]> Git Repo - qemu.git/blobdiff - include/hw/i2c/smbus.h
smbus: allow returning an error from reads
[qemu.git] / include / hw / i2c / smbus.h
index 63f0cc4788b613a491c809077b96d28606df9bfb..285d3b5de339100522cfb7d659f1d95bff203c95 100644 (file)
@@ -67,11 +67,11 @@ struct SMBusDevice {
 
 /* Master device commands.  */
 void smbus_quick_command(I2CBus *bus, uint8_t addr, int read);
-uint8_t smbus_receive_byte(I2CBus *bus, uint8_t addr);
+int smbus_receive_byte(I2CBus *bus, uint8_t addr);
 void smbus_send_byte(I2CBus *bus, uint8_t addr, uint8_t data);
-uint8_t smbus_read_byte(I2CBus *bus, uint8_t addr, uint8_t command);
+int smbus_read_byte(I2CBus *bus, uint8_t addr, uint8_t command);
 void smbus_write_byte(I2CBus *bus, uint8_t addr, uint8_t command, uint8_t data);
-uint16_t smbus_read_word(I2CBus *bus, uint8_t addr, uint8_t command);
+int smbus_read_word(I2CBus *bus, uint8_t addr, uint8_t command);
 void smbus_write_word(I2CBus *bus, uint8_t addr, uint8_t command, uint16_t data);
 int smbus_read_block(I2CBus *bus, uint8_t addr, uint8_t command, uint8_t *data);
 void smbus_write_block(I2CBus *bus, uint8_t addr, uint8_t command, uint8_t *data,
This page took 0.023618 seconds and 4 git commands to generate.