Skip to content

Commit e99ecbc

Browse files
committed
acpi/hmat: Remove now unused hmat_update_target_coordinates()
Remove deadcode since CXL no longer calls hmat_update_target_coordinates(). Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com> Link: https://patch.msgid.link/20250829222907.1290912-5-dave.jiang@intel.com Signed-off-by: Dave Jiang <dave.jiang@intel.com>
1 parent 2e454fb commit e99ecbc

4 files changed

Lines changed: 0 additions & 48 deletions

File tree

drivers/acpi/numa/hmat.c

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -367,34 +367,6 @@ static void hmat_update_target_access(struct memory_target *target,
367367
}
368368
}
369369

370-
int hmat_update_target_coordinates(int nid, struct access_coordinate *coord,
371-
enum access_coordinate_class access)
372-
{
373-
struct memory_target *target;
374-
int pxm;
375-
376-
if (nid == NUMA_NO_NODE)
377-
return -EINVAL;
378-
379-
pxm = node_to_pxm(nid);
380-
guard(mutex)(&target_lock);
381-
target = find_mem_target(pxm);
382-
if (!target)
383-
return -ENODEV;
384-
385-
hmat_update_target_access(target, ACPI_HMAT_READ_LATENCY,
386-
coord->read_latency, access);
387-
hmat_update_target_access(target, ACPI_HMAT_WRITE_LATENCY,
388-
coord->write_latency, access);
389-
hmat_update_target_access(target, ACPI_HMAT_READ_BANDWIDTH,
390-
coord->read_bandwidth, access);
391-
hmat_update_target_access(target, ACPI_HMAT_WRITE_BANDWIDTH,
392-
coord->write_bandwidth, access);
393-
394-
return 0;
395-
}
396-
EXPORT_SYMBOL_GPL(hmat_update_target_coordinates);
397-
398370
static __init void hmat_add_locality(struct acpi_hmat_locality *hmat_loc)
399371
{
400372
struct memory_locality *loc;

drivers/cxl/core/cdat.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1075,9 +1075,3 @@ void cxl_region_perf_data_calculate(struct cxl_region *cxlr,
10751075
cxlr->coord[i].write_bandwidth += perf->coord[i].write_bandwidth;
10761076
}
10771077
}
1078-
1079-
int cxl_update_hmat_access_coordinates(int nid, struct cxl_region *cxlr,
1080-
enum access_coordinate_class access)
1081-
{
1082-
return hmat_update_target_coordinates(nid, &cxlr->coord[access], access);
1083-
}

drivers/cxl/core/core.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,8 +137,6 @@ enum cxl_poison_trace_type {
137137

138138
long cxl_pci_get_latency(struct pci_dev *pdev);
139139
int cxl_pci_get_bandwidth(struct pci_dev *pdev, struct access_coordinate *c);
140-
int cxl_update_hmat_access_coordinates(int nid, struct cxl_region *cxlr,
141-
enum access_coordinate_class access);
142140
int cxl_port_get_switch_dport_bandwidth(struct cxl_port *port,
143141
struct access_coordinate *c);
144142

include/linux/acpi.h

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1595,18 +1595,6 @@ static inline void acpi_use_parent_companion(struct device *dev)
15951595
ACPI_COMPANION_SET(dev, ACPI_COMPANION(dev->parent));
15961596
}
15971597

1598-
#ifdef CONFIG_ACPI_HMAT
1599-
int hmat_update_target_coordinates(int nid, struct access_coordinate *coord,
1600-
enum access_coordinate_class access);
1601-
#else
1602-
static inline int hmat_update_target_coordinates(int nid,
1603-
struct access_coordinate *coord,
1604-
enum access_coordinate_class access)
1605-
{
1606-
return -EOPNOTSUPP;
1607-
}
1608-
#endif
1609-
16101598
#ifdef CONFIG_ACPI_NUMA
16111599
bool acpi_node_backed_by_real_pxm(int nid);
16121600
#else

0 commit comments

Comments
 (0)