lkml.org 
[lkml]   [1999]   [Dec]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
SubjectPatch: kernel/resource.c: select format string inteligently
Date
Hi Linus & world,

The following patch allows inteligent selection of the "short" form of
the format string in causes where there are only 64K ports, and the
"long" form elsewhere.

Any comments?

diff -urN linux-orig/kernel/resource.c linux/kernel/resource.c
--- linux-orig/kernel/resource.c Tue Dec 7 19:56:16 1999
+++ linux/kernel/resource.c Tue Dec 7 20:11:56 1999
@@ -55,7 +55,7 @@
int retval;

fmt = " %08lx-%08lx : %s\n";
- if (root == &ioport_resource)
+ if (root->end < 0x10000)
fmt = " %04lx-%04lx : %s\n";
read_lock(&resource_lock);
retval = do_resource_list(root->child, fmt, 8, buf, buf + size) - buf;

_____
|_____| ------------------------------------------------- ---+---+-
| | Russell King rmk@arm.linux.org.uk --- ---
| | | | http://www.arm.linux.org.uk/~rmk/aboutme.html / / |
| +-+-+ --- -+-
/ | THE developer of ARM Linux |+| /|\
/ | | | --- |
+-+-+ ------------------------------------------------- /\\\ |
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:55    [W:0.026 / U:0.356 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site