Merge git://bedivere.hansenpartnership.com/git/scsi-rc-fixes-2.6

* git://bedivere.hansenpartnership.com/git/scsi-rc-fixes-2.6:
[SCSI] libsas: fix panic when single phy is disabled on a wide port
[SCSI] qla2xxx: Fix crash in qla2x00_abort_all_cmds() on unload

+11 -8
+6 -4
drivers/scsi/libsas/sas_expander.c
··· 1769 1769 sas_disable_routing(parent, phy->attached_sas_addr); 1770 1770 } 1771 1771 memset(phy->attached_sas_addr, 0, SAS_ADDR_SIZE); 1772 - sas_port_delete_phy(phy->port, phy->phy); 1773 - if (phy->port->num_phys == 0) 1774 - sas_port_delete(phy->port); 1775 - phy->port = NULL; 1772 + if (phy->port) { 1773 + sas_port_delete_phy(phy->port, phy->phy); 1774 + if (phy->port->num_phys == 0) 1775 + sas_port_delete(phy->port); 1776 + phy->port = NULL; 1777 + } 1776 1778 } 1777 1779 1778 1780 static int sas_discover_bfs_by_root_level(struct domain_device *root,
+5 -4
drivers/scsi/qla2xxx/qla_os.c
··· 1328 1328 qla2x00_sp_compl(ha, sp); 1329 1329 } else { 1330 1330 ctx = sp->ctx; 1331 - if (ctx->type == SRB_LOGIN_CMD || 1332 - ctx->type == SRB_LOGOUT_CMD) { 1333 - ctx->u.iocb_cmd->free(sp); 1334 - } else { 1331 + if (ctx->type == SRB_ELS_CMD_RPT || 1332 + ctx->type == SRB_ELS_CMD_HST || 1333 + ctx->type == SRB_CT_CMD) { 1335 1334 struct fc_bsg_job *bsg_job = 1336 1335 ctx->u.bsg_job; 1337 1336 if (bsg_job->request->msgcode ··· 1342 1343 kfree(sp->ctx); 1343 1344 mempool_free(sp, 1344 1345 ha->srb_mempool); 1346 + } else { 1347 + ctx->u.iocb_cmd->free(sp); 1345 1348 } 1346 1349 } 1347 1350 }