]> www.infradead.org Git - users/jedix/linux-maple.git/commit
cxl/region: Refactor common create region code
authorIra Weiny <ira.weiny@intel.com>
Thu, 7 Nov 2024 20:58:24 +0000 (14:58 -0600)
committerDave Jiang <dave.jiang@intel.com>
Fri, 8 Nov 2024 16:40:16 +0000 (09:40 -0700)
commita90326c76bd684bdf0a4f2842ff987ad5c77ff11
tree8ae5d344d3c981658f83b9243f4a23fa35037129
parent27fcfb416827b9e549d821317a9bd21d1abe6821
cxl/region: Refactor common create region code

create_pmem_region_store() and create_ram_region_store() are identical
with the exception of the region mode.  With the addition of DC region
mode this would end up being 3 copies of the same code.

Refactor create_pmem_region_store() and create_ram_region_store() to use
a single common function to be used in subsequent DC code.

Suggested-by: Fan Ni <fan.ni@samsung.com>
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Fan Ni <fan.ni@samsung.com>
Reviewed-by: Dave Jiang <dave.jiang@intel.com>
Reviewed-by: Li Ming <ming4.li@intel.com>
Reviewed-by: Alison Schofield <alison.schofield@intel.com>
Signed-off-by: Ira Weiny <ira.weiny@intel.com>
Link: https://patch.msgid.link/20241107-dcd-type2-upstream-v7-6-56a84e66bc36@intel.com
Signed-off-by: Dave Jiang <dave.jiang@intel.com>
drivers/cxl/core/region.c