From f4330002d11f032559954cbff68a5cad95b6d27f Mon Sep 17 00:00:00 2001 From: Alexey Dobriyan Date: Wed, 6 Dec 2006 20:36:20 -0800 Subject: [PATCH] paride: rename pi_register() and pi_unregister() We're about to change the semantics of pi_register()'s return value, so rename it to something else first, so that any unconverted code reliaby breaks. Signed-off-by: Alexey Dobriyan Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/block/paride/on20.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/block/paride/on20.c') diff --git a/drivers/block/paride/on20.c b/drivers/block/paride/on20.c index 9f8e0109680..cc7e9f591dd 100644 --- a/drivers/block/paride/on20.c +++ b/drivers/block/paride/on20.c @@ -140,12 +140,12 @@ static struct pi_protocol on20 = { static int __init on20_init(void) { - return pi_register(&on20)-1; + return paride_register(&on20)-1; } static void __exit on20_exit(void) { - pi_unregister(&on20); + paride_unregister(&on20); } MODULE_LICENSE("GPL"); -- cgit v1.2.3 From b4178ab58aa81f4ed3c75c48940682fe3b45d880 Mon Sep 17 00:00:00 2001 From: Alexey Dobriyan Date: Wed, 6 Dec 2006 20:36:21 -0800 Subject: [PATCH] paride_register(): shuffle return values paride_register() returns 1 on success, 0 on failure and module init code looks like static int __init foo_init(void) { return paride_register(&foo) - 1; } which is not what one get used to. Converted to usual 0/-E convention. In case of kbic driver, unwind registration. It was just return (paride_register(&k951)||paride_register(&k971))-1; Signed-off-by: Alexey Dobriyan Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/block/paride/on20.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/block/paride/on20.c') diff --git a/drivers/block/paride/on20.c b/drivers/block/paride/on20.c index cc7e9f591dd..0173697a1a4 100644 --- a/drivers/block/paride/on20.c +++ b/drivers/block/paride/on20.c @@ -140,7 +140,7 @@ static struct pi_protocol on20 = { static int __init on20_init(void) { - return paride_register(&on20)-1; + return paride_register(&on20); } static void __exit on20_exit(void) -- cgit v1.2.3