linux/drivers/cxl
Ben Widawsky 85afc3175a cxl/pci: Split cxl_pci_setup_regs()
In preparation for moving parts of register mapping to cxl_core, split
cxl_pci_setup_regs() into a helper that finds register blocks,
(cxl_find_regblock()), and a generic wrapper that probes the precise
register sets within a block (cxl_setup_regs()).

Move the actual mapping (cxl_map_regs()) of the only register-set that
cxl_pci cares about (memory device registers) up a level from the former
cxl_pci_setup_regs() into cxl_pci_probe().

With this change the unused component registers are no longer mapped,
but the helpers are primed to move into the core.

[djbw: drop cxl_map_regs() for component registers]

Signed-off-by: Ben Widawsky <ben.widawsky@intel.com>
[djbw: rebase on the cxl_register_map refactor]
Reviewed-by: Ira Weiny <ira.weiny@intel.com>
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Link: https://lore.kernel.org/r/163434053788.914258.18412599112859205220.stgit@dwillia2-desk3.amr.corp.intel.com
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
2021-10-29 11:53:51 -07:00
..
core cxl/core: Split decoder setup into alloc + add 2021-09-21 14:09:34 -07:00
acpi.c cxl/acpi: Do not fail cxl_acpi_probe() based on a missing CHBS 2021-10-08 01:05:31 -07:00
cxl.h cxl/pci: Add @base to cxl_register_map 2021-10-29 11:53:51 -07:00
cxlmem.h cxl/mbox: Move command definitions to common location 2021-09-21 14:09:34 -07:00
Kconfig cxl/pmem: Add initial infrastructure for pmem support 2021-06-15 16:47:14 -07:00
Makefile cxl: Move cxl_core to new directory 2021-08-06 08:22:53 -07:00
pci.c cxl/pci: Split cxl_pci_setup_regs() 2021-10-29 11:53:51 -07:00
pci.h cxl/pci: Convert register block identifiers to an enum 2021-10-29 11:53:51 -07:00
pmem.c tools/testing/cxl: Introduce a mock memory device + driver 2021-09-21 14:09:34 -07:00