kernel/cam: Fix I/O performance regression seen at least in VMware ESXi.
authorSascha Wildner <saw@online.de>
Sun, 25 Aug 2013 18:15:37 +0000 (20:15 +0200)
committerSascha Wildner <saw@online.de>
Sun, 25 Aug 2013 18:16:44 +0000 (20:16 +0200)
commit6464358ede0a7784dfef13f5c9cb9d469cd6c48f
tree67b8bf59ca5c1f56874675007afe1162c9fcd04b
parentecba31f930b472cf033ea19b67972333b3355cf9
kernel/cam: Fix I/O performance regression seen at least in VMware ESXi.

This brings in FreeBSD's revisions 188570, 188670, 188671 and 188688.
188670 (most changed lines in the patch) is for debugging purposes only,
while 188570 and 188671 fix the actual issue and 188688 fixes gcc whining.

Reported-and-tested-by: Dongsheng Song <dongsheng.song@gmail.com>
Extra credit to vsrinivas who had actually pointed out 188570 to us a
while ago before it hit us now but at the time I hadn't noticed.

Quoting FreeBSD's commit messages:

r188570
-------
In the case that the probe has determined that it can't query the device
for a serial number, fall through to the next case so that initial
negotiation still happens.  Without this, devices were showing up with
only 1 available tag opening, leading to observations of very poor I/O
performance.

This should fix problems reported with VMWare Fusion and ESX.  Early
generation MPT-SAS controllers with SATA disks might also be affected.
HP CISS controllers are also likely affected, as are many other
pseudo-scsi disk subsystems.

r188671
-------
Fix parallel SCSI negotiation in the CAM_NEW_TRAN_CODE world order.
Overzealous sanity checks were locking the sync_rate and offset values
to zero, thanks to a twisty maze of recursive code.
sys/bus/cam/cam_xpt.c