diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2017-09-26 19:49:08 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2017-09-26 19:49:08 +0100 |
commit | 31bc1d8481af414cfa2857f905e40f7d8e6d5b2e (patch) | |
tree | 4f7198397d7f32c8880490f69b91e5d50731e678 /hw/misc/auxbus.c | |
parent | 2509dda283d438970028864dd89871bfe0263c3a (diff) | |
parent | 35deebb2327227d8c5f4816476befb06f6329de6 (diff) |
Merge remote-tracking branch 'remotes/mjt/tags/trivial-patches-fetch' into staging
trivial patches for 2017-09-26
# gpg: Signature made Tue 26 Sep 2017 07:13:16 BST
# gpg: using RSA key 0x701B4F6B1A693E59
# gpg: Good signature from "Michael Tokarev <mjt@tls.msk.ru>"
# gpg: aka "Michael Tokarev <mjt@corpit.ru>"
# gpg: aka "Michael Tokarev <mjt@debian.org>"
# Primary key fingerprint: 6EE1 95D1 886E 8FFB 810D 4324 457C E0A0 8044 65C5
# Subkey fingerprint: 7B73 BAD6 8BE7 A2C2 8931 4B22 701B 4F6B 1A69 3E59
* remotes/mjt/tags/trivial-patches-fetch: (29 commits)
hw/isa/pc87312: Mark the device with user_creatable = false
Drop gld linker usage on SunOS
tests/boot-sector: Increase timeout to 600 seconds
nbd-client: Use correct macro parenthesization
hw/display/virtio-gpu: Put the virtio-gpu-device into the display category
osdep: Fix ROUND_UP(64-bit, 32-bit)
target/xtensa: Use the pre-defined MEMTXATTRS_UNSPECIFIED macro
trivial: Add missing "-m" parameter in docs/memory-hotplug.txt
chardev/baum: fix baum that releases brlapi twice
remove trailing whitespace from qemu-options.hx
hw/display/xenfb.c: Add trace_xenfb_key_event
aux-to-i2c-bridge: don't allow user to create one
util/qemu-thread-posix.c: Replace OS ifdefs with CONFIG_HAVE_SEM_TIMEDWAIT
MAINTAINERS: update docs/interop/ entries
MAINTAINERS: update docs/devel/ entries
MAINTAINERS: add missing Cryptography entry
MAINTAINERS: add missing entry for Generic Loader
MAINTAINERS: add missing AIO entry
MAINTAINERS: add missing entries for throttling infra
MAINTAINERS: add missing SSI entries
...
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/misc/auxbus.c')
-rw-r--r-- | hw/misc/auxbus.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/hw/misc/auxbus.c b/hw/misc/auxbus.c index 8a90ddda84..1182745044 100644 --- a/hw/misc/auxbus.c +++ b/hw/misc/auxbus.c @@ -210,6 +210,16 @@ struct AUXTOI2CState { I2CBus *i2c_bus; }; +static void aux_bridge_class_init(ObjectClass *oc, void *data) +{ + DeviceClass *dc = DEVICE_CLASS(oc); + + /* This device is private and is created only once for each + * aux-bus in aux_init_bus(..). So don't allow the user to add one. + */ + dc->user_creatable = false; +} + static void aux_bridge_init(Object *obj) { AUXTOI2CState *s = AUXTOI2C(obj); @@ -225,6 +235,7 @@ static inline I2CBus *aux_bridge_get_i2c_bus(AUXTOI2CState *bridge) static const TypeInfo aux_to_i2c_type_info = { .name = TYPE_AUXTOI2C, .parent = TYPE_DEVICE, + .class_init = aux_bridge_class_init, .instance_size = sizeof(AUXTOI2CState), .instance_init = aux_bridge_init }; |