aboutsummaryrefslogtreecommitdiffstats
path: root/sys/linux/test
diff options
context:
space:
mode:
authorAndrey Konovalov <andreyknvl@google.com>2020-05-13 19:48:00 +0200
committerAndrey Konovalov <andreyknvl@gmail.com>2020-05-15 16:30:32 +0200
commit8a9f1e7dbdb76a9c0af0dc6e3e75e446a7838dc8 (patch)
tree1863b21867cc76a68b88dea31c832ac658f75527 /sys/linux/test
parent55efafca377a08f2bc5509eb7eda3568ae9cde4e (diff)
executor, sys/linux: syz_usb_ep_read/write accept endpoint address
This patch changes syz_usb_ep_read/write pseudo-syscalls to accept endpoint address as specified in its endpoint descriptor, instead of endpoint index.
Diffstat (limited to 'sys/linux/test')
-rw-r--r--sys/linux/test/vusb_ath9k2
-rw-r--r--sys/linux/test/vusb_cdc_ecm2
-rw-r--r--sys/linux/test/vusb_cdc_ncm2
-rw-r--r--sys/linux/test/vusb_hid6
4 files changed, 6 insertions, 6 deletions
diff --git a/sys/linux/test/vusb_ath9k b/sys/linux/test/vusb_ath9k
index bd095a9cb..a728664f0 100644
--- a/sys/linux/test/vusb_ath9k
+++ b/sys/linux/test/vusb_ath9k
@@ -1,4 +1,4 @@
# requires: -repeat
r0 = syz_usb_connect_ath9k(0x3, 0x5a, &(0x7f0000000080)={{0x12, 0x1, 0x200, 0xff, 0xff, 0xff, 0x40, 0xcf3, 0x9271, 0x108, 0x1, 0x2, 0x3, 0x1, [{{0x9, 0x2, 0x48, 0x1, 0x1, 0x0, 0x80, 0xfa, {{0x9, 0x4, 0x0, 0x0, 0x6, 0xff, 0x0, 0x0, 0x0, "", {{0x9, 0x5, 0x1, 0x2, 0x200, 0x0, 0x0, 0x0, ""}, {0x9, 0x5, 0x82, 0x2, 0x200, 0x0, 0x0, 0x0, ""}, {0x9, 0x5, 0x83, 0x3, 0x40, 0x1, 0x0, 0x0, ""}, {0x9, 0x5, 0x4, 0x3, 0x40, 0x1, 0x0, 0x0, ""}, {0x9, 0x5, 0x5, 0x2, 0x200, 0x0, 0x0, 0x0, ""}, {0x9, 0x5, 0x6, 0x2, 0x200, 0x0, 0x0, 0x0, ""}}}}}}]}}, 0x0)
-syz_usb_ep_write$ath9k_ep2(r0, 0x2, 0x10, &(0x7f0000000000)=@ready={0x0, 0x0, 0x8, 'BBBB', {0x1, 0x0, 0x0, 0x0, 0x0}})
+syz_usb_ep_write$ath9k_ep2(r0, 0x83, 0x10, &(0x7f0000000000)=@ready={0x0, 0x0, 0x8, 'BBBB', {0x1, 0x0, 0x0, 0x0, 0x0}})
diff --git a/sys/linux/test/vusb_cdc_ecm b/sys/linux/test/vusb_cdc_ecm
index 848158cc4..d6997255c 100644
--- a/sys/linux/test/vusb_cdc_ecm
+++ b/sys/linux/test/vusb_cdc_ecm
@@ -4,4 +4,4 @@ r0 = syz_usb_connect$cdc_ecm(0x0, 0x4d, &(0x7f0000000000)={{0x12, 0x1, 0x0, 0x2,
syz_usb_control_io$cdc_ecm(r0, 0x0, 0x0)
syz_usb_control_io$cdc_ecm(r0, 0x0, 0x0)
syz_usb_control_io$cdc_ecm(r0, &(0x7f0000000080)={0x14, 0x0, &(0x7f0000000040)={0x0, 0x3, 0x1a, {0x1a, 0x3, {0x3400320034003200, 0x3400320034003200, 0x3400320034003200}}}}, 0x0)
-syz_usb_ep_write(r0, 0x0, 0x5, &(0x7f0000002340)='hello')
+syz_usb_ep_write(r0, 0x82, 0x5, &(0x7f0000002340)='hello')
diff --git a/sys/linux/test/vusb_cdc_ncm b/sys/linux/test/vusb_cdc_ncm
index f360a6dd3..4ffdb5efa 100644
--- a/sys/linux/test/vusb_cdc_ncm
+++ b/sys/linux/test/vusb_cdc_ncm
@@ -6,4 +6,4 @@ syz_usb_control_io$cdc_ncm(r0, 0x0, 0x0)
syz_usb_control_io$cdc_ncm(r0, 0x0, &(0x7f0000000340)={0x44, 0x0, 0x0, 0x0, &(0x7f0000000200)={0x20, 0x80, 0x1c, {0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10}}, 0x0, 0x0, 0x0, 0x0})
syz_usb_control_io$cdc_ncm(r0, 0x0, 0x0)
syz_usb_control_io$cdc_ncm(r0, &(0x7f0000000080)={0x14, 0x0, &(0x7f0000000040)={0x0, 0x3, 0x1a, {0x1a, 0x3, {0x3400320034003200, 0x3400320034003200, 0x3400320034003200}}}}, 0x0)
-syz_usb_ep_write(r0, 0x0, 0x5, &(0x7f0000002340)='hello')
+syz_usb_ep_write(r0, 0x82, 0x5, &(0x7f0000002340)='hello')
diff --git a/sys/linux/test/vusb_hid b/sys/linux/test/vusb_hid
index de77a8dc2..b092470f9 100644
--- a/sys/linux/test/vusb_hid
+++ b/sys/linux/test/vusb_hid
@@ -3,6 +3,6 @@
r0 = syz_usb_connect$hid(0x0, 0x36, &(0x7f0000000040)=ANY=[@ANYBLOB="12010000000018105e04da07000000000001090224000100000000090400000903000000092100000001222200090581030800000000"], 0x0)
syz_usb_control_io$hid(r0, 0x0, 0x0)
syz_usb_control_io$hid(r0, &(0x7f00000001c0)={0x24, 0x0, 0x0, &(0x7f0000000000)={0x0, 0x22, 0x22, {[@global=@item_012={0x2, 0x1, 0x9, "2313"}, @global=@item_012={0x2, 0x1, 0x0, "e53f"}, @global=@item_4={0x3, 0x1, 0x0, '\f\x00'}, @local=@item_012={0x2, 0x2, 0x2, "9000"}, @global=@item_4={0x3, 0x1, 0x0, "0900be00"}, @main=@item_4={0x3, 0x0, 0x8, '\x00'}, @local=@item_4={0x3, 0x2, 0x0, "09007a15"}, @local=@item_4={0x3, 0x2, 0x0, "5d8c3dda"}]}}, 0x0}, 0x0)
-syz_usb_ep_write(r0, 0x0, 0x7, &(0x7f0000000000)='BBBBBBB')
-syz_usb_ep_write(r0, 0x0, 0x7, &(0x7f0000000000)='BBBBBBB')
-syz_usb_ep_write(r0, 0x0, 0x7, &(0x7f0000000000)='BBBBBBB')
+syz_usb_ep_write(r0, 0x81, 0x7, &(0x7f0000000000)='BBBBBBB')
+syz_usb_ep_write(r0, 0x81, 0x7, &(0x7f0000000000)='BBBBBBB')
+syz_usb_ep_write(r0, 0x81, 0x7, &(0x7f0000000000)='BBBBBBB')