Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 27 Jun 2009 13:05:00 +0200
From:      Ivan Voras <ivoras@freebsd.org>
To:        freebsd-current@freebsd.org
Subject:   Re: RFC: ATA to CAM integration patch
Message-ID:  <h24uct$5h9$1@ger.gmane.org>
In-Reply-To: <20090627101151.GA40915@freebsd.org>
References:  <4A4517BE.9040504@FreeBSD.org> <20090627101151.GA40915@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Roman Divacky wrote:
> On Fri, Jun 26, 2009 at 09:47:26PM +0300, Alexander Motin wrote:
>> Hi.
>>
>> I would like to present for testing and feedback present state of my and
>> Scott work on extending CAM subsystem to support ATA in addition to
>> SCSI. At this moment we have:
> 
> this is awesome! do you plan to add support for the TRIM command support?
> what would it take to teach FreeBSD to use the TRIM?

GEOM knows the BIO_DELETE command, which is supposed to do what TRIM 
does but is currently mostly unused. I think tree things need to happen 
to use TRIM effectively:

1) Investigate the conditions of use of TRIM - e.g. must TRIM be applied 
at special alignment on media (i.e. flash block-size?), because 
BIO_DELETE has no alignment requirements.

2) Translate BIO_DELETE into appropriate IO command(s) in the driver(s)

3) Make file systems use BIO_DELETE (or whatever comes from it). AFAIK 
it has been started for UFS, I have no idea about ZFS.

3a) See if existing GEOM classes support BIO_DELETE properly (i.e. 
passthrough to the lower classes)




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?h24uct$5h9$1>