frightening things to be found in the source (patch for 2.0.x)???

Gordon Oliver (gordo@lazos.cl)
Fri, 4 Apr 1997 17:41:36 -0400 (CST)


I found the following little ditty in the source... I'm not at all
sure that filemap.c shouldn't do something else (clear_bit(PG_dirty)
or some such....)

Someone more knowledgable may be able to comment... It seems
frightening that there is a member of an important kernel structure
that is used exactly twice, and is zeroed both times...
-gordo

--- include/linux/mm.h.dist Wed Jan 8 01:55:28 1997
+++ include/linux/mm.h.new Fri Apr 4 17:28:30 1997
@@ -118,7 +118,7 @@
*/
typedef struct page {
atomic_t count;
- unsigned dirty:16,
+ unsigned FIXME_not_a_bit_dirty:16, /* not used */
age:8;
unsigned flags; /* atomic flags, some possibly updated asynchronously */
struct wait_queue *wait;

--- mm/filemap.c.orig Fri Apr 4 17:18:27 1997
+++ mm/filemap.c Fri Apr 4 17:29:09 1997
@@ -73,7 +73,6 @@
inode->i_nrpages--;
if ((*p = page->next) != NULL)
(*p)->prev = page->prev;
- page->dirty = 0;
page->next = NULL;
page->prev = NULL;
remove_page_from_hash_queue(page);
@@ -106,7 +105,6 @@
inode->i_nrpages--;
if ((*p = page->next) != NULL)
(*p)->prev = page->prev;
- page->dirty = 0;
page->next = NULL;
page->prev = NULL;
remove_page_from_hash_queue(page);