@@ -40,6 +40,26 @@ the drives can vary by type, so we have one macro by type of drive.
4040{% endfor %}
4141<!-- End of virtio drives-->
4242{% - endmacro -%}
43+ {% - macro gen_drive_scsi (num_drives ,
44+ kdevops_storage_pool_path ,
45+ hostname ,
46+ libvirt_extra_drive_format ,
47+ libvirt_extra_storage_aio_mode ,
48+ libvirt_extra_storage_aio_cache_mode ) -%}
49+ <!-- We generated {{ num_drives }} scsi dives -->
50+ {% for n in range (0,num_drives ) %}
51+ <!-- This is scsi drive # {{ n + 1 }} -->
52+ <qemu:arg value =' -device' />
53+ <qemu:arg value =' pcie-root-port,id=pcie-port-for-scsi-{{ n }},multifunction=on,bus=pcie.1,addr=0x{{ "%0x" | format( n | int) }},chassis=5{{ n }}' />
54+ <qemu:arg value =' -device' />
55+ <qemu:arg value =' virtio-scsi-pci,id=scsi{{ n }},bus=pcie-port-for-scsi-{{ n }},addr=0x0' />
56+ <qemu:arg value =' -drive' />
57+ <qemu:arg value =' file={{ kdevops_storage_pool_path }}/guestfs/{{ hostname }}/extra{{ n }}.{{ libvirt_extra_drive_format }},format={{ libvirt_extra_drive_format }},if=none,aio={{ libvirt_extra_storage_aio_mode }},cache={{ libvirt_extra_storage_aio_cache_mode }},id=drv{{ n }}' />
58+ <qemu:arg value =' -device' />
59+ <qemu:arg value =' scsi-hd,drive=drv{{ n }},bus=scsi{{ n }}.0' />
60+ {% endfor %}
61+ <!-- End of scsi drives-->
62+ {% - endmacro -%}
4363{% - macro gen_drive_large_io_virtio (libvirt_largeio_logical_compat ,
4464 libvirt_largeio_logical_compat_size ,
4565 libvirt_largeio_pow_limit ,
@@ -49,7 +69,7 @@ the drives can vary by type, so we have one macro by type of drive.
4969 libvirt_extra_storage_aio_mode ,
5070 libvirt_extra_storage_aio_cache_mode ,
5171 kdevops_storage_pool_path ) -%}
52- <!-- These are virtio drives used for large IO experimentaiton , with LBS support -->
72+ <!-- These are virtio drives used for large IO experimentation , with LBS support -->
5373{% set ns = namespace (lbs_idx =0) %}
5474{% set max_pbs = libvirt_largeio_logical_compat_size * (2 ** libvirt_largeio_pow_limit ) %}
5575{% for n in range (0,libvirt_largeio_pow_limit +1) %}
@@ -106,7 +126,7 @@ the drives can vary by type, so we have one macro by type of drive.
106126 libvirt_extra_storage_aio_mode ,
107127 libvirt_extra_storage_aio_cache_mode ,
108128 kdevops_storage_pool_path ) -%}
109- <!-- These are NVMe drives used for large IO experimentaiton , with LBS support -->
129+ <!-- These are NVMe drives used for large IO experimentation , with LBS support -->
110130{% set ns = namespace (lbs_idx =0) %}
111131{% set max_pbs = libvirt_largeio_logical_compat_size * (2 ** libvirt_largeio_pow_limit ) %}
112132{% for n in range (0,libvirt_largeio_pow_limit +1) %}
0 commit comments