From: Oliver Neukum <oliver@neukum.org>
To: James Bottomley <James.Bottomley@SteelEye.com>
Cc: linux-scsi@vger.kernel.org
Subject: [PATCH]fix irq handling for DC395
Date: Fri, 16 May 2003 18:56:22 +0200 [thread overview]
Message-ID: <200305161856.22151.oliver@neukum.org> (raw)
Hi,
this fix makes sure that all test in irq handling in that
driver are for NULL thus fixing an oops.
Regards
Oliver
You can import this changeset into BK by piping this whole message to:
'| bk receive [path to repository]' or apply the patch as usual.
===================================================================
ChangeSet@1.1094, 2003-05-14 08:45:30+02:00, oliver@oenone.homelinux.org
- fix IRQ problem
dc395x.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff -Nru a/drivers/scsi/dc395x.c b/drivers/scsi/dc395x.c
--- a/drivers/scsi/dc395x.c Wed May 14 10:40:10 2003
+++ b/drivers/scsi/dc395x.c Wed May 14 10:40:10 2003
@@ -5364,7 +5364,7 @@
eeprom = &dc395x_trm_eepromBuf[index];
pTempACB = DC395x_pACB_start;
if (pTempACB != NULL) {
- for (; (pTempACB != (struct AdapterCtlBlk *) -1);) {
+ while (pTempACB) {
if (pTempACB->IRQLevel == irq) {
used_irq = 1;
break;
@@ -5842,11 +5842,11 @@
if (!DC395x_pACB_start) {
DC395x_pACB_start = pACB;
DC395x_pACB_current = pACB;
- pACB->pNextACB = (struct AdapterCtlBlk *) -1;
+ pACB->pNextACB = NULL;
} else {
DC395x_pACB_current->pNextACB = pACB;
DC395x_pACB_current = pACB;
- pACB->pNextACB = (struct AdapterCtlBlk *) -1;
+ pACB->pNextACB = NULL;
}
/*DC395x_ACB_UNLOCK(pACB,acb_flags); */
return host;
@@ -6077,13 +6077,13 @@
pACB = DC395x_pACB_start;
- while (pACB != (struct AdapterCtlBlk *) -1) {
+ while (pACB) {
shpnt = pACB->pScsiHost;
if (shpnt->host_no == hostno)
break;
pACB = pACB->pNextACB;
}
- if (pACB == (struct AdapterCtlBlk *) -1)
+ if (!pACB)
return -ESRCH;
if (!shpnt)
@@ -6306,7 +6306,7 @@
*/
int irq_count;
for (irq_count = 0, pACB = DC395x_pACB_start;
- pACB != (struct AdapterCtlBlk *) -1;
+ pACB;
pACB = pACB->pNextACB) {
if (pACB->IRQLevel == host->irq)
++irq_count;
===================================================================
This BitKeeper patch contains the following changesets:
1.1094
## Wrapped with gzip_uu ##
begin 664 bkpatch3163
M'XL(`.H`PCX``[U4VVK;0!!]UG[%E+RD!$NSVHLNP<&YE#;4I*X;?X`LCV,E
MNAA)=ARJC^]*=FT*P;2A[4HPPYS#W/:P)S"IJ`RM(DW65+(3^%14=6CEM'I:
M978>961BXZ(P,6=19.1LB<Y]250YLU@$BAG&**KC!1B@"BUNBWVD?EE2:(T_
M?)P,+\>,]?MPO8CR!_I&-?3[K"[*=93.JD%4+](BM^LRRJN,ZLB.BZS94QL7
MT36?XIY`I1NN47I-S&><1Y+3#%WI:WG(UC9Z+)=)P@5JXZE&R8"[[`:XS3&0
M@,)!Y7#C^*%4H<`S=$-$V(X]*"@O<K+;`FF2KS9V43[`&8<>LBOXN]-<LQAZ
M,$\V<#O^"LNRF*:4L<^@%'<]-CHLDO7^\#"&$;*+8S,UL[+%*J>*JV1[S1L[
MWNY.NMKEW$.OD;[P@F9.@<!HS@,NIY+\Z5OS*BY12X&\42A%T*GE57JKG'_4
M.WNDQ^F@C-:4VTEJ5S512B_47>"QUELQ<2UDHR6JH).3^%5+(D3^.UK2T-/_
M3TO=HK]`KWSN?J.-T>L[?X/(;I30'G!VN[.6];Q(4H+3Y3UER\OKJ_?PW9!\
MJ3K2UEJ6U4*]B^4=;6KC01_N)L/A><<,=LS@.%.CCRUS9_=U?]8T<;W#6VLE
J<SA]UZ$&$]A5V5G+@O:TX/GAH8L7%#]5JZP_G_NHA2O8#ZX.86!(!0``
`
end
reply other threads:[~2003-05-16 16:43 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200305161856.22151.oliver@neukum.org \
--to=oliver@neukum.org \
--cc=James.Bottomley@SteelEye.com \
--cc=linux-scsi@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox