Lines Matching refs:use_sg
3263 int use_sg, i, sg_index, chained; in hpsa_scatter_gather() local
3268 use_sg = scsi_dma_map(cmd); in hpsa_scatter_gather()
3269 if (use_sg < 0) in hpsa_scatter_gather()
3270 return use_sg; in hpsa_scatter_gather()
3272 if (!use_sg) in hpsa_scatter_gather()
3278 scsi_for_each_sg(cmd, sg, use_sg, i) { in hpsa_scatter_gather()
3280 use_sg > h->max_cmd_sg_entries) { in hpsa_scatter_gather()
3292 if (use_sg + chained > h->maxSG) in hpsa_scatter_gather()
3293 h->maxSG = use_sg + chained; in hpsa_scatter_gather()
3297 cp->Header.SGTotal = cpu_to_le16(use_sg + 1); in hpsa_scatter_gather()
3307 cp->Header.SGList = (u8) use_sg; /* no. SGs contig in this cmd */ in hpsa_scatter_gather()
3308 cp->Header.SGTotal = cpu_to_le16(use_sg); /* total sgs in cmd list */ in hpsa_scatter_gather()
3370 int use_sg, i; in hpsa_scsi_ioaccel1_queue_command() local
3394 use_sg = scsi_dma_map(cmd); in hpsa_scsi_ioaccel1_queue_command()
3395 if (use_sg < 0) { in hpsa_scsi_ioaccel1_queue_command()
3397 return use_sg; in hpsa_scsi_ioaccel1_queue_command()
3400 if (use_sg) { in hpsa_scsi_ioaccel1_queue_command()
3402 scsi_for_each_sg(cmd, sg, use_sg, i) { in hpsa_scsi_ioaccel1_queue_command()
3433 c->Header.SGList = use_sg; in hpsa_scsi_ioaccel1_queue_command()
3527 int use_sg, i; in hpsa_scsi_ioaccel2_queue_command() local
3552 use_sg = scsi_dma_map(cmd); in hpsa_scsi_ioaccel2_queue_command()
3553 if (use_sg < 0) { in hpsa_scsi_ioaccel2_queue_command()
3555 return use_sg; in hpsa_scsi_ioaccel2_queue_command()
3558 if (use_sg) { in hpsa_scsi_ioaccel2_queue_command()
3559 BUG_ON(use_sg > IOACCEL2_MAXSGENTRIES); in hpsa_scsi_ioaccel2_queue_command()
3561 scsi_for_each_sg(cmd, sg, use_sg, i) { in hpsa_scsi_ioaccel2_queue_command()
3606 cp->sg_count = (u8) use_sg; in hpsa_scsi_ioaccel2_queue_command()