Re: [Qemu-devel] [PATCH for-3.1] hw/ppc/ppc440_uc: Remove dead code in sdram_size()

2018-11-06 Thread David Gibson
On Tue, Oct 30, 2018 at 05:03:53PM +, Peter Maydell wrote: > Coverity points out in CID 1390588 that the test for sh == 0 > in sdram_size() can never fire, because we calculate sh with > sh = 1024 - ((bcr >> 6) & 0x3ff); > which must result in a value between 1 and 1024 inclusive. > >

Re: [Qemu-devel] [PATCH for-3.1] hw/ppc/ppc440_uc: Remove dead code in sdram_size()

2018-10-30 Thread BALATON Zoltan
On Tue, 30 Oct 2018, Peter Maydell wrote: Coverity points out in CID 1390588 that the test for sh == 0 in sdram_size() can never fire, because we calculate sh with sh = 1024 - ((bcr >> 6) & 0x3ff); which must result in a value between 1 and 1024 inclusive. Without the relevant manual for the

[Qemu-devel] [PATCH for-3.1] hw/ppc/ppc440_uc: Remove dead code in sdram_size()

2018-10-30 Thread Peter Maydell
Coverity points out in CID 1390588 that the test for sh == 0 in sdram_size() can never fire, because we calculate sh with sh = 1024 - ((bcr >> 6) & 0x3ff); which must result in a value between 1 and 1024 inclusive. Without the relevant manual for the SoC, we're not completely sure of the