lkml.org 
[lkml]   [2001]   [Feb]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[patchlet] cramfs incompatible with initrd..
(If the initrd is other than PAGE_CACHE_SIZE blocksize)

Hi,

I found that merely having cramfs configured into the kernel
precludes mounting a ramdisk root after cramfs_read_super() has
been called. The problem is that cramfs changes the blocksize
of the ramdisk to PAGE_CACHE_SIZE after we've loaded the initrd
at 1k blocksize.

The patchlet below effectively works around the problem. Question
being does it do it in an acceptable manner? Can refusing to change
blocksize of a device with a registered hard blocksize cause problems
elsewhere?

-Mike

--- linux-2.4.1.ac12/fs/buffer.c.org Wed Feb 14 14:01:54 2001
+++ linux-2.4.1.ac12/fs/buffer.c Wed Feb 14 14:19:13 2001
@@ -686,7 +686,7 @@
int i, nlist, slept;
struct buffer_head * bh, * bh_next;

- if (!blksize_size[MAJOR(dev)])
+ if (!blksize_size[MAJOR(dev)] || get_hardblocksize(dev))
return;

/* Size must be a power of two, and between 512 and PAGE_SIZE */
-
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:14    [W:0.018 / U:3.876 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site