Blame view

drivers/nvdimm/Kconfig 4.22 KB
ec8f24b7f   Thomas Gleixner   treewide: Add SPD...
1
  # SPDX-License-Identifier: GPL-2.0-only
18da2c9ee   Dan Williams   libnvdimm, pmem: ...
2
  menuconfig LIBNVDIMM
b94d5230d   Dan Williams   libnvdimm, nfit: ...
3
4
  	tristate "NVDIMM (Non-Volatile Memory Device) Support"
  	depends on PHYS_ADDR_T_64BIT
29b9aa0aa   Dan Williams   libnvdimm: introd...
5
  	depends on HAS_IOMEM
b94d5230d   Dan Williams   libnvdimm, nfit: ...
6
  	depends on BLK_DEV
33dd70752   Dan Williams   lib: Uplevel the ...
7
  	select MEMREGION
b94d5230d   Dan Williams   libnvdimm, nfit: ...
8
9
10
11
12
13
  	help
  	  Generic support for non-volatile memory devices including
  	  ACPI-6-NFIT defined resources.  On platforms that define an
  	  NFIT, or otherwise can discover NVDIMM resources, a libnvdimm
  	  bus is registered to advertise PMEM (persistent memory)
  	  namespaces (/dev/pmemX) and BLK (sliding mmio window(s))
5212e11fd   Vishal Verma   nd_btt: atomic se...
14
15
16
17
18
  	  namespaces (/dev/ndblkX.Y). A PMEM namespace refers to a
  	  memory resource that may span multiple DIMMs and support DAX
  	  (see CONFIG_DAX).  A BLK namespace refers to an NVDIMM control
  	  region which exposes an mmio register set for windowed access
  	  mode to non-volatile memory.
18da2c9ee   Dan Williams   libnvdimm, pmem: ...
19
20
21
22
23
24
  
  if LIBNVDIMM
  
  config BLK_DEV_PMEM
  	tristate "PMEM: Persistent memory block device support"
  	default LIBNVDIMM
2080e88ae   Dan Williams   dax: introduce CO...
25
  	select DAX_DRIVER
5212e11fd   Vishal Verma   nd_btt: atomic se...
26
  	select ND_BTT if BTT
e1455744b   Dan Williams   libnvdimm, pfn: '...
27
  	select ND_PFN if NVDIMM_PFN
18da2c9ee   Dan Williams   libnvdimm, pmem: ...
28
29
30
31
32
33
  	help
  	  Memory ranges for PMEM are described by either an NFIT
  	  (NVDIMM Firmware Interface Table, see CONFIG_NFIT_ACPI), a
  	  non-standard OEM-specific E820 memory type (type-12, see
  	  CONFIG_X86_PMEM_LEGACY), or it is manually specified by the
  	  'memmap=nn[KMG]!ss[KMG]' kernel command line (see
8c27ceff3   Mauro Carvalho Chehab   docs: fix locatio...
34
  	  Documentation/admin-guide/kernel-parameters.rst).  This driver converts
18da2c9ee   Dan Williams   libnvdimm, pmem: ...
35
36
  	  these persistent memory ranges into block devices that are
  	  capable of DAX (direct-access) file system mappings.  See
ae4a05027   Mauro Carvalho Chehab   docs: nvdimm: add...
37
  	  Documentation/driver-api/nvdimm/nvdimm.rst for more details.
18da2c9ee   Dan Williams   libnvdimm, pmem: ...
38
39
  
  	  Say Y if you want to use an NVDIMM
047fc8a1f   Ross Zwisler   libnvdimm, nfit, ...
40
41
42
43
44
45
46
47
48
49
50
51
  config ND_BLK
  	tristate "BLK: Block data window (aperture) device support"
  	default LIBNVDIMM
  	select ND_BTT if BTT
  	help
  	  Support NVDIMMs, or other devices, that implement a BLK-mode
  	  access capability.  BLK-mode access uses memory-mapped-i/o
  	  apertures to access persistent media.
  
  	  Say Y if your platform firmware emits an ACPI.NFIT table
  	  (CONFIG_ACPI_NFIT), or otherwise exposes BLK-mode
  	  capabilities.
e1455744b   Dan Williams   libnvdimm, pfn: '...
52
53
  config ND_CLAIM
  	bool
5212e11fd   Vishal Verma   nd_btt: atomic se...
54
55
  config ND_BTT
  	tristate
