Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | # SPDX-License-Identifier: GPL-2.0 |
Dan Williams | 9d27a87 | 2015-07-10 14:07:03 -0400 | [diff] [blame] | 2 | ldflags-y += --wrap=ioremap_wc |
Ross Zwisler | 67a3e8f | 2015-08-27 13:14:20 -0600 | [diff] [blame] | 3 | ldflags-y += --wrap=memremap |
Dan Williams | 9d27a87 | 2015-07-10 14:07:03 -0400 | [diff] [blame] | 4 | ldflags-y += --wrap=devm_ioremap_nocache |
Christoph Hellwig | 708ab62 | 2015-08-10 23:07:08 -0400 | [diff] [blame] | 5 | ldflags-y += --wrap=devm_memremap |
Dan Williams | 32ab0a3f | 2015-08-01 02:16:37 -0400 | [diff] [blame] | 6 | ldflags-y += --wrap=devm_memunmap |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 7 | ldflags-y += --wrap=ioremap_nocache |
| 8 | ldflags-y += --wrap=iounmap |
Ross Zwisler | 67a3e8f | 2015-08-27 13:14:20 -0600 | [diff] [blame] | 9 | ldflags-y += --wrap=memunmap |
Christoph Hellwig | 708ab62 | 2015-08-10 23:07:08 -0400 | [diff] [blame] | 10 | ldflags-y += --wrap=__devm_request_region |
Dan Williams | 200c79d | 2016-03-22 00:22:16 -0700 | [diff] [blame] | 11 | ldflags-y += --wrap=__devm_release_region |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 12 | ldflags-y += --wrap=__request_region |
| 13 | ldflags-y += --wrap=__release_region |
Dan Williams | 979fccf | 2015-12-15 00:34:21 -0800 | [diff] [blame] | 14 | ldflags-y += --wrap=devm_memremap_pages |
Dan Williams | ee8520f | 2016-06-15 20:34:17 -0700 | [diff] [blame] | 15 | ldflags-y += --wrap=insert_resource |
| 16 | ldflags-y += --wrap=remove_resource |
Dan Williams | c14a868 | 2016-08-18 22:15:04 -0700 | [diff] [blame] | 17 | ldflags-y += --wrap=acpi_evaluate_object |
Dan Williams | a7de92d | 2016-12-05 13:43:25 -0800 | [diff] [blame] | 18 | ldflags-y += --wrap=acpi_evaluate_dsm |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 19 | |
| 20 | DRIVERS := ../../../drivers |
| 21 | NVDIMM_SRC := $(DRIVERS)/nvdimm |
Dan Williams | bdf9701 | 2016-07-23 21:24:19 -0700 | [diff] [blame] | 22 | ACPI_SRC := $(DRIVERS)/acpi/nfit |
Dan Williams | ab68f26 | 2016-05-18 09:15:08 -0700 | [diff] [blame] | 23 | DAX_SRC := $(DRIVERS)/dax |
Dan Williams | f295e53 | 2016-06-17 11:08:06 -0700 | [diff] [blame] | 24 | ccflags-y := -I$(src)/$(NVDIMM_SRC)/ |
Dan Williams | f110176 | 2018-10-17 10:47:19 -0700 | [diff] [blame] | 25 | ccflags-y += -I$(src)/$(ACPI_SRC)/ |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 26 | |
| 27 | obj-$(CONFIG_LIBNVDIMM) += libnvdimm.o |
| 28 | obj-$(CONFIG_BLK_DEV_PMEM) += nd_pmem.o |
| 29 | obj-$(CONFIG_ND_BTT) += nd_btt.o |
| 30 | obj-$(CONFIG_ND_BLK) += nd_blk.o |
Dan Williams | 7a67832 | 2015-08-19 00:34:34 -0400 | [diff] [blame] | 31 | obj-$(CONFIG_X86_PMEM_LEGACY) += nd_e820.o |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 32 | obj-$(CONFIG_ACPI_NFIT) += nfit.o |
Dan Williams | 7b6be84 | 2017-04-11 09:49:49 -0700 | [diff] [blame] | 33 | ifeq ($(CONFIG_DAX),m) |
| 34 | obj-$(CONFIG_DAX) += dax.o |
| 35 | endif |
| 36 | obj-$(CONFIG_DEV_DAX) += device_dax.o |
Dan Williams | ab68f26 | 2016-05-18 09:15:08 -0700 | [diff] [blame] | 37 | obj-$(CONFIG_DEV_DAX_PMEM) += dax_pmem.o |
Dan Williams | 730926c | 2017-07-16 13:51:53 -0700 | [diff] [blame^] | 38 | obj-$(CONFIG_DEV_DAX_PMEM) += dax_pmem_core.o |
| 39 | obj-$(CONFIG_DEV_DAX_PMEM_COMPAT) += dax_pmem_compat.o |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 40 | |
Dan Williams | bdf9701 | 2016-07-23 21:24:19 -0700 | [diff] [blame] | 41 | nfit-y := $(ACPI_SRC)/core.o |
Dave Jiang | f298939 | 2018-12-05 23:39:29 -0800 | [diff] [blame] | 42 | nfit-y += $(ACPI_SRC)/intel.o |
Vishal Verma | 6839a6d | 2016-07-23 21:51:21 -0700 | [diff] [blame] | 43 | nfit-$(CONFIG_X86_MCE) += $(ACPI_SRC)/mce.o |
Dan Williams | 0fb5c8d | 2018-02-01 12:28:54 -0800 | [diff] [blame] | 44 | nfit-y += acpi_nfit_test.o |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 45 | nfit-y += config_check.o |
| 46 | |
| 47 | nd_pmem-y := $(NVDIMM_SRC)/pmem.o |
Dan Williams | f295e53 | 2016-06-17 11:08:06 -0700 | [diff] [blame] | 48 | nd_pmem-y += pmem-dax.o |
Dan Williams | 0fb5c8d | 2018-02-01 12:28:54 -0800 | [diff] [blame] | 49 | nd_pmem-y += pmem_test.o |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 50 | nd_pmem-y += config_check.o |
| 51 | |
| 52 | nd_btt-y := $(NVDIMM_SRC)/btt.o |
| 53 | nd_btt-y += config_check.o |
| 54 | |
| 55 | nd_blk-y := $(NVDIMM_SRC)/blk.o |
| 56 | nd_blk-y += config_check.o |
| 57 | |
Dan Williams | 7a67832 | 2015-08-19 00:34:34 -0400 | [diff] [blame] | 58 | nd_e820-y := $(NVDIMM_SRC)/e820.o |
| 59 | nd_e820-y += config_check.o |
| 60 | |
Dan Williams | 7b6be84 | 2017-04-11 09:49:49 -0700 | [diff] [blame] | 61 | dax-y := $(DAX_SRC)/super.o |
Dan Williams | 51cf784 | 2017-07-12 17:58:21 -0700 | [diff] [blame] | 62 | dax-y += $(DAX_SRC)/bus.o |
Dan Williams | ab68f26 | 2016-05-18 09:15:08 -0700 | [diff] [blame] | 63 | dax-y += config_check.o |
| 64 | |
Dan Williams | 7b6be84 | 2017-04-11 09:49:49 -0700 | [diff] [blame] | 65 | device_dax-y := $(DAX_SRC)/device.o |
Dan Williams | 7361636 | 2017-05-04 23:38:43 -0700 | [diff] [blame] | 66 | device_dax-y += dax-dev.o |
Dan Williams | 0fb5c8d | 2018-02-01 12:28:54 -0800 | [diff] [blame] | 67 | device_dax-y += device_dax_test.o |
Dan Williams | 7b6be84 | 2017-04-11 09:49:49 -0700 | [diff] [blame] | 68 | device_dax-y += config_check.o |
| 69 | |
Dan Williams | 730926c | 2017-07-16 13:51:53 -0700 | [diff] [blame^] | 70 | dax_pmem-y := $(DAX_SRC)/pmem/pmem.o |
| 71 | dax_pmem_core-y := $(DAX_SRC)/pmem/core.o |
| 72 | dax_pmem_compat-y := $(DAX_SRC)/pmem/compat.o |
Dan Williams | ab68f26 | 2016-05-18 09:15:08 -0700 | [diff] [blame] | 73 | dax_pmem-y += config_check.o |
| 74 | |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 75 | libnvdimm-y := $(NVDIMM_SRC)/core.o |
| 76 | libnvdimm-y += $(NVDIMM_SRC)/bus.o |
| 77 | libnvdimm-y += $(NVDIMM_SRC)/dimm_devs.o |
| 78 | libnvdimm-y += $(NVDIMM_SRC)/dimm.o |
| 79 | libnvdimm-y += $(NVDIMM_SRC)/region_devs.o |
| 80 | libnvdimm-y += $(NVDIMM_SRC)/region.o |
| 81 | libnvdimm-y += $(NVDIMM_SRC)/namespace_devs.o |
| 82 | libnvdimm-y += $(NVDIMM_SRC)/label.o |
Dave Jiang | aa9ad44 | 2017-08-23 12:48:26 -0700 | [diff] [blame] | 83 | libnvdimm-y += $(NVDIMM_SRC)/badrange.o |
Dan Williams | e145574 | 2015-07-30 17:57:47 -0400 | [diff] [blame] | 84 | libnvdimm-$(CONFIG_ND_CLAIM) += $(NVDIMM_SRC)/claim.o |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 85 | libnvdimm-$(CONFIG_BTT) += $(NVDIMM_SRC)/btt_devs.o |
Dan Williams | e145574 | 2015-07-30 17:57:47 -0400 | [diff] [blame] | 86 | libnvdimm-$(CONFIG_NVDIMM_PFN) += $(NVDIMM_SRC)/pfn_devs.o |
Dan Williams | cd03412 | 2016-03-11 10:15:36 -0800 | [diff] [blame] | 87 | libnvdimm-$(CONFIG_NVDIMM_DAX) += $(NVDIMM_SRC)/dax_devs.o |
Dave Jiang | 4c6926a | 2018-12-06 12:40:01 -0800 | [diff] [blame] | 88 | libnvdimm-$(CONFIG_NVDIMM_KEYS) += $(NVDIMM_SRC)/security.o |
Dave Jiang | 3c13e2a | 2018-12-10 13:20:42 -0700 | [diff] [blame] | 89 | libnvdimm-y += dimm_devs.o |
Dan Williams | 0fb5c8d | 2018-02-01 12:28:54 -0800 | [diff] [blame] | 90 | libnvdimm-y += libnvdimm_test.o |
Dan Williams | 6bc7561 | 2015-06-17 17:23:32 -0400 | [diff] [blame] | 91 | libnvdimm-y += config_check.o |
| 92 | |
| 93 | obj-m += test/ |