Author: sbruno
Date: Tue Apr 23 18:29:51 2013
New Revision: 249815
URL: http://svnweb.freebsd.org/changeset/base/249815
Log:
Return a lun count of 1 and a lun id of 0 when CAM attempts a REPORT_LUNS
command on a disk device. This quieseces some noise on the console that
recently appeared.
Obtained from: Yahoo! Inc.
MFC after: 2 weeks
Modified:
head/sys/dev/ciss/ciss.c
Modified: head/sys/dev/ciss/ciss.c
==============================================================================
--- head/sys/dev/ciss/ciss.c Tue Apr 23 17:03:10 2013 (r249814)
+++ head/sys/dev/ciss/ciss.c Tue Apr 23 18:29:51 2013 (r249815)
@@ -3202,6 +3202,19 @@ ciss_cam_emulate(struct ciss_softc *sc,
}
}
+ /*
+ * A CISS target can only ever have one lun per target. REPORT_LUNS
requires
+ * at least one LUN field to be pre created for us, so snag it and fill in
+ * the least significant byte indicating 1 LUN here. Emulate the command
+ * return to shut up warning on console of a CDB error. swb
+ */
+ if (opcode == REPORT_LUNS && csio->dxfer_len > 0) {
+ csio->data_ptr[3] = 8;
+ csio->ccb_h.status |= CAM_REQ_CMP;
+ xpt_done((union ccb *)csio);
+ return(1);
+ }
+
return(0);
}
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"