PCI: of_property: Constify parameter in of_pci_get_addr_flags()

The res parameter has no reason to be a pointer to an un-const struct
resource. Indeed, struct resource is not supposed to be modified by the
function.

Constify the res parameter.

Link: https://lore.kernel.org/r/20250224141356.36325-5-herve.codina@bootlin.com
Signed-off-by: Herve Codina <herve.codina@bootlin.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
This commit is contained in:
Herve Codina 2025-02-24 15:13:54 +01:00 committed by Bjorn Helgaas
parent c5785a165f
commit 3dc8adeeef

View File

@ -69,7 +69,7 @@ static void of_pci_set_address(struct pci_dev *pdev, u32 *prop, u64 addr,
}
}
static int of_pci_get_addr_flags(struct resource *res, u32 *flags)
static int of_pci_get_addr_flags(const struct resource *res, u32 *flags)
{
u32 ss;