On Tuesday 04 March 2008, Colin Watson wrote: > On Tue, Jan 15, 2008 at 05:58:37AM +0100, Frans Pop wrote: > > I can easily reproduce this from a debug shell: > > # mount /dev/hda1 /mnt/ -t ext3 -o relatime > > mount: Mounting /dev/hda1 on /mnt/ failed: Invalid argument > > # dmesg > > EXT3-fs: Unrecognized mount option "relatime" or missing value > > The attached patch adds support for the relatime and norelatime mount > options, fixing this bug. (util-linux has similar code already.) Please > apply.
Attached is an updated patch that makes relatime work with busybox 1.9.1. There is one thing I'm wondering at. @@ -33,6 +33,9 @@ #ifndef MS_SILENT #define MS_SILENT (1 << 15) #endif +#ifndef MS_RELATIME +#define MS_RELATIME 2097152 +#endif I used 2097152 because that is the value Colin had. However, MS_SILENT is defined as a single bit (2^15), but MS_RELATIME is two bits: 2^21 + 2^1. Is that correct? If it is, what would be the correct notation to make it consistent with the notation for MS_SILENT? Cheers, FJP
diff -ru tmp/busybox/util-linux/mount.c busybox-1.9.1/util-linux/mount.c --- tmp/busybox/util-linux/mount.c 2008-02-12 17:03:13.000000000 +0100 +++ busybox-1.9.1/util-linux/mount.c 2008-03-11 13:41:45.000000000 +0100 @@ -33,6 +33,9 @@ #ifndef MS_SILENT #define MS_SILENT (1 << 15) #endif +#ifndef MS_RELATIME +#define MS_RELATIME 2097152 +#endif #if defined(__dietlibc__) /* 16.12.2006, Sampo Kellomaki ([EMAIL PROTECTED]) @@ -97,6 +100,8 @@ /* "noatime" */ MS_NOATIME, /* "diratime" */ ~MS_NODIRATIME, /* "nodiratime" */ MS_NODIRATIME, + /* "relatime" */ MS_RELATIME, + /* "norelatime" */ ~MS_RELATIME, /* "loud" */ ~MS_SILENT, // action flags @@ -145,6 +150,8 @@ "noatime" "\0" "diratime" "\0" "nodiratime" "\0" + "relatime" "\0" + "norelatime" "\0" "loud" "\0" // action flags
signature.asc
Description: This is a digitally signed message part.