summary refs log tree commit diff stats
path: root/hw/misc/meson.build
diff options
context:
space:
mode:
authorKlaus Jensen <k.jensen@samsung.com>2023-03-02 13:57:50 +0100
committerCédric Le Goater <clg@kaod.org>2023-03-02 13:57:50 +0100
commitb14037f37f913a21eddadb1e4b53a2f7adf720ad (patch)
tree9d2854fb48c58625307789b36747d7e5cfe91774 /hw/misc/meson.build
parent791cb95f23045f2d69364786edf61d289889199d (diff)
downloadfocaccia-qemu-b14037f37f913a21eddadb1e4b53a2f7adf720ad.tar.gz
focaccia-qemu-b14037f37f913a21eddadb1e4b53a2f7adf720ad.zip
hw/misc: add a toy i2c echo device
Add an example I2C device to demonstrate how a slave may master the bus
and send data asynchronously to another slave.

The device will echo whatever it is sent to the device identified by the
first byte received.

Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
[ clg: integrated fixes :
  https://lore.kernel.org/qemu-devel/Y3yMKAhOkYGtnkOp@cormorant.local/ ]
Message-Id: <20220601210831.67259-7-its@irrelevant.dk>
Signed-off-by: Cédric Le Goater <clg@kaod.org>
Diffstat (limited to 'hw/misc/meson.build')
-rw-r--r--hw/misc/meson.build2
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/misc/meson.build b/hw/misc/meson.build
index fe869b98ca..a40245ad44 100644
--- a/hw/misc/meson.build
+++ b/hw/misc/meson.build
@@ -128,6 +128,8 @@ softmmu_ss.add(when: 'CONFIG_NRF51_SOC', if_true: files('nrf51_rng.c'))
 
 softmmu_ss.add(when: 'CONFIG_GRLIB', if_true: files('grlib_ahb_apb_pnp.c'))
 
+softmmu_ss.add(when: 'CONFIG_I2C', if_true: files('i2c-echo.c'))
+
 specific_ss.add(when: 'CONFIG_AVR_POWER', if_true: files('avr_power.c'))
 
 specific_ss.add(when: 'CONFIG_MAC_VIA', if_true: files('mac_via.c'))