qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 5/8] spapr: Clean up local variable shadowing in spapr_get_fw


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH 5/8] spapr: Clean up local variable shadowing in spapr_get_fw_dev_path()
Date: Mon, 18 Sep 2023 17:29:44 +0200
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.15.1

On 18/9/23 16:58, Cédric Le Goater wrote:
Rename PCIDevice variable to avoid this warning :

   ../hw/ppc/spapr.c: In function ‘spapr_get_fw_dev_path’:
   ../hw/ppc/spapr.c:3217:20: warning: declaration of ‘pcidev’ shadows a 
previous local [-Wshadow=compatible-local]
    3217 |         PCIDevice *pcidev = CAST(PCIDevice, dev, TYPE_PCI_DEVICE);
         |                    ^~~~~~
   ../hw/ppc/spapr.c:3147:16: note: shadowed declaration is here
    3147 |     PCIDevice *pcidev = CAST(PCIDevice, dev, TYPE_PCI_DEVICE);
         |                ^~~~~~

Signed-off-by: Cédric Le Goater <clg@kaod.org>
---
  hw/ppc/spapr.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]