2. Is there a way of passing these parameters through from U-Boot? (I think the answer here is no)
Apologies for reviving a very old thread, but I thought this might be useful for future reference.
One can tell the kernel which options to use when mounting the root filesystem through the kernel command line, using the
rootflags parameter. Something like the following should do the trick:
rootflags=usrquota,grpquota
I do wonder whether it would be necessary to force these specific flags in the early read-only kernel mount, though. The filesystem will still be remounted read-write by the boot scripts, and those will usually honor
fstab (as long as the "new" options can be set on a re-mount, which usrquota and grpquota can). The rootfs
/etc/fstab entry on my DreamPlug for example (running Debian 6.0), currently looks like this:
# override rootfs's mount options (reduce writes to disk)
rootfs / rootfs rw,noatime,commit=300,barrier=0 0 0
And indeed I have the following after boot (without changing anything in the kernel command line through u-boot):
# dmesg | grep re-mounted
EXT4-fs (sda2): re-mounted. Opts: commit=300,barrier=0
# grep root /proc/mounts
rootfs / rootfs rw 0 0
/dev/root / ext4 rw,noatime,commit=300,barrier=0,data=ordered 0 0
Incidentally, another parameter which may be of use is
rootfstype, for when one wants to explicitly state the root filesystem type. I have a box whose rootfs is an ext3, but I want to take advantage of ext4's backwards-compatible features (such as delayed allocation and multiblock allocation). The relevant portion of the kernel command-line on that system is as follows:
root=/dev/sda2 rootfstype=ext4