lkml.org 
[lkml]   [2002]   [Sep]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectReiserFS buglet

First:

In linux-2.4.19, I found the following:

fs/reiserfs/super.c:707

s->s_blocksize = sb_blocksize(rs);
s->s_blocksize_bits = 0;
while ((1 << s->s_blocksize_bits) != s->s_blocksize)
s->s_blocksize_bits ++;


What happens if there's a bit-flip on the disk so that s->s_blocksize is
not a power of two ?

I would suggest replacing the '!=' with a '<' in the while loop and
adding a sanity check afterwards.

After all, a single bit-flip in the root fs superblock would cause the
system to hang silently (but spinning really fast!) at boot.


Second:

As I see it, the ReiserFS journal has the same problems as jbd wrt. to
atomicity of write operations of indexes. Please see my recent mail
about the jbd problems.


--
................................................................
: jakob@unthought.net : And I see the elder races, :
:.........................: putrid forms of man :
: Jakob Østergaard : See him rise and claim the earth, :
: OZ9ABN : his downfall is at hand. :
:.........................:............{Konkhra}...............:
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

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