lkml.org 
[lkml]   [2000]   [Nov]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Date
SubjectPatch(?): linux-2.4.0-test11-pre5 ISAPNP_DEVICE simplification

I think the definition of ISAPNP_DEVICE in
linux-2.4.0-test11-pre5/include/linux/isapnp.h is unnecessarily complex.
Here is a proposed patch.

Adam J. Richter __ ______________ 4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com \ / San Jose, California 95129-1034
+1 408 261-6630 | g g d r a s i l United States of America
fax +1 408 261-6631 "Free Software For The Rest Of Us."


--- linux/include/linux/isapnp.h.orig Thu Nov 16 02:20:14 2000
+++ linux/include/linux/isapnp.h Thu Nov 16 02:20:33 2000
@@ -42,10 +42,8 @@
#define ISAPNP_VENDOR(a,b,c) (((((a)-'A'+1)&0x3f)<<2)|\
((((b)-'A'+1)&0x18)>>3)|((((b)-'A'+1)&7)<<13)|\
((((c)-'A'+1)&0x1f)<<8))
-#define ISAPNP_DEVICE(x) ((((x)&0xf000)>>8)|\
- (((x)&0x0f00)>>8)|\
- (((x)&0x00f0)<<8)|\
- (((x)&0x000f)<<8))
+#define ISAPNP_DEVICE(x) ((((x)&0xff00)>>8)|\
+ (((x)&0x00ff)<<8))
#define ISAPNP_FUNCTION(x) ISAPNP_DEVICE(x)

/*
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 12:45    [W:0.019 / U:11.624 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site