Peter Delevoryas 2ec063788e hw/gpio/aspeed_gpio: Fix QOM pin property
I was setting gpioV4-7 to "1110" using the QOM pin property handler and
noticed that lowering gpioV7 was inadvertently lowering gpioV4-6 too.

    (qemu) qom-set /machine/soc/gpio gpioV4 true
    (qemu) qom-set /machine/soc/gpio gpioV5 true
    (qemu) qom-set /machine/soc/gpio gpioV6 true
    (qemu) qom-get /machine/soc/gpio gpioV4
    true
    (qemu) qom-set /machine/soc/gpio gpioV7 false
    (qemu) qom-get /machine/soc/gpio gpioV4
    false

An expression in aspeed_gpio_set_pin_level was using a logical NOT
operator instead of a bitwise NOT operator:

    value &= !pin_mask;

The original author probably intended to make a bitwise NOT expression
"~", but mistakenly used a logical NOT operator "!" instead. Some
programming languages like Rust use "!" for both purposes.

Fixes: 4b7f956862dc ("hw/gpio: Add basic Aspeed GPIO model for AST2400 and
AST2500")
Signed-off-by: Peter Delevoryas <pdel@fb.com>
Message-Id: <20220502080827.244815-1-pdel@fb.com>
Signed-off-by: Cédric Le Goater <clg@kaod.org>
2022-05-02 17:03:04 +02:00
..
2022-04-06 20:03:26 +01:00
2022-05-02 17:03:02 +02:00
2022-03-09 18:06:40 +00:00
2022-03-09 09:13:39 +00:00
2022-04-20 09:36:24 +02:00
2022-05-02 17:03:04 +02:00
2022-04-20 10:51:11 -07:00
2022-04-26 12:25:14 +02:00
2022-04-29 10:48:48 +10:00
2022-04-20 09:36:24 +02:00
2022-05-02 17:03:03 +02:00
2022-05-02 17:03:03 +02:00
2022-05-02 17:03:03 +02:00
2022-04-06 10:50:37 +02:00