lkml.org 
[lkml]   [2000]   [Aug]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
SubjectPatch: Make af_packet use {Set,Clear}PageReserved
Date
Linus,

I'm not sure why net/packet/af_packet.c doesn't use these macros that are
defined in pagemap.h. Here is a patch to convert it.

diff -urN linux-orig/net/packet/af_packet.c linux/net/packet/af_packet.c
--- linux-orig/net/packet/af_packet.c Sat Aug 26 19:56:54 2000
+++ linux/net/packet/af_packet.c Sat Aug 26 19:48:38 2000
@@ -1585,7 +1585,7 @@

pend = virt_to_page(pg_vec[i] + (PAGE_SIZE << order) - 1);
for (page = virt_to_page(pg_vec[i]); page <= pend; page++)
- clear_bit(PG_reserved, &page->flags);
+ ClearPageReserved(page);
free_pages(pg_vec[i], order);
}
}
@@ -1640,7 +1640,7 @@

pend = virt_to_page(pg_vec[i] + (PAGE_SIZE << order) - 1);
for (page = virt_to_page(pg_vec[i]); page <= pend; page++)
- set_bit(PG_reserved, &page->flags);
+ SetPageReserved(page);
}
/* Page vector is allocated */

_____
|_____| ------------------------------------------------- ---+---+-
| | Russell King rmk@arm.linux.org.uk --- ---
| | | | http://www.arm.linux.org.uk/personal/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.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 12:38    [W:0.022 / U:3.832 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site