aboutsummaryrefslogtreecommitdiff
path: root/hw/i2c.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/i2c.c')
-rw-r--r--hw/i2c.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/hw/i2c.c b/hw/i2c.c
index 627bbfc4e1..e590801af3 100644
--- a/hw/i2c.c
+++ b/hw/i2c.c
@@ -7,7 +7,8 @@
* This code is licenced under the LGPL.
*/
-#include "vl.h"
+#include "hw.h"
+#include "i2c.h"
struct i2c_bus
{
@@ -30,7 +31,7 @@ i2c_slave *i2c_slave_init(i2c_bus *bus, int address, int size)
i2c_slave *dev;
if (size < sizeof(i2c_slave))
- cpu_abort(cpu_single_env, "I2C struct too small");
+ hw_error("I2C struct too small");
dev = (i2c_slave *)qemu_mallocz(size);
dev->address = address;