Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 31 May 2014 10:31:53 -0700
From:      Adrian Chadd <adrian@freebsd.org>
To:        Warner Losh <imp@bsdimp.com>
Cc:        "freebsd-arm@freebsd.org" <freebsd-arm@freebsd.org>, Bernd Walter <ticso@cicely7.cicely.de>, ticso@cicely.de, Ian Lepore <ian@freebsd.org>
Subject:   Re: TRIM on SD cards
Message-ID:  <CAJ-Vmom=r9FA_HWLTjgThSZPncGw3dkCknNGCEpd=F39AJN8ww@mail.gmail.com>
In-Reply-To: <05005B04-1BDA-4242-946B-28D0DA069A42@bsdimp.com>
References:  <20140531004306.GI26883@cicely7.cicely.de> <1401505209.20883.34.camel@revolution.hippie.lan> <20140531102305.GK26883@cicely7.cicely.de> <05005B04-1BDA-4242-946B-28D0DA069A42@bsdimp.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 31 May 2014 09:45, Warner Losh <imp@bsdimp.com> wrote:

> One of the things that I did for images years ago was compressed tar file=
s. There was so much variation between CF makers and at the time CF geometr=
y was important to the BIOS, so we made our images as tar balls. We then ha=
d a makefile target that would create a partition on the card that was actu=
ally there, put boot blocks on it then extract the tarball=E2=80=A6  I neve=
r have liked DD for creating images, even when LBAs ruled the day because y=
ou=E2=80=99d always have to grow/shrink the FS afterwards. The only advanta=
ge it had was it was easy=E2=80=A6 Perhaps it is time to go back to that mo=
del? The alternative that wouldn=E2=80=99t suck too bad would be to create =
variable sized images based on how much data was actually present and ensur=
e there are no holes (or minimal holes) in the filesystem.
>
> Hmmm, if we know WHAT filesystem we=E2=80=99re dealing with, then we coul=
d perhaps enhance fsck and/or growfs to BIO_DELETE all the blocks that it k=
nows are free, which would be a useful, data-driven approach that could ens=
ure we start out with a nicely trimmed FS. Given the vagaries of the differ=
ent kinds of TRIMs and the various translation layers we have, that might b=
e the most robust.

Having makefs spit this out would be rather useful.


-a



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJ-Vmom=r9FA_HWLTjgThSZPncGw3dkCknNGCEpd=F39AJN8ww>