···11+The virtual channel subsystem
22+=============================
33+44+QEMU implements a virtual channel subsystem with subchannels, (mostly
55+functionless) channel paths, and channel devices (virtio-ccw, 3270, and
66+devices passed via vfio-ccw). It supports multiple subchannel sets (MSS) and
77+multiple channel subsystems extended (MCSS-E).
88+99+All channel devices support the ``devno`` property, which takes a parameter
1010+in the form ``<cssid>.<ssid>.<device number>``.
1111+1212+The default channel subsystem image id (``<cssid>``) is ``0xfe``. Devices in
1313+there will show up in channel subsystem image ``0`` to guests that do not
1414+enable MCSS-E. Note that devices with a different cssid will not be visible
1515+if the guest OS does not enable MCSS-E (which is true for all supported guest
1616+operating systems today).
1717+1818+Supported values for the subchannel set id (``<ssid>``) range from ``0-3``.
1919+Devices with a ssid that is not ``0`` will not be visible if the guest OS
2020+does not enable MSS (any Linux version that supports virtio also enables MSS).
2121+Any device may be put into any subchannel set, there is no restriction by
2222+device type.
2323+2424+The device number can range from ``0-0xffff``.
2525+2626+If the ``devno`` property is not specified for a device, QEMU will choose the
2727+next free device number in subchannel set 0, skipping to the next subchannel
2828+set if no more device numbers are free.
2929+3030+QEMU places a device at the first free subchannel in the specified subchannel
3131+set. If a device is hotunplugged and later replugged, it may appear at a
3232+different subchannel. (This is similar to how z/VM works.)
3333+3434+3535+Examples
3636+--------
3737+3838+* a virtio-net device, cssid/ssid/devno automatically assigned::
3939+4040+ -device virtio-net-ccw
4141+4242+ In a Linux guest (without default devices and no other devices specified
4343+ prior to this one), this will show up as ``0.0.0000`` under subchannel
4444+ ``0.0.0000``.
4545+4646+ The auto-assigned-properties in QEMU (as seen via e.g. ``info qtree``)
4747+ would be ``dev_id = "fe.0.0000"`` and ``subch_id = "fe.0.0000"``.
4848+4949+* a virtio-rng device in subchannel set ``0``::
5050+5151+ -device virtio-rng-ccw,devno=fe.0.0042
5252+5353+ If added to the same Linux guest as above, it would show up as ``0.0.0042``
5454+ under subchannel ``0.0.0001``.
5555+5656+ The properties for the device would be ``dev_id = "fe.0.0042"`` and
5757+ ``subch_id = "fe.0.0001"``.
5858+5959+* a virtio-gpu device in subchannel set ``2``::
6060+6161+ -device virtio-gpu-ccw,devno=fe.2.1111
6262+6363+ If added to the same Linux guest as above, it would show up as ``0.2.1111``
6464+ under subchannel ``0.2.0000``.
6565+6666+ The properties for the device would be ``dev_id = "fe.2.1111"`` and
6767+ ``subch_id = "fe.2.0000"``.
6868+6969+* a virtio-mouse device in a non-standard channel subsystem image::
7070+7171+ -device virtio-mouse-ccw,devno=2.0.2222
7272+7373+ This would not show up in a standard Linux guest.
7474+7575+ The properties for the device would be ``dev_id = "2.0.2222"`` and
7676+ ``subch_id = "2.0.0000"``.
7777+7878+* a virtio-keyboard device in another non-standard channel subsystem image::
7979+8080+ -device virtio-keyboard-ccw,devno=0.0.1234
8181+8282+ This would not show up in a standard Linux guest, either, as ``0`` is not
8383+ the standard channel subsystem image id.
8484+8585+ The properties for the device would be ``dev_id = "0.0.1234"`` and
8686+ ``subch_id = "0.0.0000"``.
+1
docs/system/target-s390x.rst
···23232424.. toctree::
2525 s390x/vfio-ap
2626+ s390x/css
26272728Architectural features
2829======================