Skip to content

Commit

Permalink
Cut down serial characters length
Browse files Browse the repository at this point in the history
QEMU error info:
The serial number can't be longer than 20 characters when it is
also used as the default for device_id

Signed-off-by: ybduan <[email protected]>
  • Loading branch information
ybduan committed Oct 18, 2024
1 parent aa143f5 commit cba8aab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion qemu/tests/usb_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ def _check_io_size_option(min_io_size="512", opt_io_size="0"):
# this part is linux only
if params.get("check_serial_option") == "yes":
error_context.context("Check usb serial option", test.log.info)
serial = uuid.uuid4().hex
serial = uuid.uuid4().hex[:20]
regex_str = r'usb-storage.*?serial = "(.*?)"\s'
_check_serial_option(serial, regex_str, serial)

Expand Down

0 comments on commit cba8aab

Please sign in to comment.