From: John Crispin <blogic@openwrt.org>
To: Varka Bhadram <varkabhadram@gmail.com>, linux-mips@linux-mips.org
Cc: ralf@linux-mips.org, Varka Bhadram <varkab@cdac.in>
Subject: Re: [PATCH mips] pci: pci-lantiq: remove duplicate check on resource
Date: Wed, 22 Oct 2014 08:43:00 +0200 [thread overview]
Message-ID: <544751F4.3080304@openwrt.org> (raw)
In-Reply-To: <1413950475-29451-1-git-send-email-varkab@cdac.in>
Hi Vara,
On 22/10/2014 06:01, Varka Bhadram wrote:
> Sanity check on resource happening with devm_ioremap_resource()
>
> Signed-off-by: Varka Bhadram <varkab@cdac.in>
Acked-by: John Crispin <blogic@openwrt.org>
Thanks for the fix !
> ---
>
> This patch based on master brnch of
> https://kernel.googlesource.com/pub/scm/linux/kernel/git/ralf/linux
> tree.
>
> Thanks.
>
> arch/mips/pci/pci-lantiq.c | 7 +------ 1 file changed, 1
> insertion(+), 6 deletions(-)
>
> diff --git a/arch/mips/pci/pci-lantiq.c
> b/arch/mips/pci/pci-lantiq.c index 37fe8e7..d3ed15b 100644 ---
> a/arch/mips/pci/pci-lantiq.c +++ b/arch/mips/pci/pci-lantiq.c @@
> -215,17 +215,12 @@ static int ltq_pci_probe(struct platform_device
> *pdev)
>
> pci_clear_flags(PCI_PROBE_ONLY);
>
> - res_cfg = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> res_bridge = platform_get_resource(pdev, IORESOURCE_MEM, 1); - if
> (!res_cfg || !res_bridge) { - dev_err(&pdev->dev, "missing memory
> resources\n"); - return -EINVAL; - } - ltq_pci_membase =
> devm_ioremap_resource(&pdev->dev, res_bridge); if
> (IS_ERR(ltq_pci_membase)) return PTR_ERR(ltq_pci_membase);
>
> + res_cfg = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> ltq_pci_mapped_cfg = devm_ioremap_resource(&pdev->dev, res_cfg); if
> (IS_ERR(ltq_pci_mapped_cfg)) return PTR_ERR(ltq_pci_mapped_cfg);
>
prev parent reply other threads:[~2014-10-22 6:43 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-22 4:01 [PATCH mips] pci: pci-lantiq: remove duplicate check on resource Varka Bhadram
2014-10-22 6:43 ` John Crispin [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=544751F4.3080304@openwrt.org \
--to=blogic@openwrt.org \
--cc=linux-mips@linux-mips.org \
--cc=ralf@linux-mips.org \
--cc=varkab@cdac.in \
--cc=varkabhadram@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox