Yeah.... the AMD64 patch is a bit lame. You really
need to at least return a value from that function. What value are you hoping the thing returns most of the time? Why not just return a constant?
Here's the text of the patch so others can see what I'm talking about:
Code: Select all
diff -Nuar linux-2.6.13.2-nitro1/include/linux/dyn_pageflags.h linux-2.6.13.2-nitro1-modded/include/linux/dyn_pageflags.h
--- linux-2.6.13.2-nitro1/include/linux/dyn_pageflags.h 2005-09-23 05:01:37.000000000 +1000
+++ linux-2.6.13.2-nitro1-modded/include/linux/dyn_pageflags.h 2005-09-23 04:39:20.000000000 +1000
@@ -31,12 +31,14 @@
static inline int __get_next_bit_on(dyn_pageflags_t bitmap, int counter)
{
- do {
- counter++;
- } while((counter < max_mapnr) &&
- (!test_bit(PAGEBIT(pfn_to_page(counter)),
- PAGE_UL_PTR(bitmap, pfn_to_page(counter)))));
- return counter;
+// FIXME: Fix this dirty hack for AMD64.
+//
+// do {
+// counter++;
+// } while((counter < max_mapnr) &&
+// (!test_bit(PAGEBIT(pfn_to_page(counter)),
+// PAGE_UL_PTR(bitmap, pfn_to_page(counter)))));
+// return counter;
}
/* With the above macros defined, you can do...
Alright, look, I'm just going to add the following line after the commented out return:
This is the absolute *smallest* value that the original function would've been able to return. I don't want to compile my kernel w/ a function returning undefined values, and neither should anyone else here.
Not that I am ungrateful for the patch or a solution to problem. Not in the slightest. Just trying to make improvements.