Re: [PATCH 22/28] x86: apm: avoid uninitialized data

2016-10-18 Thread Luis R. Rodriguez
On Tue, Oct 18, 2016 at 12:16:10AM +0200, Arnd Bergmann wrote: > apm_bios_call() can fail, and return a status in its argument > structure. If that status however is zero during a call from > apm_get_power_status(), we end up using data that may have > never been set, as reported by "gcc -Wmaybe-un

Re: [PATCH 22/28] x86: apm: avoid uninitialized data

2016-10-18 Thread Jiri Kosina
On Tue, 18 Oct 2016, Arnd Bergmann wrote: > apm_bios_call() can fail, and return a status in its argument > structure. If that status however is zero during a call from > apm_get_power_status(), we end up using data that may have > never been set, as reported by "gcc -Wmaybe-uninitialized": > > a

[PATCH 22/28] x86: apm: avoid uninitialized data

2016-10-17 Thread Arnd Bergmann
apm_bios_call() can fail, and return a status in its argument structure. If that status however is zero during a call from apm_get_power_status(), we end up using data that may have never been set, as reported by "gcc -Wmaybe-uninitialized": arch/x86/kernel/apm_32.c: In function ‘apm’: arch/x86/ke