Commit 0f511ea7 authored by Linus Torvalds's avatar Linus Torvalds

Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6

* master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
  [SCSI] zfcp: fix device registration issues
  [SCSI] scsi_transport_fc: fix FC_HOST_NUM_ATTRS
  [SCSI] scsi: aha152x pcmcia driver needs spi transport
  [SCSI] zfcp: correctly set this_id for hosts
  [SCSI] Add Brownie to blacklist
parents 67963132 ad58f7db
...@@ -664,6 +664,7 @@ do { \ ...@@ -664,6 +664,7 @@ do { \
#define ZFCP_STATUS_UNIT_TEMPORARY 0x00000002 #define ZFCP_STATUS_UNIT_TEMPORARY 0x00000002
#define ZFCP_STATUS_UNIT_SHARED 0x00000004 #define ZFCP_STATUS_UNIT_SHARED 0x00000004
#define ZFCP_STATUS_UNIT_READONLY 0x00000008 #define ZFCP_STATUS_UNIT_READONLY 0x00000008
#define ZFCP_STATUS_UNIT_REGISTERED 0x00000010
/* FSF request status (this does not have a common part) */ /* FSF request status (this does not have a common part) */
#define ZFCP_STATUS_FSFREQ_NOT_INIT 0x00000000 #define ZFCP_STATUS_FSFREQ_NOT_INIT 0x00000000
......
...@@ -3391,10 +3391,13 @@ zfcp_erp_action_cleanup(int action, struct zfcp_adapter *adapter, ...@@ -3391,10 +3391,13 @@ zfcp_erp_action_cleanup(int action, struct zfcp_adapter *adapter,
&& (!atomic_test_mask(ZFCP_STATUS_UNIT_TEMPORARY, && (!atomic_test_mask(ZFCP_STATUS_UNIT_TEMPORARY,
&unit->status)) &unit->status))
&& !unit->device && !unit->device
&& port->rport) && port->rport) {
scsi_add_device(port->adapter->scsi_host, 0, atomic_set_mask(ZFCP_STATUS_UNIT_REGISTERED,
&unit->status);
scsi_scan_target(&port->rport->dev, 0,
port->rport->scsi_target_id, port->rport->scsi_target_id,
unit->scsi_lun); unit->scsi_lun, 0);
}
zfcp_unit_put(unit); zfcp_unit_put(unit);
break; break;
case ZFCP_ERP_ACTION_REOPEN_PORT_FORCED: case ZFCP_ERP_ACTION_REOPEN_PORT_FORCED:
......
...@@ -68,7 +68,7 @@ struct zfcp_data zfcp_data = { ...@@ -68,7 +68,7 @@ struct zfcp_data zfcp_data = {
eh_host_reset_handler: zfcp_scsi_eh_host_reset_handler, eh_host_reset_handler: zfcp_scsi_eh_host_reset_handler,
/* FIXME(openfcp): Tune */ /* FIXME(openfcp): Tune */
can_queue: 4096, can_queue: 4096,
this_id: 0, this_id: -1,
/* /*
* FIXME: * FIXME:
* one less? can zfcp_create_sbale cope with it? * one less? can zfcp_create_sbale cope with it?
...@@ -183,7 +183,8 @@ zfcp_scsi_slave_alloc(struct scsi_device *sdp) ...@@ -183,7 +183,8 @@ zfcp_scsi_slave_alloc(struct scsi_device *sdp)
read_lock_irqsave(&zfcp_data.config_lock, flags); read_lock_irqsave(&zfcp_data.config_lock, flags);
unit = zfcp_unit_lookup(adapter, sdp->channel, sdp->id, sdp->lun); unit = zfcp_unit_lookup(adapter, sdp->channel, sdp->id, sdp->lun);
if (unit) { if (unit && atomic_test_mask(ZFCP_STATUS_UNIT_REGISTERED,
&unit->status)) {
sdp->hostdata = unit; sdp->hostdata = unit;
unit->device = sdp; unit->device = sdp;
zfcp_unit_get(unit); zfcp_unit_get(unit);
...@@ -208,6 +209,7 @@ zfcp_scsi_slave_destroy(struct scsi_device *sdpnt) ...@@ -208,6 +209,7 @@ zfcp_scsi_slave_destroy(struct scsi_device *sdpnt)
struct zfcp_unit *unit = (struct zfcp_unit *) sdpnt->hostdata; struct zfcp_unit *unit = (struct zfcp_unit *) sdpnt->hostdata;
if (unit) { if (unit) {
atomic_clear_mask(ZFCP_STATUS_UNIT_REGISTERED, &unit->status);
sdpnt->hostdata = NULL; sdpnt->hostdata = NULL;
unit->device = NULL; unit->device = NULL;
zfcp_unit_put(unit); zfcp_unit_put(unit);
...@@ -291,7 +293,7 @@ zfcp_scsi_command_async(struct zfcp_adapter *adapter, struct zfcp_unit *unit, ...@@ -291,7 +293,7 @@ zfcp_scsi_command_async(struct zfcp_adapter *adapter, struct zfcp_unit *unit,
"on port 0x%016Lx in recovery\n", "on port 0x%016Lx in recovery\n",
zfcp_get_busid_by_unit(unit), zfcp_get_busid_by_unit(unit),
unit->fcp_lun, unit->port->wwpn); unit->fcp_lun, unit->port->wwpn);
retval = SCSI_MLQUEUE_DEVICE_BUSY; zfcp_scsi_command_fail(scpnt, DID_NO_CONNECT);
goto out; goto out;
} }
......
...@@ -8,6 +8,7 @@ menu "PCMCIA SCSI adapter support" ...@@ -8,6 +8,7 @@ menu "PCMCIA SCSI adapter support"
config PCMCIA_AHA152X config PCMCIA_AHA152X
tristate "Adaptec AHA152X PCMCIA support" tristate "Adaptec AHA152X PCMCIA support"
depends on m && !64BIT depends on m && !64BIT
select SCSI_SPI_ATTRS
help help
Say Y here if you intend to attach this type of PCMCIA SCSI host Say Y here if you intend to attach this type of PCMCIA SCSI host
adapter to your computer. adapter to your computer.
......
...@@ -126,6 +126,7 @@ static struct { ...@@ -126,6 +126,7 @@ static struct {
{"ADAPTEC", "Adaptec 5400S", NULL, BLIST_FORCELUN}, {"ADAPTEC", "Adaptec 5400S", NULL, BLIST_FORCELUN},
{"AFT PRO", "-IX CF", "0.0>", BLIST_FORCELUN}, {"AFT PRO", "-IX CF", "0.0>", BLIST_FORCELUN},
{"BELKIN", "USB 2 HS-CF", "1.95", BLIST_FORCELUN | BLIST_INQUIRY_36}, {"BELKIN", "USB 2 HS-CF", "1.95", BLIST_FORCELUN | BLIST_INQUIRY_36},
{"BROWNIE", "1600U3P", NULL, BLIST_NOREPORTLUN},
{"CANON", "IPUBJD", NULL, BLIST_SPARSELUN}, {"CANON", "IPUBJD", NULL, BLIST_SPARSELUN},
{"CBOX3", "USB Storage-SMC", "300A", BLIST_FORCELUN | BLIST_INQUIRY_36}, {"CBOX3", "USB Storage-SMC", "300A", BLIST_FORCELUN | BLIST_INQUIRY_36},
{"CMD", "CRA-7280", NULL, BLIST_SPARSELUN}, /* CMD RAID Controller */ {"CMD", "CRA-7280", NULL, BLIST_SPARSELUN}, /* CMD RAID Controller */
......
...@@ -223,7 +223,7 @@ static void fc_rport_terminate(struct fc_rport *rport); ...@@ -223,7 +223,7 @@ static void fc_rport_terminate(struct fc_rport *rport);
*/ */
#define FC_STARGET_NUM_ATTRS 3 #define FC_STARGET_NUM_ATTRS 3
#define FC_RPORT_NUM_ATTRS 9 #define FC_RPORT_NUM_ATTRS 9
#define FC_HOST_NUM_ATTRS 16 #define FC_HOST_NUM_ATTRS 17
struct fc_internal { struct fc_internal {
struct scsi_transport_template t; struct scsi_transport_template t;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment