Skip to contentSkip to conversation

PCI: cpcihp: remove uneccessary field

PATCH Applied Guilherme Giacomo Simoes 2 participants 2 messages Oct 14, 2024 – Oct 16, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 PCI: cpcihp: remove uneccessary field

The hardware_test field in cpci_hp_controller_ops is uneccessary because no file is being used. How a pointer need a space in memory for storage the address (4 bytes in 32bits systems and 8 bytes in 64 bits sustems), remove this dead code to reduce resource consumption.

---
 drivers/pci/hotplug/cpci_hotplug.h | 1 -
 1 file changed, 1 deletion(-)
drivers/pci/hotplug/cpci_hotplug.h +0 -1
index 6d8970d8c3f2..03fa39ab0c88 100644
@@ -44,7 +44,6 @@ struct cpci_hp_controller_ops {
 	int (*enable_irq)(void);
 	int (*disable_irq)(void);
 	int (*check_irq)(void *dev_id);
-	int (*hardware_test)(struct slot *slot, u32 value);
 	u8  (*get_power)(struct slot *slot);
 	int (*set_power)(struct slot *slot, int value);
 };
Signature · 1 line
2.46.2
#1 lore raw
Quoted 6 lines · Guilherme Giacomo Simoes

The hardware_test field in cpci_hp_controller_ops is uneccessary because no file is being used. How a pointer need a space in memory for storage the address (4 bytes in 32bits systems and 8 bytes in 64 bits sustems), remove this dead code to reduce resource consumption.

Applied to pci/hotplug for v6.13, thanks!

Quoted 19 lines
---
 drivers/pci/hotplug/cpci_hotplug.h | 1 -
 1 file changed, 1 deletion(-)
drivers/pci/hotplug/cpci_hotplug.h +0 -1
index 6d8970d8c3f2..03fa39ab0c88 100644
@@ -44,7 +44,6 @@ struct cpci_hp_controller_ops {
 	int (*enable_irq)(void);
 	int (*disable_irq)(void);
 	int (*check_irq)(void *dev_id);
-	int (*hardware_test)(struct slot *slot, u32 value);
 	u8  (*get_power)(struct slot *slot);
 	int (*set_power)(struct slot *slot, int value);
 };
Signature · 1 line
2.46.2