Lines Matching refs:dev_num
177 if (slave->dev_num) { /* clear dev_num if assigned */ in sdw_delete_slave()
178 clear_bit(slave->dev_num, bus->assigned); in sdw_delete_slave()
279 msg->dev_num, ret, in sdw_transfer_unlocked()
353 msg->dev_num, ret); in sdw_transfer_defer()
359 u32 addr, size_t count, u16 dev_num, u8 flags, u8 *buf) in sdw_fill_msg() argument
364 msg->dev_num = dev_num; in sdw_fill_msg()
383 if (dev_num == SDW_ENUM_DEV_NUM || dev_num == SDW_BROADCAST_DEV_NUM) { in sdw_fill_msg()
384 pr_err("SDW: Invalid device for paging :%d\n", dev_num); in sdw_fill_msg()
422 ret = sdw_fill_msg(&msg, slave, addr, size, slave->dev_num, flags, val); in sdw_ntransfer_no_pm()
483 sdw_bread_no_pm(struct sdw_bus *bus, u16 dev_num, u32 addr) in sdw_bread_no_pm() argument
489 ret = sdw_fill_msg(&msg, NULL, addr, 1, dev_num, in sdw_bread_no_pm()
502 sdw_bwrite_no_pm(struct sdw_bus *bus, u16 dev_num, u32 addr, u8 value) in sdw_bwrite_no_pm() argument
507 ret = sdw_fill_msg(&msg, NULL, addr, 1, dev_num, in sdw_bwrite_no_pm()
515 int sdw_bread_no_pm_unlocked(struct sdw_bus *bus, u16 dev_num, u32 addr) in sdw_bread_no_pm_unlocked() argument
521 ret = sdw_fill_msg(&msg, NULL, addr, 1, dev_num, in sdw_bread_no_pm_unlocked()
534 int sdw_bwrite_no_pm_unlocked(struct sdw_bus *bus, u16 dev_num, u32 addr, u8 value) in sdw_bwrite_no_pm_unlocked() argument
539 ret = sdw_fill_msg(&msg, NULL, addr, 1, dev_num, in sdw_bwrite_no_pm_unlocked()
701 if (slave->dev_num == i) in sdw_get_slave()
752 int ret, dev_num; in sdw_assign_device_num() local
756 if (!slave->dev_num) { in sdw_assign_device_num()
759 dev_num = sdw_get_device_num(slave); in sdw_assign_device_num()
761 if (dev_num < 0) { in sdw_assign_device_num()
763 dev_num); in sdw_assign_device_num()
764 return dev_num; in sdw_assign_device_num()
766 slave->dev_num = dev_num; in sdw_assign_device_num()
767 slave->dev_num_sticky = dev_num; in sdw_assign_device_num()
770 slave->dev_num = slave->dev_num_sticky; in sdw_assign_device_num()
777 slave->dev_num); in sdw_assign_device_num()
780 dev_num = slave->dev_num; in sdw_assign_device_num()
781 slave->dev_num = 0; in sdw_assign_device_num()
783 ret = sdw_write_no_pm(slave, SDW_SCP_DEVNUMBER, dev_num); in sdw_assign_device_num()
786 dev_num, ret); in sdw_assign_device_num()
791 slave->dev_num = slave->dev_num_sticky; in sdw_assign_device_num()
794 bus->ops->new_peripheral_assigned(bus, slave, dev_num); in sdw_assign_device_num()
928 slave->dev_num, slave->status, status); in sdw_modify_slave_status()
933 slave->dev_num); in sdw_modify_slave_status()
942 slave->dev_num); in sdw_modify_slave_status()
1008 static int sdw_bus_wait_for_clk_prep_deprep(struct sdw_bus *bus, u16 dev_num, bool prepare) in sdw_bus_wait_for_clk_prep_deprep() argument
1014 val = sdw_bread_no_pm(bus, dev_num, SDW_SCP_STAT); in sdw_bus_wait_for_clk_prep_deprep()
1024 dev_num); in sdw_bus_wait_for_clk_prep_deprep()
1034 dev_num); in sdw_bus_wait_for_clk_prep_deprep()
1062 if (!slave->dev_num) in sdw_bus_prep_clk_stop()
1117 if (!slave->dev_num) in sdw_bus_prep_clk_stop()
1188 if (!slave->dev_num) in sdw_bus_exit_clk_stop()
1230 if (!slave->dev_num) in sdw_bus_exit_clk_stop()
1967 slave->dev_num); in sdw_handle_slave_status()