Home
last modified time | relevance | path

Searched refs:lun (Results 1 – 25 of 243) sorted by relevance

12345678910

/linux/drivers/target/
H A Dtarget_core_tpg.c110 struct se_lun *lun; in core_tpg_add_node_to_devs() local
114 hlist_for_each_entry_rcu(lun, &tpg->tpg_lun_hlist, link) { in core_tpg_add_node_to_devs()
115 if (lun_orig && lun != lun_orig) in core_tpg_add_node_to_devs()
118 dev = rcu_dereference_check(lun->lun_se_dev, in core_tpg_add_node_to_devs()
140 tpg->se_tpg_tfo->tpg_get_tag(tpg), lun->unpacked_lun, in core_tpg_add_node_to_devs()
143 core_enable_device_list_for_node(lun, NULL, lun->unpacked_lun, in core_tpg_add_node_to_devs()
150 core_scsi3_check_aptpl_registration(dev, tpg, lun, acl, in core_tpg_add_node_to_devs()
151 lun->unpacked_lun); in core_tpg_add_node_to_devs()
438 struct se_lun *lun = container_of(ref, struct se_lun, lun_ref); in core_tpg_lun_ref_release() local
440 complete(&lun->lun_shutdown_comp); in core_tpg_lun_ref_release()
[all …]
H A Dtarget_core_alua.c35 struct se_lun *lun, int explicit, int offline);
39 static void __target_attach_tg_pt_gp(struct se_lun *lun,
140 struct se_lun *lun; in target_emulate_report_target_port_groups() local
217 list_for_each_entry(lun, &tg_pt_gp->tg_pt_gp_lun_list, in target_emulate_report_target_port_groups()
228 put_unaligned_be16(lun->lun_tpg->tpg_rtpi, &buf[off]); in target_emulate_report_target_port_groups()
387 struct se_lun *lun; in target_emulate_set_target_port_groups() local
400 list_for_each_entry(lun, &dev->dev_sep_list, in target_emulate_set_target_port_groups()
402 if (lun->lun_tpg->tpg_rtpi != rtpi) in target_emulate_set_target_port_groups()
409 lun, 1, 1)) in target_emulate_set_target_port_groups()
648 struct se_lun *lun = cmd->se_lun; in target_alua_state_check() local
[all …]
H A Dtarget_core_fabric_configfs.c71 struct se_lun *lun; in target_fabric_mappedlun_link() local
83 lun = container_of(to_config_group(lun_ci), struct se_lun, lun_group); in target_fabric_mappedlun_link()
88 if (!lun->lun_se_dev) { in target_fabric_mappedlun_link()
92 if (lun->lun_shutdown) { in target_fabric_mappedlun_link()
97 se_tpg = lun->lun_tpg; in target_fabric_mappedlun_link()
139 return core_dev_add_initiator_node_lun_acl(se_tpg, lacl, lun, lun_access_ro); in target_fabric_mappedlun_link()
148 struct se_lun *lun = container_of(to_config_group(lun_ci), in target_fabric_mappedlun_unlink() local
151 core_dev_del_initiator_node_lun_acl(lun, lacl); in target_fabric_mappedlun_unlink()
522 struct se_lun *lun = item_to_lun(item); in target_fabric_port_alua_tg_pt_gp_show() local
524 if (!lun->lun_se_dev) in target_fabric_port_alua_tg_pt_gp_show()
[all …]
H A Dtarget_core_stat.c349 CONFIGFS_ATTR_RO(target_stat_lu_, lun);
427 struct se_lun *lun = to_stat_port(item); in target_stat_port_inst_show() local
432 dev = rcu_dereference(lun->lun_se_dev); in target_stat_port_inst_show()
441 struct se_lun *lun = to_stat_port(item); in target_stat_port_dev_show() local
446 dev = rcu_dereference(lun->lun_se_dev); in target_stat_port_dev_show()
455 struct se_lun *lun = to_stat_port(item); in target_stat_port_indx_show() local
460 dev = rcu_dereference(lun->lun_se_dev); in target_stat_port_indx_show()
462 ret = snprintf(page, PAGE_SIZE, "%u\n", lun->lun_tpg->tpg_rtpi); in target_stat_port_indx_show()
469 struct se_lun *lun = to_stat_port(item); in target_stat_port_role_show() local
474 dev = rcu_dereference(lun->lun_se_dev); in target_stat_port_role_show()
[all …]
H A Dtarget_core_device.c208 struct se_lun *lun; in core_get_se_deve_from_rtpi() local
213 lun = deve->se_lun; in core_get_se_deve_from_rtpi()
214 if (!lun) { in core_get_se_deve_from_rtpi()
220 if (lun->lun_tpg->tpg_rtpi != rtpi) in core_get_se_deve_from_rtpi()
287 struct se_lun *lun; in target_dev_ua_allocate() local
290 list_for_each_entry(lun, &dev->dev_sep_list, lun_dev_link) { in target_dev_ua_allocate()
292 spin_lock(&lun->lun_deve_lock); in target_dev_ua_allocate()
293 list_for_each_entry(se_deve, &lun->lun_deve_list, lun_link) in target_dev_ua_allocate()
295 spin_unlock(&lun->lun_deve_lock); in target_dev_ua_allocate()
317 struct se_lun *lun, in core_enable_device_list_for_node() argument
[all …]
/linux/drivers/scsi/
H A Dscsi_common.c133 u64 lun; in scsilun_to_int() local
135 lun = 0; in scsilun_to_int()
136 for (i = 0; i < sizeof(lun); i += 2) in scsilun_to_int()
137 lun = lun | (((u64)scsilun->scsi_lun[i] << ((i + 1) * 8)) | in scsilun_to_int()
139 return lun; in scsilun_to_int()
158 void int_to_scsilun(u64 lun, struct scsi_lun *scsilun) in int_to_scsilun() argument
164 for (i = 0; i < sizeof(lun); i += 2) { in int_to_scsilun()
165 scsilun->scsi_lun[i] = (lun >> 8) & 0xFF; in int_to_scsilun()
166 scsilun->scsi_lun[i+1] = lun & 0xFF; in int_to_scsilun()
167 lun = lun >> 16; in int_to_scsilun()
H A Dsd_trace.h27 __field( unsigned int, lun )
36 __entry->lun = cmnd->device->lun;
43 __entry->lun, __entry->lba, __entry->wp_offset)
57 __field( unsigned int, lun )
67 __entry->lun = cmnd->device->lun;
76 __entry->lun, __entry->rq_sector, __entry->wp_offset,
H A Dvirtio_scsi.c284 unsigned int target = event->lun[1]; in virtscsi_handle_transport_reset()
285 unsigned int lun = (event->lun[2] << 8) | event->lun[3]; in virtscsi_handle_transport_reset() local
289 if (lun == 0) { in virtscsi_handle_transport_reset()
293 scsi_add_device(shost, 0, target, lun); in virtscsi_handle_transport_reset()
297 sdev = scsi_device_lookup(shost, 0, target, lun); in virtscsi_handle_transport_reset()
303 shost->host_no, target, lun); in virtscsi_handle_transport_reset()
316 unsigned int target = event->lun[1]; in virtscsi_handle_param_change()
317 unsigned int lun = (event->lun[2] << 8) | event->lun[3]; in virtscsi_handle_param_change() local
321 sdev = scsi_device_lookup(shost, 0, target, lun); in virtscsi_handle_param_change()
324 shost->host_no, target, lun); in virtscsi_handle_param_change()
[all …]
H A Dscsi_scan.c281 u64 lun, void *hostdata) in scsi_alloc_sdev() argument
301 sdev->lun = lun; in scsi_alloc_sdev()
938 if (scsi_is_wlun(sdev->lun) && sdev->type != TYPE_WLUN) { in scsi_add_lun()
941 __func__, sdev->type, (unsigned int)sdev->lun); in scsi_add_lun()
1184 u64 lun, blist_flags_t *bflagsp, in scsi_probe_and_add_lun() argument
1199 sdev = scsi_device_lookup_by_target(starget, lun); in scsi_probe_and_add_lun()
1218 sdev = scsi_alloc_sdev(starget, lun, hostdata); in scsi_probe_and_add_lun()
1254 if (lun == 0) { in scsi_probe_and_add_lun()
1293 !scsi_is_wlun(lun)) { in scsi_probe_and_add_lun()
1346 u64 sparse_lun, lun; in scsi_sequential_lun_scan() local
[all …]
H A D53c700.c434 NCR_700_identify(int can_disconnect, __u8 lun) in NCR_700_identify() argument
438 (lun & NCR_700_LUN_MASK); in NCR_700_identify()
799 __u8 pun = 0xff, lun = 0xff; in process_extended_message() local
803 lun = SCp->device->lun; in process_extended_message()
848 host->host_no, pun, lun); in process_extended_message()
858 host->host_no, pun, lun, in process_extended_message()
880 __u8 pun = 0xff, lun = 0xff; in process_message() local
884 lun = SCp->device->lun; in process_message()
888 printk("scsi%d (%d:%d): message %s: ", host->host_no, pun, lun, in process_message()
922 pun, lun, in process_message()
[all …]
H A Dscsi_proc.c285 sdev->host->host_no, sdev->channel, sdev->id, sdev->lun); in proc_print_scsidevice()
338 static int scsi_add_single_device(uint host, uint channel, uint id, uint lun) in scsi_add_single_device() argument
348 error = shost->transportt->user_scan(shost, channel, id, lun); in scsi_add_single_device()
350 error = scsi_scan_host_selected(shost, channel, id, lun, in scsi_add_single_device()
366 static int scsi_remove_single_device(uint host, uint channel, uint id, uint lun) in scsi_remove_single_device() argument
375 sdev = scsi_device_lookup(shost, channel, id, lun); in scsi_remove_single_device()
408 int host, channel, id, lun; in proc_scsi_write() local
443 lun = (p + 1 < end) ? simple_strtoul(p + 1, &p, 0) : 0; in proc_scsi_write()
445 err = scsi_add_single_device(host, channel, id, lun); in proc_scsi_write()
457 lun = (p + 1 < end) ? simple_strtoul(p + 1, &p, 0) : 0; in proc_scsi_write()
[all …]
H A Dwd33c93.c435 (1 << (cmd->device->lun & 0xff)))) in DEF_SCSI_QCMD()
506 (prev->device->lun != cmd->device->lun)) { in DEF_SCSI_QCMD()
527 write_wd33c93(regs, WD_TARGET_LUN, (u8)cmd->device->lun); in DEF_SCSI_QCMD()
530 hostdata->busy[cmd->device->id] |= (1 << (cmd->device->lun & 0xFF)); in DEF_SCSI_QCMD()
741 uchar asr, sr, phs, id, lun, *ucp, msg; in wd33c93_intr() local
800 hostdata->busy[cmd->device->id] &= ~(1 << (cmd->device->lun & 0xff)); in wd33c93_intr()
833 hostdata->outgoing_msg[0] = IDENTIFY(0, cmd->device->lun); in wd33c93_intr()
1114 lun = read_wd33c93(regs, WD_TARGET_LUN); in wd33c93_intr()
1115 DB(DB_INTR, printk(":%d.%d", scsi_pointer->Status, lun)) in wd33c93_intr()
1117 hostdata->busy[cmd->device->id] &= ~(1 << (cmd->device->lun & 0xff)); in wd33c93_intr()
[all …]
H A Dqla1280.h513 uint8_t lun; /* SCSI LUN */ member
599 uint8_t lun; /* SCSI LUN */ member
620 uint8_t lun; /* SCSI LUN */ member
640 uint8_t lun; /* SCSI LUN */ member
686 __le16 lun; /* Bit 15 is bus number. */ member
714 uint8_t lun; /* SCSI LUN */ member
739 uint8_t lun; member
765 uint8_t lun; member
786 uint8_t lun; member
809 uint8_t lun; /* SCSI LUN */ member
[all …]
/linux/drivers/usb/gadget/function/
H A Df_mass_storage.c259 unsigned int lun; member
1728 unsigned int lun = common->cmnd[1] >> 5; in check_command() local
1793 if (common->lun != lun) in check_command()
1795 common->lun, lun); in check_command()
1814 DBG(common, "unsupported LUN %u\n", common->lun); in check_command()
2245 common->lun = cbw->Lun; in received_cbw()
2246 if (common->lun < ARRAY_SIZE(common->luns)) in received_cbw()
2247 common->curlun = common->luns[common->lun]; in received_cbw()
2778 void fsg_common_remove_lun(struct fsg_lun *lun) in fsg_common_remove_lun() argument
2780 if (device_is_registered(&lun->dev)) in fsg_common_remove_lun()
[all …]
/linux/drivers/scsi/aic94xx/
H A Daic94xx_tmf.c201 static int asd_clear_nexus_I_T_L(struct domain_device *dev, u8 *lun) in asd_clear_nexus_I_T_L() argument
208 memcpy(scb->clear_nexus.ssp_task.lun, lun, 8); in asd_clear_nexus_I_T_L()
221 memcpy(scb->clear_nexus.ssp_task.lun, task->ssp_task.LUN, 8); in asd_clear_nexus_tag()
443 memcpy(scb->abort_task.ssp_task.lun, task->ssp_task.LUN, 8); in asd_abort_task()
556 static int asd_initiate_ssp_tmf(struct domain_device *dev, u8 *lun, in asd_initiate_ssp_tmf() argument
592 memcpy(scb->ssp_tmf.ssp_task.lun, lun, 8); in asd_initiate_ssp_tmf()
638 int asd_abort_task_set(struct domain_device *dev, u8 *lun) in asd_abort_task_set() argument
640 int res = asd_initiate_ssp_tmf(dev, lun, TMF_ABORT_TASK_SET, 0); in asd_abort_task_set()
643 asd_clear_nexus_I_T_L(dev, lun); in asd_abort_task_set()
647 int asd_clear_task_set(struct domain_device *dev, u8 *lun) in asd_clear_task_set() argument
[all …]
H A Daic94xx.h62 int asd_abort_task_set(struct domain_device *, u8 *lun);
63 int asd_clear_task_set(struct domain_device *, u8 *lun);
64 int asd_lu_reset(struct domain_device *, u8 *lun);
/linux/include/uapi/linux/
H A Dvirtio_scsi.h45 __u8 lun[8]; /* Logical Unit Number */ member
55 __u8 lun[8]; /* Logical Unit Number */ member
79 __u8 lun[8]; member
90 __u8 lun[8]; member
101 __u8 lun[8]; member
/linux/drivers/s390/scsi/
H A Dzfcp_unit.c25 u64 lun; in zfcp_unit_scsi_scan() local
27 lun = scsilun_to_int((struct scsi_lun *) &unit->fcp_lun); in zfcp_unit_scsi_scan()
30 scsi_scan_target(&rport->dev, 0, rport->scsi_target_id, lun, in zfcp_unit_scsi_scan()
199 u64 lun; in zfcp_unit_sdev() local
201 lun = scsilun_to_int((struct scsi_lun *) &unit->fcp_lun); in zfcp_unit_sdev()
204 return scsi_device_lookup(shost, 0, port->starget_id, lun); in zfcp_unit_sdev()
/linux/drivers/scsi/arm/
H A Dqueue.c172 (u8)(q->SCpnt->device->lun & 0x7), exclude)) { in queue_remove_exclude()
210 struct scsi_cmnd *queue_remove_tgtluntag(Queue_t *queue, int target, int lun, in queue_remove_tgtluntag() argument
220 if (q->SCpnt->device->id == target && q->SCpnt->device->lun == lun && in queue_remove_tgtluntag()
261 int queue_probetgtlun (Queue_t *queue, int target, int lun) in queue_probetgtlun() argument
270 if (q->SCpnt->device->id == target && q->SCpnt->device->lun == lun) { in queue_probetgtlun()
/linux/include/scsi/
H A Dscsi.h62 static inline int scsi_is_wlun(u64 lun) in scsi_is_wlun() argument
64 return (lun & 0xff00) == SCSI_W_LUN_BASE; in scsi_is_wlun()
143 #define IDENTIFY(can_disconnect, lun) (IDENTIFY_BASE |\ argument
145 ((lun) & 0x07))
H A Discsi_proto.h82 struct scsi_lun lun; member
144 struct scsi_lun lun; member
220 struct scsi_lun lun; member
248 struct scsi_lun lun; member
263 struct scsi_lun lun; member
279 struct scsi_lun lun; member
337 struct scsi_lun lun; member
355 struct scsi_lun lun; member
375 struct scsi_lun lun; member
581 uint8_t lun[8]; member
/linux/drivers/scsi/isci/
H A Dtask.h88 unsigned char lun[8]; member
143 u8 *lun);
147 u8 *lun);
154 u8 *lun);
/linux/drivers/scsi/aic7xxx/
H A Daic79xx.h84 ((scb)->hscb->lun)
104 #define BUILD_TCL(scsiid, lun) \ argument
105 ((lun) | (((scsiid) & TID) << 4))
106 #define BUILD_TCL_RAW(target, channel, lun) \ argument
107 ((lun) | ((target) << 8))
117 #define AHD_BUILD_COL_IDX(target, lun) \ argument
118 ((((u8)lun) << 4) | target)
126 (scb)->hscb->lun = ((col_idx) >> 4) & (AHD_NUM_LUNS_NONPKT-1); \
132 dst->hscb->lun = src->hscb->lun; \
496 /*20*/ uint8_t lun; member
[all …]
H A Daic79xx_proc.c163 int lun; in ahd_dump_target_state() local
179 for (lun = 0; lun < AHD_NUM_LUNS; lun++) { in ahd_dump_target_state()
182 dev = scsi_device_lookup_by_target(starget, lun); in ahd_dump_target_state()
198 sdev->sdev_target->id, (u8)sdev->lun); in ahd_dump_device_state()
/linux/drivers/scsi/snic/
H A Dsnic_res.h15 u16 flags, u64 tgt_id, u8 *lun, u8 *scsi_cdb, u8 cdb_len, in snic_icmnd_init() argument
24 memcpy(&req->u.icmnd.lun_id, lun, LUN_ADDR_LEN); in snic_icmnd_init()
36 u16 flags, u32 req_id, u64 tgt_id, u8 *lun, u8 tm_type) in snic_itmf_init() argument
45 memcpy(&req->u.itmf.lun_id, lun, LUN_ADDR_LEN); in snic_itmf_init()

12345678910