mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
tests: convert OMAP i2c tests to qgraph
This way, pca9952-test and tmp105-test will run for every machine that exposes an i2c-bus. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
751a7a5d00
commit
93c3fe2a34
5 changed files with 34 additions and 74 deletions
|
@ -187,25 +187,6 @@ void omap_i2c_init(OMAPI2C *s, QTestState *qts, uint64_t addr)
|
|||
s->parent.qts = qts;
|
||||
}
|
||||
|
||||
I2CAdapter *omap_i2c_create(QTestState *qts, uint64_t addr)
|
||||
{
|
||||
OMAPI2C *s = g_malloc0(sizeof(*s));
|
||||
|
||||
omap_i2c_init(s, qts, addr);
|
||||
return &s->parent;
|
||||
}
|
||||
|
||||
void omap_i2c_free(I2CAdapter *i2c)
|
||||
{
|
||||
OMAPI2C *s;
|
||||
|
||||
if (!i2c) {
|
||||
return;
|
||||
}
|
||||
s = container_of(i2c, OMAPI2C, parent);
|
||||
g_free(s);
|
||||
}
|
||||
|
||||
static void omap_i2c_register_nodes(void)
|
||||
{
|
||||
qos_node_create_driver("omap_i2c", NULL);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue