[PATCH 3/3] PCI/sysfs: Remove unnecessary zero in initializer

From: Ilpo Järvinen
Date: Mon Oct 28 2024 - 13:47:25 EST


Providing empty initializer for an array is enough to set its elements
to zero. Thus, remove the redundant 0 from the initializer.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@xxxxxxxxxxxxxxx>
---
drivers/pci/pci-sysfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
index 74e4e0917898..19da2f8e98e4 100644
--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -1433,7 +1433,7 @@ static ssize_t reset_method_store(struct device *dev,
struct pci_dev *pdev = to_pci_dev(dev);
char *tmp_options, *name;
int m, n;
- u8 reset_methods[PCI_NUM_RESET_METHODS] = { 0 };
+ u8 reset_methods[PCI_NUM_RESET_METHODS] = {};

if (sysfs_streq(buf, "")) {
pdev->reset_methods[0] = 0;
--
2.39.5