All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Lord <kernel@teksavvy.com>
To: Greg Freemyer <greg.freemyer@gmail.com>
Cc: Christoph Hellwig <hch@lst.de>,
	"Martin K. Petersen" <martin.petersen@oracle.com>,
	linux-ide@vger.kernel.org, linux-scsi@vger.kernel.org
Subject: Re: [PATCH 2/6] libata: Report supported TRIM payload size
Date: Fri, 20 Aug 2010 14:28:34 -0400	[thread overview]
Message-ID: <4C6EC952.4010706@teksavvy.com> (raw)
In-Reply-To: <AANLkTikMkNsqS=nmCmGY4t9bKouaeDC8aAxybcykBSBF@mail.gmail.com>

On 10-08-20 01:13 PM, Greg Freemyer wrote:
> On Fri, Aug 20, 2010 at 9:53 AM, Mark Lord<kernel@teksavvy.com>  wrote:
>> On 10-08-20 04:58 AM, Christoph Hellwig wrote:
>>>
>>> On Thu, Aug 19, 2010 at 05:50:11PM -0400, Mark Lord wrote:
>>>>
>>>> On 10-08-19 02:05 PM, Martin K. Petersen wrote:
>>>>>
>>>>> I'm only aware of one drive that currently
>>>>> supports more than 512 bytes of payload and it also caps at 4KB.
>>>>
>>>> SSDs based upon the Indilinx Barefoot controller support
>>>> more or less "infinite" payload for TRIM, with no cap.
>>>> But it predates idword[105], so just has a zero there.
>>>
>>> Is there an easy way to identify them?  If so we could add a quirk
>>> for them if it provides enough benefit.
..
> A whitelist to enable large contiguous range trims via 8 512B-block
> payloads seems useful for those devices that don't support word 105.
> (ie. 4KB payload)
>
> But, I doubt there is enough observable performance advantage to
> justify reworking the internal SCSI-ATA translation mechanism in the
> kernel to handle larger payloads.   Especially if only one or two SSDs
> will accept greater than 4KB of payload to the trim command.
..

Actually, for in-kernel uses, even just a single 512-byte long list
would likely be adequate.  The biggest gains will come from simply
having more than one range per TRIM command issued.

Once we get that, it's diminishing returns for larger and larger lists,
and in-kernel code is unlikely to ever be able to generate lists that long.

But getting started should be easier than folks are making it out to be.
The first step is to have "file deletion" issue multi-range trims for
all extents of the file at once, rather than one range at a time as at present.

That'll be the biggest gain, and shouldn't be too complex to implement.
Especially not after Christoph/Tejun's current barrier rework stuff is in place.

  reply	other threads:[~2010-08-20 18:28 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-19 15:48 Discard/trim/thin provisioning update Martin K. Petersen
2010-08-19 15:48 ` [PATCH 1/6] libata: Signal that our SATL supports WRITE SAME(16) with UNMAP Martin K. Petersen
2010-08-19 16:15   ` James Bottomley
2010-08-19 16:20     ` Martin K. Petersen
2010-08-23  8:32   ` Tejun Heo
2010-08-23 18:22     ` Douglas Gilbert
2010-08-23 18:29       ` Douglas Gilbert
2010-08-23 19:11         ` Martin K. Petersen
2010-08-19 15:48 ` [PATCH 2/6] libata: Report supported TRIM payload size Martin K. Petersen
2010-08-19 17:27   ` Greg Freemyer
2010-08-19 18:05     ` Martin K. Petersen
2010-08-19 21:08       ` Greg Freemyer
2010-08-19 21:50       ` Mark Lord
2010-08-20  8:58         ` Christoph Hellwig
2010-08-20 13:53           ` Mark Lord
2010-08-20 17:13             ` Greg Freemyer
2010-08-20 18:28               ` Mark Lord [this message]
2010-08-23 13:50   ` Christoph Hellwig
2010-08-23 18:56     ` Martin K. Petersen
2010-08-19 15:48 ` [PATCH 3/6] block: Make max_discard_sectors sector_t Martin K. Petersen
2010-08-20  8:59   ` Christoph Hellwig
2010-08-19 15:48 ` [PATCH 4/6] scsi: Fix VPD page wrapper Martin K. Petersen
2010-08-19 15:49 ` [PATCH 5/6] scsi_debug: Update thin provisioning support Martin K. Petersen
2010-08-23 16:37   ` Douglas Gilbert
2010-08-19 15:49 ` [PATCH 6/6] sd: " Martin K. Petersen
2010-08-20  9:00   ` Christoph Hellwig
2010-08-23 19:06     ` Martin K. Petersen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4C6EC952.4010706@teksavvy.com \
    --to=kernel@teksavvy.com \
    --cc=greg.freemyer@gmail.com \
    --cc=hch@lst.de \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.