Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

USB: usbtest - add alignment tests to test script

Enhance the test script to call the new tests added to usbtest
in order to detect host controllers that don't accept byte
aligned DMA.

The unaligned tests are called after their aligned
equivalents but for fewer iterations (since alignment
failure is generally immediate).

Signed-off-by: Martin Fuzzey <mfuzzey@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

authored by

Martin Fuzzey and committed by
Greg Kroah-Hartman
bc0f23dc c17d936e

+26
+26
tools/usb/hcd-tests.sh
··· 112 112 # this relies on some vendor-specific commands 113 113 echo "test 14: control writes" 114 114 do_test -t 14 -c 15000 -s 256 -v 1 115 + 116 + echo "test 21: control writes, unaligned" 117 + do_test -t 21 -c 100 -s 256 -v 1 118 + 115 119 ;; 116 120 117 121 out) ··· 126 122 do_test -t 1 127 123 echo "test 3: $COUNT transfers, variable/short size" 128 124 do_test -t 3 -v 421 125 + 126 + COUNT=100 127 + echo "test 17: $COUNT transfers, unaligned DMA map by core" 128 + do_test -t 17 129 + 130 + echo "test 19: $COUNT transfers, unaligned DMA map by usb_alloc_coherent" 131 + do_test -t 19 129 132 130 133 COUNT=2000 131 134 echo "test 5: $COUNT scatterlists, same size entries" ··· 170 159 # FIXME it'd make sense to have an iso OUT test issuing 171 160 # short writes on more packets than the last one 172 161 162 + COUNT=100 163 + echo "test 22: $COUNT transfers, non aligned" 164 + do_test -t 22 -g 8 -v 0 165 + 173 166 ;; 174 167 175 168 in) ··· 187 172 do_test -t 2 188 173 echo "test 4: $COUNT transfers, variable size" 189 174 do_test -t 4 175 + 176 + COUNT=100 177 + echo "test 18: $COUNT transfers, unaligned DMA map by core" 178 + do_test -t 18 179 + 180 + echo "test 20: $COUNT transfers, unaligned DMA map by usb_alloc_coherent" 181 + do_test -t 20 190 182 191 183 COUNT=2000 192 184 echo "test 6: $COUNT scatterlists, same size entries" ··· 222 200 223 201 # FIXME since iso expects faults, it'd make sense 224 202 # to have an iso IN test issuing short reads ... 203 + 204 + COUNT=100 205 + echo "test 23: $COUNT transfers, unaligned" 206 + do_test -t 23 -g 8 -v 0 225 207 226 208 ;; 227 209