qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 0/5] add TRIM/UNMAP support
@ 2010-11-25 13:56 Christoph Hellwig
  2010-11-25 13:57 ` [Qemu-devel] [PATCH 1/5] block: add discard support Christoph Hellwig
                   ` (5 more replies)
  0 siblings, 6 replies; 27+ messages in thread
From: Christoph Hellwig @ 2010-11-25 13:56 UTC (permalink / raw)
  To: qemu-devel

This patchset adds support for the ATA TRIM and SCSI WRITE SAME with
unmap commands, which allow reclaiming free space from a backing image.

The user facing implementation is pretty complete, but not really
efficient because the underlying bdrv_discard implementation doesn't
use the aio implementation yet.  The reason for that is that the SCSI
layer doesn't really allow any asynchronous commands except for
READ/WRITE by design, and implementing the ATA TRIM command with it's
multiple ranges is rather painful, and combined with the SCSI limitation
I didn't bother yet.  The only backend support so far is the XFS hole
punching ioctl, but others can be added easily when they become
available.  A virtio implementation for a discard command would also
be pretty easy, but until we actually support a better backend then
a plain sparse file it's not worth using for production enviroments
anyway, but more for playing with the thin provisioning infrastructure,
or observing guest behaviour when TRIM / unmap is supported.

If the support is enabled and the backend doesn't support hole punching
the TRIM / WRITE SAME commands become no-ops so that migration from
hosts supporting or not supporting it works.

^ permalink raw reply	[flat|nested] 27+ messages in thread

end of thread, other threads:[~2010-12-13 16:24 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-25 13:56 [Qemu-devel] [PATCH 0/5] add TRIM/UNMAP support Christoph Hellwig
2010-11-25 13:57 ` [Qemu-devel] [PATCH 1/5] block: add discard support Christoph Hellwig
2010-11-25 14:09   ` malc
2010-11-25 14:45   ` Stefan Hajnoczi
2010-11-25 13:57 ` [Qemu-devel] [PATCH 2/5] scsi-disk: support WRITE SAME (16) with unmap bit Christoph Hellwig
2010-11-25 14:10   ` malc
2010-11-25 13:57 ` [Qemu-devel] [PATCH 3/5] make dma_bdrv_io available to drivers Christoph Hellwig
2010-11-25 13:57 ` [Qemu-devel] [PATCH 4/5] ide: add TRIM support Christoph Hellwig
2010-11-25 14:10   ` malc
2010-11-25 13:57 ` [Qemu-devel] [PATCH 5/5] raw-posix: add discard support Christoph Hellwig
2010-12-01 15:35 ` [Qemu-devel] PATCH 0/5] add TRIM/UNMAP support, v2 Christoph Hellwig
2010-12-01 15:35   ` [Qemu-devel] [PATCH 1/5] block: add discard support Christoph Hellwig
2010-12-02 12:12     ` Kevin Wolf
2010-12-10 13:38       ` Christoph Hellwig
2010-12-11 12:50         ` Paul Brook
2010-12-13 15:43           ` Christoph Hellwig
2010-12-13 16:17             ` Paul Brook
2010-12-13 16:07         ` [Qemu-devel] " Paolo Bonzini
2010-12-13 16:15           ` Christoph Hellwig
2010-12-13 16:24             ` Paolo Bonzini
2010-12-01 15:35   ` [Qemu-devel] [PATCH 2/5] scsi-disk: support WRITE SAME (16) with unmap bit Christoph Hellwig
2010-12-01 15:35   ` [Qemu-devel] [PATCH 3/5] make dma_bdrv_io available to drivers Christoph Hellwig
2010-12-01 15:35   ` [Qemu-devel] [PATCH 4/5] ide: add TRIM support Christoph Hellwig
2010-12-02 14:07     ` Kevin Wolf
2010-12-10 13:39       ` Christoph Hellwig
2010-12-01 15:35   ` [Qemu-devel] [PATCH 5/5] raw-posix: add discard support Christoph Hellwig
2010-12-02 12:04     ` Kevin Wolf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).