From: Borislav Petkov <bbpetkov@yahoo.de>
To: akpm@osdl.org
Cc: linux-kernel@vger.kernel.org, R.E.Wolff@BitWizard.nl
Subject: [PATCH] remove check_region in drivers-char-specialix.c
Date: Wed, 28 Sep 2005 10:37:37 +0200 [thread overview]
Message-ID: <20050928083737.GA29498@gollum.tnic> (raw)
Hi Andrew,
This is also a pretty simple case. We remove the wrapper and make
sx__request_io_range return struct resource *. We check its value accordingly
in the probing routine. It compiles cleanly here.
Signed-off-by: Borislav Petkov <petkov@uni-muenster.de>
--- 2.6.14-rc2/drivers/char/specialix.c.orig 2005-09-28 10:02:31.000000000 +0200
+++ 2.6.14-rc2/drivers/char/specialix.c 2005-09-28 10:30:24.000000000 +0200
@@ -338,15 +338,9 @@ static inline void sx_wait_CCR_off(struc
* specialix IO8+ IO range functions.
*/
-static inline int sx_check_io_range(struct specialix_board * bp)
+static inline struct resource * sx_request_io_range(struct specialix_board * bp)
{
- return check_region (bp->base, SX_IO_SPACE);
-}
-
-
-static inline void sx_request_io_range(struct specialix_board * bp)
-{
- request_region(bp->base,
+ return request_region(bp->base,
bp->flags&SX_BOARD_IS_PCI?SX_PCI_IO_SPACE:SX_IO_SPACE,
"specialix IO8+" );
}
@@ -495,7 +489,7 @@ static int sx_probe(struct specialix_boa
func_enter();
- if (sx_check_io_range(bp)) {
+ if (!sx_request_io_range(bp)) {
func_exit();
return 1;
}
@@ -583,7 +577,6 @@ static int sx_probe(struct specialix_boa
return -EIO;
}
- sx_request_io_range(bp);
bp->flags |= SX_BOARD_PRESENT;
/* Chip revcode pkgtype
___________________________________________________________
Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de
next reply other threads:[~2005-09-28 8:37 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-09-28 8:37 Borislav Petkov [this message]
2005-09-28 17:52 ` Al Viro
2005-09-28 22:28 ` Borislav Petkov
2005-09-29 1:10 ` Al Viro
2005-09-29 1:41 ` Andrew Morton
2005-09-29 2:05 ` Al Viro
2005-09-29 6:43 ` Rogier Wolff
2005-09-29 7:38 ` Christoph Hellwig
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=20050928083737.GA29498@gollum.tnic \
--to=bbpetkov@yahoo.de \
--cc=R.E.Wolff@BitWizard.nl \
--cc=akpm@osdl.org \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®