/* set slave device's address witdh on target I2C channel */
aos_status_t aos_i2c_addr_width_set(i2c_dev_handle_t dev_h, uint32_t addr_width)
/* set slave device's address witdh on target I2C channel */
aos_status_t aos_i2c_addr_width_set(i2c_dev_handle_t dev_h, uint32_t addr_width)
{
        ddkc_err("invalid dev:%p, 0x%x\r\n", dev_h, !dev_h ? 0 : *dev_h);
        return -EINVAL;
    }
    slave = aos_container_of(dev_h, i2c_slave_dev_t, i2c_dev_handle);
    status = aos_mutex_lock(&slave->lock, AOS_WAIT_FOREVER);
    if (status) {
        ddkc_warn("lock i2c slave 0x%x failed, status:%d\r\n", slave->config.addr, status);
        return -EIO;
    }
    slave->config.addr_width = addr_width;
    status = aos_mutex_unlock(&slave->lock);
    if (status) {
        ddkc_warn("THIS SHOULD NEVER HAPPEN - unlock i2c slave 0x%x failed, status:%d\r\n", slave->config.addr, status);
    }
    return status;
}