Re: [PATCH 1/3] PCI/pwrctrl: Fix device leak at registration
From: Markus Elfring
Date: Tue Jul 22 2025 - 14:34:43 EST
…
> +++ b/drivers/pci/bus.c
> @@ -362,11 +362,15 @@ void pci_bus_add_device(struct pci_dev *dev)
…
> + if (of_pci_supply_present(dn)) {
> + if (!device_link_add(&dev->dev, &pdev->dev,
> + DL_FLAG_AUTOREMOVE_CONSUMER)) {
> + pci_err(dev, "failed to add device link to power control device %s\n",
> + pdev->name);
> + }
> + }
…
How do you think about to reconsider the usage of any curly brackets
once more?
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/coding-style.rst?h=v6.16-rc7#n197
Regards,
Markus