Skip to content

Commit

Permalink
[SCSI] aic7xxx/79xx: fix another potential panic due to a non existen…
Browse files Browse the repository at this point in the history
…t target

I ran into this one sending bus resets across the hardware.

Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
  • Loading branch information
James Bottomley authored and James Bottomley committed Aug 5, 2005
1 parent 79778a2 commit fc789a9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions drivers/scsi/aic7xxx/aic79xx_osm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1617,9 +1617,9 @@ ahd_send_async(struct ahd_softc *ahd, char channel,
* are identical to those last reported.
*/
starget = ahd->platform_data->starget[target];
targ = scsi_transport_target_data(starget);
if (targ == NULL)
if (starget == NULL)
break;
targ = scsi_transport_target_data(starget);

target_ppr_options =
(spi_dt(starget) ? MSG_EXT_PPR_DT_REQ : 0)
Expand Down
4 changes: 2 additions & 2 deletions drivers/scsi/aic7xxx/aic7xxx_osm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1618,9 +1618,9 @@ ahc_send_async(struct ahc_softc *ahc, char channel,
if (channel == 'B')
target_offset += 8;
starget = ahc->platform_data->starget[target_offset];
targ = scsi_transport_target_data(starget);
if (targ == NULL)
if (starget == NULL)
break;
targ = scsi_transport_target_data(starget);

target_ppr_options =
(spi_dt(starget) ? MSG_EXT_PPR_DT_REQ : 0)
Expand Down

0 comments on commit fc789a9

Please sign in to comment.