]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blame - src/patches/suse-2.6.27.25/patches.drivers/lpfc-8.2.8.9-update
Reenabled linux-xen and xen-image build
[people/pmueller/ipfire-2.x.git] / src / patches / suse-2.6.27.25 / patches.drivers / lpfc-8.2.8.9-update
CommitLineData
00e5a55c
BS
1Subject: Update Emulex lpfc driver to 8.2.8.9
2From: Jamie Wellnitz <jamie.wellnitz@emulex.com>
3Date: Wed Dec 3 09:06:44 2008 +0100:
4References: bnc#420767
5
6Changes from 8.2.8.7 to 8.2.8.9:
7
8* Changed version number to 8.2.8.9
9* Remove unused defines from lpfc_auth_access.h
10* Fix firmware dump on CNAs (CR 86157)
11* Changed version number to 8.2.8.8
12* Fixed wrong number of bytes copied reported to applications (CR 85743)
13* Fixed potential spin_lock problem when HBA is in MSI-X mode
14
15Signed-off-by: Jamie Wellnitz <jamie.wellnitz@emulex.com>
16Signed-off-by: Hannes Reinecke <hare@suse.de>
17
18diff --git a/drivers/scsi/lpfc/lpfc_auth_access.h b/drivers/scsi/lpfc/lpfc_auth_access.h
19index be7525f..0aadcd3 100644
20--- a/drivers/scsi/lpfc/lpfc_auth_access.h
21+++ b/drivers/scsi/lpfc/lpfc_auth_access.h
22@@ -1,7 +1,7 @@
23 /*******************************************************************
24 * This file is part of the Emulex Linux Device Driver for *
25 * Fibre Channel Host Bus Adapters. *
26- * Copyright (C) 2006-2007 Emulex. All rights reserved. *
27+ * Copyright (C) 2006-2008 Emulex. All rights reserved. *
28 * EMULEX and SLI are trademarks of Emulex. *
29 * www.emulex.com *
30 * *
31@@ -18,26 +18,6 @@
32 * included with this package. *
33 *******************************************************************/
34
35-#define to_fc_internal(tmpl) container_of(tmpl, struct fc_internal, t)
36-
37-/* scsi_nl_hdr->version value */
38-#define SCSI_NL_VERSION 1
39-
40-/* scsi_nl_hdr->magic value */
41-#define SCSI_NL_MAGIC 0xA1B2
42-
43-/* scsi_nl_hdr->transport value */
44-#define SCSI_NL_TRANSPORT 0
45-#define SCSI_NL_TRANSPORT_FC 1
46-#define SCSI_NL_MAX_TRANSPORTS 2
47-
48-#define FC_NL_GROUP_CNT 0
49-
50- /* Note: when specifying vendor_id to fc_host_post_vendor_event()
51- * be sure to read the Vendor Type and ID formatting requirements
52- * specified in scsi_netlink.h
53- */
54-
55 #define FC_SC_REQ_TIMEOUT (60*HZ)
56
57 enum fc_sc_service_state {
58diff --git a/drivers/scsi/lpfc/lpfc_mbox.c b/drivers/scsi/lpfc/lpfc_mbox.c
59index 84619ed..b5c7876 100644
60--- a/drivers/scsi/lpfc/lpfc_mbox.c
61+++ b/drivers/scsi/lpfc/lpfc_mbox.c
62@@ -1349,10 +1349,12 @@ lpfc_mbox_get(struct lpfc_hba * phba)
63 void
64 lpfc_mbox_cmpl_put(struct lpfc_hba * phba, LPFC_MBOXQ_t * mbq)
65 {
66+ unsigned long iflag;
67+
68 /* This function expects to be called from interrupt context */
69- spin_lock(&phba->hbalock);
70+ spin_lock_irqsave(&phba->hbalock, iflag);
71 list_add_tail(&mbq->list, &phba->sli.mboxq_cmpl);
72- spin_unlock(&phba->hbalock);
73+ spin_unlock_irqrestore(&phba->hbalock, iflag);
74 return;
75 }
76
77diff --git a/drivers/scsi/lpfc/lpfc_menlo.c b/drivers/scsi/lpfc/lpfc_menlo.c
78index 4f3b332..12fd7fe 100644
79--- a/drivers/scsi/lpfc/lpfc_menlo.c
80+++ b/drivers/scsi/lpfc/lpfc_menlo.c
81@@ -1064,13 +1064,22 @@ lpfc_menlo_read(struct lpfc_hba *phba, char *buf, loff_t off, size_t count,
82 }
83 genreq->offset += count;
84
85-
86- if (genreq->offset >= sysfs_menlo->cmdhdr.rspsize) {
87+ if (genreq->offset >= (genreq->rspiocbq->iocb.un.ulpWord[0] &
88+ 0x00ffffff)) {
89 lpfc_printf_log(phba, KERN_INFO, LOG_LIBDFC,
90- "1222 menlo_read: done off %d rc=%d"
91- " cnt %d rsp_code %x\n",
92- (int)off, rc, (int)count,*((uint32_t *)buf));
93- rc = count;
94+ "1222 menlo_read: done off %d genoff:%d rspsz:%d "
95+ "rc=%d cnt %d rsp_code %x Word0:%x\n",
96+ (int)off, (int)genreq->offset,
97+ sysfs_menlo->cmdhdr.rspsize, rc, (int)count,
98+ *((uint32_t *)buf),
99+ genreq->rspiocbq->iocb.un.ulpWord[0]);
100+
101+ if ((genreq->rspiocbq->iocb.un.ulpWord[0] & 0x00ffffff)
102+ < sysfs_menlo->cmdhdr.rspsize)
103+ rc = (genreq->rspiocbq->iocb.un.ulpWord[0] & 0x00ffffff)
104+ + count - genreq->offset;
105+ else
106+ rc = count;
107 goto lpfc_menlo_read_err_exit;
108 }
109
110diff --git a/drivers/scsi/lpfc/lpfc_version.h b/drivers/scsi/lpfc/lpfc_version.h
111index 16626a5..26f6760 100644
112--- a/drivers/scsi/lpfc/lpfc_version.h
113+++ b/drivers/scsi/lpfc/lpfc_version.h
114@@ -18,7 +18,7 @@
115 * included with this package. *
116 *******************************************************************/
117
118-#define LPFC_DRIVER_VERSION "8.2.8.7"
119+#define LPFC_DRIVER_VERSION "8.2.8.9"
120
121 #define LPFC_DRIVER_NAME "lpfc"
122 #define LPFC_SP_DRIVER_HANDLER_NAME "lpfc:sp"