freebsd-dev/sys/cam/scsi
Kenneth D. Merry 9fb7b3949c Fix a bug in the CAM SCSI probe code that caused changes in inquiry
data to go undetected.

The probe code does an MD5 checksum of the inquiry data (and page
0x80 serial number if available) before doing a reprobe of an
existing device, and then compares a checksum after the probe to
see whether the device has changed.

This check was broken in January, 2000 by change 56146 when the extended
inquiry probe code was added.

In the extended inquiry probe case, it was calculating the checksum
a second time.  The second time it included the updated inquiry
data from the short inquiry probe (first 36 bytes).  So it wouldn't
catch cases where the vendor, product, revision, etc. changed.

This change will have the effect that when a device's inquiry data is
updated and a rescan is issued, it will disappear and then reappear.
This is the appropriate action, because if the inquiry data or serial
number changes, it is either a different device or the device
configuration may have changed significantly.  (e.g. with updated
firmware.)

scsi_xpt.c:	Don't calculate the initial MD5 checksum on
		standard inquiry data and the page 0x80 serial
		number if we have already calculated it.

MFC after:	1 week
Sponsored by:	Spectra Logic
2015-01-08 16:27:56 +00:00
..
scsi_all.c Improve CAM's reaction on asymmetric access errors. 2014-11-12 01:28:28 +00:00
scsi_all.h Add GET LBA STATUS command support to CTL. 2014-12-04 11:34:19 +00:00
scsi_cd.c Pull in r267961 and r267973 again. Fix for issues reported will follow. 2014-06-28 03:56:17 +00:00
scsi_cd.h
scsi_ch.c Merge CAM locking changes from the projects/camlock branch to radically 2013-10-21 12:00:26 +00:00
scsi_ch.h Update chio(1) and ch(4) to support reporting element designators. 2013-04-19 20:03:51 +00:00
scsi_da.c Allow a block size of zero to mean 512 bytes, which is the most common 2015-01-08 15:10:25 +00:00
scsi_da.h Add LBPERE mode bit definition. 2014-10-14 08:30:02 +00:00
scsi_dvcfg.h
scsi_enc_internal.h Merge CAM locking changes from the projects/camlock branch to radically 2013-10-21 12:00:26 +00:00
scsi_enc_safte.c Pull in r267961 and r267973 again. Fix for issues reported will follow. 2014-06-28 03:56:17 +00:00
scsi_enc_ses.c Remove instances of variables that were set, but never used. gcc 4.9 2014-03-30 23:43:36 +00:00
scsi_enc.c Merge CAM locking changes from the projects/camlock branch to radically 2013-10-21 12:00:26 +00:00
scsi_enc.h MFprojects/zfsd: 2012-05-24 14:07:44 +00:00
scsi_iu.h
scsi_low.c Lock the scsi_low code and the drivers which use it along with other 2014-11-20 20:50:05 +00:00
scsi_low.h Lock the scsi_low code and the drivers which use it along with other 2014-11-20 20:50:05 +00:00
scsi_message.h
scsi_pass.c Remove instances of variables that were set, but never used. gcc 4.9 2014-03-30 23:43:36 +00:00
scsi_pass.h
scsi_pt.c Merge CAM locking changes from the projects/camlock branch to radically 2013-10-21 12:00:26 +00:00
scsi_pt.h
scsi_sa.c Fix multiple incorrect SYSCTL arguments in the kernel: 2014-10-21 07:31:21 +00:00
scsi_sa.h
scsi_ses.h Fix off by one error in ses_enc_desc_last_byte(). 2012-07-24 13:32:49 +00:00
scsi_sg.c - Add support for SG_GET_SG_TABLESIZE IOCTL to report that we don't support 2014-06-04 12:05:47 +00:00
scsi_sg.h Overhaul CAM SG driver IOCTL interfaces. 2014-06-02 19:53:53 +00:00
scsi_targ_bh.c Merge CAM locking changes from the projects/camlock branch to radically 2013-10-21 12:00:26 +00:00
scsi_target.c Merge CAM locking changes from the projects/camlock branch to radically 2013-10-21 12:00:26 +00:00
scsi_targetio.h
scsi_xpt.c Fix a bug in the CAM SCSI probe code that caused changes in inquiry 2015-01-08 16:27:56 +00:00
smp_all.c Add Serial Management Protocol (SMP) passthrough support to CAM. 2010-11-30 22:39:46 +00:00
smp_all.h Add Serial Management Protocol (SMP) passthrough support to CAM. 2010-11-30 22:39:46 +00:00