On 6/16/20 7:15 PM, Cédric Le Goater wrote:
> After a closer look,
>
>>> @@ -45,9 +46,15 @@ static void pca9552_update_pin_input(PCA9552State *s)
>>> switch (config) {
>>> case PCA9552_LED_ON:
>>> s->regs[input_reg] |= 1 << input_shift;
>>> +if (input_shi
After a closer look,
>> @@ -45,9 +46,15 @@ static void pca9552_update_pin_input(PCA9552State *s)
>> switch (config) {
>> case PCA9552_LED_ON:
>> s->regs[input_reg] |= 1 << input_shift;
>> +if (input_shift < s->nr_leds) {
This seems like a superfluous test
On 6/16/20 11:45 AM, Philippe Mathieu-Daudé wrote:
> Signed-off-by: Philippe Mathieu-Daudé
Reviewed-by: Cédric Le Goater
Tested-by: Cédric Le Goater
Download an OpenBMC witherspoon flash image :
wget
https://openpower.xyz/job/openbmc-build/lastSuccessfulBuild/distro=ubuntu,label=builder,ta
Signed-off-by: Philippe Mathieu-Daudé
---
hw/misc/pca9552.c| 7 +++
hw/misc/trace-events | 3 +++
2 files changed, 10 insertions(+)
diff --git a/hw/misc/pca9552.c b/hw/misc/pca9552.c
index cac729e35a..a3d0decbff 100644
--- a/hw/misc/pca9552.c
+++ b/hw/misc/pca9552.c
@@ -17,6 +17,7 @@
#i