* [PATCH] PCI: designware: Use NULL instead of false
@ 2014-09-19 13:47 Fabio Estevam
2014-09-19 15:27 ` Lucas Stach
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Fabio Estevam @ 2014-09-19 13:47 UTC (permalink / raw)
To: bhelgaas; +Cc: mohit.kumar, jg1.han, linux-pci, Fabio Estevam
of_get_address() expects pointers in the third and fourth parameters.
Pass NULL in order to fix the following sparse warnings:
drivers/pci/host/pcie-designware.c:433:51: warning: Using plain integer as NULL pointer
drivers/pci/host/pcie-designware.c:433:58: warning: Using plain integer as NULL pointer
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
---
drivers/pci/host/pcie-designware.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pci/host/pcie-designware.c b/drivers/pci/host/pcie-designware.c
index 12c42fc..f1f0b7a 100644
--- a/drivers/pci/host/pcie-designware.c
+++ b/drivers/pci/host/pcie-designware.c
@@ -430,7 +430,7 @@ int __init dw_pcie_host_init(struct pcie_port *pp)
/* Find the untranslated configuration space address */
index = of_property_match_string(np, "reg-names", "config");
- addrp = of_get_address(np, index, false, false);
+ addrp = of_get_address(np, index, NULL, NULL);
pp->cfg0_mod_base = of_read_number(addrp, ns);
pp->cfg1_mod_base = pp->cfg0_mod_base + pp->config.cfg0_size;
} else {
--
1.9.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] PCI: designware: Use NULL instead of false
2014-09-19 13:47 [PATCH] PCI: designware: Use NULL instead of false Fabio Estevam
@ 2014-09-19 15:27 ` Lucas Stach
2014-09-22 9:26 ` Jingoo Han
2014-09-22 20:54 ` Bjorn Helgaas
2 siblings, 0 replies; 4+ messages in thread
From: Lucas Stach @ 2014-09-19 15:27 UTC (permalink / raw)
To: Fabio Estevam; +Cc: bhelgaas, mohit.kumar, jg1.han, linux-pci
Am Freitag, den 19.09.2014, 10:47 -0300 schrieb Fabio Estevam:
> of_get_address() expects pointers in the third and fourth parameters.
>
> Pass NULL in order to fix the following sparse warnings:
>
> drivers/pci/host/pcie-designware.c:433:51: warning: Using plain integer as NULL pointer
> drivers/pci/host/pcie-designware.c:433:58: warning: Using plain integer as NULL pointer
>
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Lucas Stach <l.stach@pengutronix.de>
> ---
> drivers/pci/host/pcie-designware.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pci/host/pcie-designware.c b/drivers/pci/host/pcie-designware.c
> index 12c42fc..f1f0b7a 100644
> --- a/drivers/pci/host/pcie-designware.c
> +++ b/drivers/pci/host/pcie-designware.c
> @@ -430,7 +430,7 @@ int __init dw_pcie_host_init(struct pcie_port *pp)
>
> /* Find the untranslated configuration space address */
> index = of_property_match_string(np, "reg-names", "config");
> - addrp = of_get_address(np, index, false, false);
> + addrp = of_get_address(np, index, NULL, NULL);
> pp->cfg0_mod_base = of_read_number(addrp, ns);
> pp->cfg1_mod_base = pp->cfg0_mod_base + pp->config.cfg0_size;
> } else {
--
Pengutronix e.K. | Lucas Stach |
Industrial Linux Solutions | http://www.pengutronix.de/ |
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] PCI: designware: Use NULL instead of false
2014-09-19 13:47 [PATCH] PCI: designware: Use NULL instead of false Fabio Estevam
2014-09-19 15:27 ` Lucas Stach
@ 2014-09-22 9:26 ` Jingoo Han
2014-09-22 20:54 ` Bjorn Helgaas
2 siblings, 0 replies; 4+ messages in thread
From: Jingoo Han @ 2014-09-22 9:26 UTC (permalink / raw)
To: 'Fabio Estevam'
Cc: bhelgaas, mohit.kumar, linux-pci, 'Jingoo Han'
On Friday, September 19, 2014 10:48 PM, Fabio Estevam wrote:
>
> of_get_address() expects pointers in the third and fourth parameters.
>
> Pass NULL in order to fix the following sparse warnings:
>
> drivers/pci/host/pcie-designware.c:433:51: warning: Using plain integer as NULL pointer
> drivers/pci/host/pcie-designware.c:433:58: warning: Using plain integer as NULL pointer
>
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Jingoo Han <jg1.han@samsung.com>
Best regards,
Jingoo Han
> ---
> drivers/pci/host/pcie-designware.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pci/host/pcie-designware.c b/drivers/pci/host/pcie-designware.c
> index 12c42fc..f1f0b7a 100644
> --- a/drivers/pci/host/pcie-designware.c
> +++ b/drivers/pci/host/pcie-designware.c
> @@ -430,7 +430,7 @@ int __init dw_pcie_host_init(struct pcie_port *pp)
>
> /* Find the untranslated configuration space address */
> index = of_property_match_string(np, "reg-names", "config");
> - addrp = of_get_address(np, index, false, false);
> + addrp = of_get_address(np, index, NULL, NULL);
> pp->cfg0_mod_base = of_read_number(addrp, ns);
> pp->cfg1_mod_base = pp->cfg0_mod_base + pp->config.cfg0_size;
> } else {
> --
> 1.9.1
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] PCI: designware: Use NULL instead of false
2014-09-19 13:47 [PATCH] PCI: designware: Use NULL instead of false Fabio Estevam
2014-09-19 15:27 ` Lucas Stach
2014-09-22 9:26 ` Jingoo Han
@ 2014-09-22 20:54 ` Bjorn Helgaas
2 siblings, 0 replies; 4+ messages in thread
From: Bjorn Helgaas @ 2014-09-22 20:54 UTC (permalink / raw)
To: Fabio Estevam; +Cc: mohit.kumar, jg1.han, linux-pci
On Fri, Sep 19, 2014 at 10:47:30AM -0300, Fabio Estevam wrote:
> of_get_address() expects pointers in the third and fourth parameters.
>
> Pass NULL in order to fix the following sparse warnings:
>
> drivers/pci/host/pcie-designware.c:433:51: warning: Using plain integer as NULL pointer
> drivers/pci/host/pcie-designware.c:433:58: warning: Using plain integer as NULL pointer
>
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Applied with acks from Lucas and Jingoo to pci/host-designware for v3.18,
thanks!
> ---
> drivers/pci/host/pcie-designware.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pci/host/pcie-designware.c b/drivers/pci/host/pcie-designware.c
> index 12c42fc..f1f0b7a 100644
> --- a/drivers/pci/host/pcie-designware.c
> +++ b/drivers/pci/host/pcie-designware.c
> @@ -430,7 +430,7 @@ int __init dw_pcie_host_init(struct pcie_port *pp)
>
> /* Find the untranslated configuration space address */
> index = of_property_match_string(np, "reg-names", "config");
> - addrp = of_get_address(np, index, false, false);
> + addrp = of_get_address(np, index, NULL, NULL);
> pp->cfg0_mod_base = of_read_number(addrp, ns);
> pp->cfg1_mod_base = pp->cfg0_mod_base + pp->config.cfg0_size;
> } else {
> --
> 1.9.1
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-09-22 20:54 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-19 13:47 [PATCH] PCI: designware: Use NULL instead of false Fabio Estevam
2014-09-19 15:27 ` Lucas Stach
2014-09-22 9:26 ` Jingoo Han
2014-09-22 20:54 ` Bjorn Helgaas
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).