8c2f7e865   Dan Williams   libnvdimm: infras...
56
  config BTT
5212e11fd   Vishal Verma   nd_btt: atomic se...
57
58
  	bool "BTT: Block Translation Table (atomic sector updates)"
  	default y if LIBNVDIMM
e1455744b   Dan Williams   libnvdimm, pfn: '...
59
  	select ND_CLAIM
5212e11fd   Vishal Verma   nd_btt: atomic se...
60
61
62
63
64
65
66
67
68
69
70
  	help
  	  The Block Translation Table (BTT) provides atomic sector
  	  update semantics for persistent memory devices, so that
  	  applications that rely on sector writes not being torn (a
  	  guarantee that typical disks provide) can continue to do so.
  	  The BTT manifests itself as an alternate personality for an
  	  NVDIMM namespace, i.e. a namespace can be in raw mode (pmemX,
  	  ndblkX.Y, etc...), or 'sectored' mode, (pmemXs, ndblkX.Ys,
  	  etc...).
  
  	  Select Y if unsure
8c2f7e865   Dan Williams   libnvdimm: infras...
71

e1455744b   Dan Williams   libnvdimm, pfn: '...
72
73
74
75
76
77
  config ND_PFN
  	tristate
  
  config NVDIMM_PFN
  	bool "PFN: Map persistent (device) memory"
  	default LIBNVDIMM
32ab0a3f5   Dan Williams   libnvdimm, pmem: ...
78
  	depends on ZONE_DEVICE
e1455744b   Dan Williams   libnvdimm, pfn: '...
79
80
81
82
83
84
85
86
87
88
  	select ND_CLAIM
  	help
  	  Map persistent memory, i.e. advertise it to the memory
  	  management sub-system.  By default persistent memory does
  	  not support direct I/O, RDMA, or any other usage that
  	  requires a 'struct page' to mediate an I/O request.  This
  	  driver allocates and initializes the infrastructure needed
  	  to support those use cases.
  
  	  Select Y if unsure
cd03412a5   Dan Williams   libnvdimm, dax: i...
89
  config NVDIMM_DAX
867dfe342   Arnd Bergmann   nvdimm: make CONF...
90
  	bool "NVDIMM DAX: Raw access to persistent memory"
cd03412a5   Dan Williams   libnvdimm, dax: i...
91
92
93
94
95
  	default LIBNVDIMM
  	depends on NVDIMM_PFN
  	help
  	  Support raw device dax access to a persistent memory
  	  namespace.  For environments that want to hard partition
83fc61a56   Masanari Iida   treewide: Fix typ...
96
  	  persistent memory, this capability provides a mechanism to
cd03412a5   Dan Williams   libnvdimm, dax: i...
97
98
99
100
  	  sub-divide a namespace into character devices that can only be
  	  accessed via DAX (mmap(2)).
  
  	  Select Y if unsure
717197608   Oliver O'Halloran   libnvdimm: Add de...
101
  config OF_PMEM
f22acf827   Dan Williams   Revert "libnvdimm...
102
  	tristate "Device-tree support for persistent memory regions"
717197608   Oliver O'Halloran   libnvdimm: Add de...
103
104
105
106
107
108
109
  	depends on OF
  	default LIBNVDIMM
  	help
  	  Allows regions of persistent memory to be described in the
  	  device-tree.
  
  	  Select Y if unsure.
4c6926a23   Dave Jiang   acpi/nfit, libnvd...
110
111
112
113
  config NVDIMM_KEYS
  	def_bool y
  	depends on ENCRYPTED_KEYS
  	depends on (LIBNVDIMM=ENCRYPTED_KEYS) || LIBNVDIMM=m
62974fc38   Dan Williams   libnvdimm: Enable...
114
115
116
117
118
119
120
121
122
123
124
  config NVDIMM_TEST_BUILD
  	tristate "Build the unit test core"
  	depends on m
  	depends on COMPILE_TEST && X86_64
  	default m if COMPILE_TEST
  	help
  	  Build the core of the unit test infrastructure. The result of
  	  this build is non-functional for unit test execution, but it
  	  otherwise helps catch build errors induced by changes to the
  	  core devm_memremap_pages() implementation and other
  	  infrastructure.
18da2c9ee   Dan Williams   libnvdimm, pmem: ...
125
  endif