On 2021/4/1 20:12, Viresh Kumar wrote:
+
+/* vhost-user-i2c definitions */
+
+#define MAX_I2C_VDEV(1 << 7)
+#define MAX_I2C_ADAPTER 16
Generally speaking, 16 is big enough for most cases. But comparing with
static configuration,
I think it is better if we
On 2021/3/24 15:33, Viresh Kumar wrote:
+static int vi2c_parse(VuI2c *i2c)
+{
+uint16_t client_addr[MAX_I2C_VDEV];
+int32_t n_adapter = 0, n_client;
+int64_t addr, bus;
+const char *cp, *t;
+
+while (device_list) {
+/* Read :[:] entries one by one */
+cp =
On 2021/3/24 15:33, Viresh Kumar wrote:
+
+/* Definitions from virtio-i2c specifications */
+#define VHOST_USER_I2C_MAX_QUEUES 1
+
+/* Status */
+#define VIRTIO_I2C_MSG_OK 0
+#define VIRTIO_I2C_MSG_ERR 1
+
+/* The bit 0 of the @virtio_i2c_out_hdr.@flags, used