mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-08-08 03:24:15 +00:00
Merge pull request #10660 from BbolroC/fix-leading-zero-issue-for-vfio-ap
vfio-ap: Assign default string "0" for empty APID and APQI
This commit is contained in:
commit
cfbc425041
@ -156,7 +156,9 @@ create_mediated_device() {
|
|||||||
_APID=${APQN//.*}
|
_APID=${APQN//.*}
|
||||||
_APQI=${APQN#*.}
|
_APQI=${APQN#*.}
|
||||||
APID=$(echo ${_APID} | sed 's/^0*//')
|
APID=$(echo ${_APID} | sed 's/^0*//')
|
||||||
|
APID=${APID:-0}
|
||||||
APQI=$(echo ${_APQI} | sed 's/^0*//')
|
APQI=$(echo ${_APQI} | sed 's/^0*//')
|
||||||
|
APQI=${APQI:-0}
|
||||||
|
|
||||||
# Release the device from the host
|
# Release the device from the host
|
||||||
pushd ${sys_bus_base}
|
pushd ${sys_bus_base}
|
||||||
|
Loading…
Reference in New Issue
Block a user