Some makefs(8) improvements

moxalt moxalt at riseup.net
Mon Oct 12 15:25:53 UTC 2015


On Sun, 11 Oct 2015 20:21:30 -0700, Adrian Chadd <adrian.chadd at gmail.com> wrote:

> Hi!
> 
> It looks fine to me as a stopgap measure. Sean, please do commit it
> when you have some spare time. :)
> 
> Thanks!
> 
> 
> -a
> 
> 
> On 11 October 2015 at 12:52, Eugene Grosbein <egrosbein at rdtc.ru> wrote:
> > Hi!
> >
> > While building my own FreeBSD/mips image for device having 8MB flash inly,
> > I've faced two problems with makefs(8) utility.
> >
> > First, there is a bug in makefs: it fails to initialise fs_providersize
> > in a superblock while making UFS file system. This leads to other problems
> > with geom_label. The (trivial) patch is attached to the PR I just submited:
> > https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=203704
> >
> > Then, makefs is not quite compatible with mkulzma/geom_uncompress feature:
> > geom_uncompress kernel module reports GEOM provider size rounded up to
> > its compression block size. Generally, this changes original media size
> > and now it fails to match the size of embedded UFS that  again
> > leads to problems with geom_label kernel module. This module does not like
> > the mismatch and skips the file system while tasting the GEOM and looking
> > for UFS label.
> >
> > I've added new option "-r" to makefs to round up generated image to
> > specified block size, f.e.:
> >
> > makefs -t ffs -r 65536 -o bsize=4096,fsize=512,label=flash
> > optimization=space fs.img fs
> >
> > geom_uncompress does not change GEOM media size for images rounded that way
> > and geom_label accepts such GEOMs just fine.
> >
> > The patch is attached to another PR I just submited:
> > https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=203707

Top-posting. No.


More information about the freebsd-mips mailing list