virt-manager/virtinst
Lin Ma febddd4b01 cli: Add --memdev target.address_base for virtio-mem and virtio-pmem
Libvirt(since 9.4.0) allows to control this attribute for virtio-{mem,pmem}.
Now add it into virt-install.

Example:
virt-install \
--name test \
--os-variant opensusetumbleweed \
--cdrom /isos/openSUSE-Tumbleweed-DVD-x86_64-Current.iso \
--disk /vms/tw/disk0.qcow2 \
--vcpu 2 \
--cpu cell0.cpus=0,cell0.memory=4194304,\
cell1.cpus=1,cell1.memory=4194304 \
--memory maxMemory=65536,maxMemory.slots=8 \
--memdev model=virtio-mem,\
target.node=0,\
target.block=2048,\
target.size=8192,\
target.requested=2097152,\
target.address_base=0x280000000 \
--memdev model=virtio-pmem,\
source.path=/tmp/virtio_pmem,\
target.size=4096,\
target.address_base=0x480000000

It results in the following domain XML snippet:
    <memory model='virtio-mem'>
      <target>
        <size unit='KiB'>8388608</size>
        <node>0</node>
        <block unit='KiB'>2048</block>
        <requested unit='KiB'>2097152</requested>
        <current unit='KiB'>0</current>
        <address base='0x280000000'/>
      </target>
      <alias name='virtiomem0'/>
      <address type='pci' domain='0x0000' bus='0x07' slot='0x00' function='0x0'/>
    </memory>
    <memory model='virtio-pmem' access='shared'>
      <source>
        <path>/tmp/virtio_pmem</path>
      </source>
      <target>
        <size unit='KiB'>2097152</size>
        <address base='0x480000000'/>
      </target>
      <alias name='virtiopmem0'/>
      <address type='pci' domain='0x0000' bus='0x08' slot='0x00' function='0x0'/>
    </memory>

Reviewed-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Lin Ma <lma@suse.de>
2024-09-08 11:25:32 -04:00
..
devices cli: Add --memdev target.address_base for virtio-mem and virtio-pmem 2024-09-08 11:25:32 -04:00
domain cli: Add --features kvm.pv-ipi.state=on|off 2024-09-08 11:25:32 -04:00
install virt-install: fix cloud-init ssh keys 2024-07-25 16:50:34 +02:00
__init__.py i18n: globally install also the ngettext function 2020-07-14 11:24:14 -04:00
_progresspriv.py virtinstall: Hide total_size in the progress bar if it doesn't need 2022-12-14 13:18:36 -05:00
buildconfig.py Prep for release 4.1.0 2022-08-04 15:53:33 -04:00
capabilities.py virtinst: enable most Hyper-V features by default 2024-09-06 14:15:09 -04:00
cli.py cli: Add --memdev target.address_base for virtio-mem and virtio-pmem 2024-09-08 11:25:32 -04:00
cloner.py cloner: clone serial files 2023-03-22 17:44:06 -04:00
connection.py connection: De-duplicate ui and cli version logging 2022-08-01 06:04:48 -04:00
diskbackend.py Fix some pylint 2024-01-22 17:15:11 -05:00
domcapabilities.py domcapabilities: get list of supported Hyper-V features 2024-09-06 14:15:09 -04:00
generatename.py generatename: Move libvirt collision handling to callers 2019-06-11 17:54:45 -04:00
guest.py virtinst: add/remove spice devices when updating graphics type 2024-08-26 12:33:51 -04:00
logger.py tests: abide logging options for clitests 2019-12-11 17:57:28 -05:00
network.py hostnets: Remove SR-IOV info listing 2019-06-16 23:48:51 -04:00
nodedev.py nodedev: Move the CLI string format lookup to cli.py 2022-01-21 13:20:46 -05:00
osdict.py tests: test win11 XML generation 2023-01-19 11:54:03 -05:00
pollhelpers.py Fix pylint/pycodestyle warnings with latest versions 2022-12-13 11:23:45 -05:00
progress.py progress: Drop tqdm and revert back to local urlgrabber copy 2021-06-09 16:52:11 -04:00
snapshot.py virtinst: snapshot: add memory file attribute 2024-03-25 13:21:50 +01:00
storage.py virt-clone: Copy disk permissions as well 2023-09-10 11:19:31 -04:00
support.py virtinst.support: drop unused conn_hyperv_vapic function 2024-09-06 14:15:09 -04:00
uri.py uri: Mock domcaps returning NO_SUPPORT 2024-01-22 17:07:31 -05:00
virtclone.py Remove shebangs from library paths 2021-06-22 19:54:37 -04:00
virtinstall.py Fix pylint/pycodestyle warnings with latest versions 2022-12-13 11:23:45 -05:00
virtxml.py Revert virt-xml multiple --edit support 2024-08-28 21:09:31 +02:00
xmlapi.py cli: Add --xml xpath option for virt-install and virt-xml 2020-09-11 15:04:37 -04:00
xmlbuilder.py Fix some pylint 2023-09-12 11:54:04 -04:00
xmlutil.py xmlutil: Take unindent_device_xml from details.py 2022-08-03 12:34:47 -04:00