Commit 81e99deb authored by Julien Muchembled's avatar Julien Muchembled

kvm: enable TRIM on raw images

When the image is a block device, the guest must also run Linux >= 5.0.
parent 9ae8e791
...@@ -55,7 +55,7 @@ md5sum = 2036bf145f472f62ef8dee5e729328fd ...@@ -55,7 +55,7 @@ md5sum = 2036bf145f472f62ef8dee5e729328fd
[template-kvm-run] [template-kvm-run]
filename = template/template-kvm-run.in filename = template/template-kvm-run.in
md5sum = 2a49e6065a3f46f871318ba88f0cd235 md5sum = 2c3e788632910a061b5272dfef5caa73
[template-kvm-controller] [template-kvm-controller]
filename = template/kvm-controller-run.in filename = template/kvm-controller-run.in
......
...@@ -242,7 +242,8 @@ additional_disk_options = '' ...@@ -242,7 +242,8 @@ additional_disk_options = ''
if disk_aio == 'native': if disk_aio == 'native':
additional_disk_options += ',cache.direct=on' additional_disk_options += ',cache.direct=on'
if disk_format == "raw":
additional_disk_options += ',discard=on'
# Generate network parameters # Generate network parameters
# XXX: use_tap should be a boolean # XXX: use_tap should be a boolean
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment