From: Richard Henderson Date: Mon, 12 Jul 2021 20:04:37 +0000 (+0000) Subject: hw/pci-hist/pnv_phb4: Fix typo in pnv_phb4_ioda_write X-Git-Tag: v6.1.0-rc1~4^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=984178d86b92be23b0efb6da769f22adb08cb83a;p=thirdparty%2Fqemu.git hw/pci-hist/pnv_phb4: Fix typo in pnv_phb4_ioda_write From clang-13: hw/pci-host/pnv_phb4.c:375:18: error: variable 'v' set but not used \ [-Werror,-Wunused-but-set-variable] It's pretty clear that we meant to write back 'v' after all that computation and not 'val'. Acked-by: David Gibson Acked-by: Benjamin Herrenschmidt Reviewed-by: Cédric Le Goater Signed-off-by: Richard Henderson --- diff --git a/hw/pci-host/pnv_phb4.c b/hw/pci-host/pnv_phb4.c index 54f57c660a9..5c375a9f285 100644 --- a/hw/pci-host/pnv_phb4.c +++ b/hw/pci-host/pnv_phb4.c @@ -392,7 +392,7 @@ static void pnv_phb4_ioda_write(PnvPHB4 *phb, uint64_t val) v &= 0xffffffffffff0000ull; v |= 0x000000000000cfffull & val; } - *tptr = val; + *tptr = v; break; } case IODA3_TBL_MBT: