cam_ccb.h:

Bring back the CAM_NEGOTIATE ccb flag.  This flag indicates
	that SPI transfer negotiation should occur concurrently with the
	execution of this CCB.  The flag is not yet used by the XPT but
	is required for proper support of multi-initiator configurations
	where topology scans cannot rely on a bus reset to invalidate
	prior negotiations.

cam_xpt.c:
	Don't allow DT transmission rates to be specified for devices
	that don't have the DT feature listed in their inquiry data.
This commit is contained in:
Justin T. Gibbs 2000-07-18 19:47:14 +00:00
parent 727a4ed619
commit dd5bac9d0f
2 changed files with 13 additions and 0 deletions

View File

@ -58,6 +58,10 @@ typedef enum {
CAM_CDB_POINTER = 0x00000001,/* The CDB field is a pointer */
CAM_QUEUE_ENABLE = 0x00000002,/* SIM queue actions are enabled */
CAM_CDB_LINKED = 0x00000004,/* CCB contains a linked CDB */
CAM_NEGOTIATE = 0x00000008,/*
* Perform transport negotiation
* with this command.
*/
CAM_SCATTER_VALID = 0x00000010,/* Scatter/gather list is valid */
CAM_DIS_AUTOSENSE = 0x00000020,/* Disable autosense feature */
CAM_DIR_RESV = 0x00000000,/* Data direction (00:reserved) */

View File

@ -5786,6 +5786,15 @@ xpt_set_transfer_settings(struct ccb_trans_settings *cts, struct cam_ed *device,
cts->sync_offset = 0;
}
/*
* Don't allow DT transmission rates if the
* device does not support it.
*/
if ((device->flags & CAM_DEV_INQUIRY_DATA_VALID) != 0
&& (inq_data->spi3data & SID_SPI_CLOCK_DT) == 0
&& cts->sync_period <= 0x9)
cts->sync_period = 0xa;
switch (cts->bus_width) {
case MSG_EXT_WDTR_BUS_32_BIT:
if (((device->flags & CAM_DEV_INQUIRY_DATA_VALID) == 0