diff options
author | Jianeng Ceng <cengjianeng@huaqin.corp-partner.google.com> | 2024-04-25 17:24:03 +0800 |
---|---|---|
committer | Subrata Banik <subratabanik@google.com> | 2024-04-28 18:27:40 +0000 |
commit | 05ee5c21b4ae8e2723b1340886b0b53e408f2a05 (patch) | |
tree | b5ac4adf20a2b21a1013735b134fff41f4311b9e | |
parent | fce08d78837431a3309d2b8705555fd81bd09c29 (diff) |
acpi: Fix return value in acpi_device_write_dsd_gpio()
Fix ++ as suffix and * precedence. After modification, the gpio index
can be obtained correctly.
The error was introduced in the commit making it public:
commit 01344bce
BUG=None
TEST= Can get the correct index test on nissa.
Change-Id: I7a3eb89633aaebebc8bd98ac6126c578fda23839
Signed-off-by: Jianeng Ceng <cengjianeng@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/82088
Reviewed-by: Eric Lai <ericllai@google.com>
Reviewed-by: Dolan Liu <liuyong5@huaqin.corp-partner.google.com>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
-rw-r--r-- | src/acpi/device.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/acpi/device.c b/src/acpi/device.c index 091a0865a1..7313639afa 100644 --- a/src/acpi/device.c +++ b/src/acpi/device.c @@ -51,7 +51,7 @@ int acpi_device_write_dsd_gpio(struct acpi_gpio *gpio, int *curr_index) return ret; acpi_device_write_gpio(gpio); - ret = *curr_index++; + ret = (*curr_index)++; return ret; } |