• Home
  • Raw
  • Download

Lines Matching refs:starget

543 ahc_linux_target_in_softc(struct scsi_target *starget)  in DEF_SCSI_QCMD()
546 *((struct ahc_softc **)dev_to_shost(&starget->dev)->hostdata); in DEF_SCSI_QCMD()
549 target_offset = starget->id; in DEF_SCSI_QCMD()
550 if (starget->channel != 0) in DEF_SCSI_QCMD()
553 return &ahc->platform_data->starget[target_offset]; in DEF_SCSI_QCMD()
557 ahc_linux_target_alloc(struct scsi_target *starget) in ahc_linux_target_alloc() argument
560 *((struct ahc_softc **)dev_to_shost(&starget->dev)->hostdata); in ahc_linux_target_alloc()
563 struct scsi_target **ahc_targp = ahc_linux_target_in_softc(starget); in ahc_linux_target_alloc()
566 char channel = starget->channel + 'A'; in ahc_linux_target_alloc()
570 target_offset = starget->id; in ahc_linux_target_alloc()
571 if (starget->channel != 0) in ahc_linux_target_alloc()
574 if (starget->channel) in ahc_linux_target_alloc()
581 *ahc_targp = starget; in ahc_linux_target_alloc()
607 spi_max_width(starget) = (flags & CFWIDEB) ? 1 : 0; in ahc_linux_target_alloc()
609 spi_max_offset(starget) = 0; in ahc_linux_target_alloc()
610 spi_min_period(starget) = in ahc_linux_target_alloc()
613 ahc_compile_devinfo(&devinfo, our_id, starget->id, in ahc_linux_target_alloc()
626 ahc_linux_target_destroy(struct scsi_target *starget) in ahc_linux_target_destroy() argument
628 struct scsi_target **ahc_targp = ahc_linux_target_in_softc(starget); in ahc_linux_target_destroy()
638 struct scsi_target *starget = sdev->sdev_target; in ahc_linux_slave_alloc() local
660 spi_period(starget) = 0; in ahc_linux_slave_alloc()
1212 struct scsi_target *starget; in ahc_platform_free() local
1218 starget = ahc->platform_data->starget[i]; in ahc_platform_free()
1219 if (starget != NULL) { in ahc_platform_free()
1220 ahc->platform_data->starget[i] = NULL; in ahc_platform_free()
1593 struct scsi_target *starget; in ahc_send_async() local
1624 starget = ahc->platform_data->starget[target_offset]; in ahc_send_async()
1625 if (starget == NULL) in ahc_send_async()
1629 (spi_dt(starget) ? MSG_EXT_PPR_DT_REQ : 0) in ahc_send_async()
1630 + (spi_qas(starget) ? MSG_EXT_PPR_QAS_REQ : 0) in ahc_send_async()
1631 + (spi_iu(starget) ? MSG_EXT_PPR_IU_REQ : 0); in ahc_send_async()
1633 if (tinfo->curr.period == spi_period(starget) in ahc_send_async()
1634 && tinfo->curr.width == spi_width(starget) in ahc_send_async()
1635 && tinfo->curr.offset == spi_offset(starget) in ahc_send_async()
1640 spi_period(starget) = tinfo->curr.period; in ahc_send_async()
1641 spi_width(starget) = tinfo->curr.width; in ahc_send_async()
1642 spi_offset(starget) = tinfo->curr.offset; in ahc_send_async()
1643 spi_dt(starget) = tinfo->curr.ppr_options & MSG_EXT_PPR_DT_REQ ? 1 : 0; in ahc_send_async()
1644 spi_qas(starget) = tinfo->curr.ppr_options & MSG_EXT_PPR_QAS_REQ ? 1 : 0; in ahc_send_async()
1645 spi_iu(starget) = tinfo->curr.ppr_options & MSG_EXT_PPR_IU_REQ ? 1 : 0; in ahc_send_async()
1646 spi_display_xfer_agreement(starget); in ahc_send_async()
2311 static void ahc_linux_set_width(struct scsi_target *starget, int width) in ahc_linux_set_width() argument
2313 struct Scsi_Host *shost = dev_to_shost(starget->dev.parent); in ahc_linux_set_width()
2318 ahc_compile_devinfo(&devinfo, shost->this_id, starget->id, 0, in ahc_linux_set_width()
2319 starget->channel + 'A', ROLE_INITIATOR); in ahc_linux_set_width()
2325 static void ahc_linux_set_period(struct scsi_target *starget, int period) in ahc_linux_set_period() argument
2327 struct Scsi_Host *shost = dev_to_shost(starget->dev.parent); in ahc_linux_set_period()
2332 starget->channel + 'A', in ahc_linux_set_period()
2333 shost->this_id, starget->id, &tstate); in ahc_linux_set_period()
2346 if (spi_max_width(starget)) in ahc_linux_set_period()
2353 ahc_compile_devinfo(&devinfo, shost->this_id, starget->id, 0, in ahc_linux_set_period()
2354 starget->channel + 'A', ROLE_INITIATOR); in ahc_linux_set_period()
2358 if (spi_width(starget) == 0) in ahc_linux_set_period()
2370 static void ahc_linux_set_offset(struct scsi_target *starget, int offset) in ahc_linux_set_offset() argument
2372 struct Scsi_Host *shost = dev_to_shost(starget->dev.parent); in ahc_linux_set_offset()
2377 starget->channel + 'A', in ahc_linux_set_offset()
2378 shost->this_id, starget->id, &tstate); in ahc_linux_set_offset()
2385 ahc_compile_devinfo(&devinfo, shost->this_id, starget->id, 0, in ahc_linux_set_offset()
2386 starget->channel + 'A', ROLE_INITIATOR); in ahc_linux_set_offset()
2399 static void ahc_linux_set_dt(struct scsi_target *starget, int dt) in ahc_linux_set_dt() argument
2401 struct Scsi_Host *shost = dev_to_shost(starget->dev.parent); in ahc_linux_set_dt()
2406 starget->channel + 'A', in ahc_linux_set_dt()
2407 shost->this_id, starget->id, &tstate); in ahc_linux_set_dt()
2416 if (dt && spi_max_width(starget)) { in ahc_linux_set_dt()
2419 ahc_linux_set_width(starget, 1); in ahc_linux_set_dt()
2423 ahc_compile_devinfo(&devinfo, shost->this_id, starget->id, 0, in ahc_linux_set_dt()
2424 starget->channel + 'A', ROLE_INITIATOR); in ahc_linux_set_dt()
2438 static void ahc_linux_set_qas(struct scsi_target *starget, int qas)
2440 struct Scsi_Host *shost = dev_to_shost(starget->dev.parent);
2445 starget->channel + 'A',
2446 shost->this_id, starget->id, &tstate);
2457 ahc_compile_devinfo(&devinfo, shost->this_id, starget->id, 0,
2458 starget->channel + 'A', ROLE_INITIATOR);
2467 static void ahc_linux_set_iu(struct scsi_target *starget, int iu)
2469 struct Scsi_Host *shost = dev_to_shost(starget->dev.parent);
2474 starget->channel + 'A',
2475 shost->this_id, starget->id, &tstate);
2486 ahc_compile_devinfo(&devinfo, shost->this_id, starget->id, 0,
2487 starget->channel + 'A', ROLE_INITIATOR);