From: Omkhar Arasaratnam <omkhar@rogers.com>
To: trivial@rustcorp.com.au
Cc: gene.heskett@verizon.net, linux-kernel@vger.kernel.org
Subject: [PATCH] drivers/scsi/advansys.c check_region() fix
Date: Tue, 30 Dec 2003 08:44:33 -0500 [thread overview]
Message-ID: <20031230134433.GA22187@omkhar.ibm.com> (raw)
Another trivial check_region() fix verified by Gene
--- linux-clean/drivers/scsi/advansys.c.org 2003-12-29 19:35:26.000000000 -0500
+++ linux-clean/drivers/scsi/advansys.c 2003-12-30 01:37:01.000000000 -0500
@@ -4619,7 +4619,7 @@
ASC_DBG1(1,
"advansys_detect: probing I/O port 0x%x...\n",
iop);
- if (check_region(iop, ASC_IOADR_GAP) != 0) {
+ if (!request_region(iop, ASC_IOADR_GAP, "advansys")) {
printk(
"AdvanSys SCSI: specified I/O Port 0x%X is busy\n", iop);
/* Don't try this I/O port twice. */
@@ -4630,6 +4630,7 @@
"AdvanSys SCSI: specified I/O Port 0x%X has no adapter\n", iop);
/* Don't try this I/O port twice. */
asc_ioport[ioport] = 0;
+ release_region(iop, ASC_IOADR_GAP);
goto ioport_try_again;
} else {
/*
@@ -4647,6 +4648,7 @@
* 'ioport' past this board.
*/
ioport++;
+ release_region(iop, ASC_IOADR_GAP);
goto ioport_try_again;
}
}
@@ -10003,10 +10005,11 @@
}
for (; i < ASC_IOADR_TABLE_MAX_IX; i++) {
iop_base = _asc_def_iop_base[i];
- if (check_region(iop_base, ASC_IOADR_GAP) != 0) {
+ if (!request_region(iop_base, ASC_IOADR_GAP, "advansys")) {
ASC_DBG1(1,
- "AscSearchIOPortAddr11: check_region() failed I/O port 0x%x\n",
+ "AscSearchIOPortAddr11: request_region() failed I/O port 0x%x\n",
iop_base);
+ release_region(iop_base, ASC_IOADR_GAP);
continue;
}
ASC_DBG1(1, "AscSearchIOPortAddr11: probing I/O port 0x%x\n", iop_base);
O
next reply other threads:[~2003-12-30 13:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-12-30 13:44 Omkhar Arasaratnam [this message]
2004-01-07 23:26 ` Rusty Russell
2004-01-08 4:09 ` Gene Heskett
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=20031230134433.GA22187@omkhar.ibm.com \
--to=omkhar@rogers.com \
--cc=gene.heskett@verizon.net \
--cc=linux-kernel@vger.kernel.org \
--cc=trivial@rustcorp.com.au \
/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
Powered by JetHome