diff options
author | Patrick Venture | 2021-04-12 21:45:19 +0200 |
---|---|---|
committer | Corey Minyard | 2021-04-15 14:09:19 +0200 |
commit | b98ec6896ee88f1dcdd7098af25bcb6ee0fc50f0 (patch) | |
tree | 9c39c2cec1c40dff90f5924e5115e17d17e99d43 /include/hw/i2c | |
parent | Update version for v6.0.0-rc3 release (diff) | |
download | qemu-b98ec6896ee88f1dcdd7098af25bcb6ee0fc50f0.tar.gz qemu-b98ec6896ee88f1dcdd7098af25bcb6ee0fc50f0.tar.xz qemu-b98ec6896ee88f1dcdd7098af25bcb6ee0fc50f0.zip |
hw/i2c: name I2CNode list in I2CBus
To enable passing the current_devs field as a parameter, we need to use
a named struct type.
Tested: BMC firmware with i2c devices booted to userspace.
Signed-off-by: Patrick Venture <venture@google.com>
Reviewed-by: Hao Wu <wuhaotsh@google.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20210412194522.664594-2-venture@google.com>
Signed-off-by: Corey Minyard <cminyard@mvista.com>
Diffstat (limited to 'include/hw/i2c')
-rw-r--r-- | include/hw/i2c/i2c.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/hw/i2c/i2c.h b/include/hw/i2c/i2c.h index 277dd9f2d6..1f7c268c86 100644 --- a/include/hw/i2c/i2c.h +++ b/include/hw/i2c/i2c.h @@ -58,9 +58,11 @@ struct I2CNode { QLIST_ENTRY(I2CNode) next; }; +typedef QLIST_HEAD(I2CNodeList, I2CNode) I2CNodeList; + struct I2CBus { BusState qbus; - QLIST_HEAD(, I2CNode) current_devs; + I2CNodeList current_devs; uint8_t saved_address; bool broadcast; }; |