Commit 18914ab
srp: skip test if scsi_transport_srp module is loaded and in use
The srp/* tests requires exclusive access to scsi_transport_srp
module. Running srp/* tests would definitely fail if the test can't
get exclusive access of scsi_transport_srp module as shown below:
$ lsmod | grep scsi_transport_srp
scsi_transport_srp 327680 1 ibmvscsi
$ ./check srp/001
srp/001 (Create and remove LUNs) [failed]
runtime ... 0.249s
tests/srp/rc: line 263: /sys/class/srp_remote_ports/port-0:1/delete: Permission denied
tests/srp/rc: line 263: /sys/class/srp_remote_ports/port-0:1/delete: Permission denied
modprobe: FATAL: Module scsi_transport_srp is in use.
error: Invalid argument
error: Invalid argument
So if the scsi_transport_srp module is loaded and in use then skip
running srp/* tests.
Signed-off-by: Nilay Shroff <[email protected]>
Tested-by: Disha Goel <[email protected]>
Reviewed-by: Bart Van Assche <[email protected]>
[Shin'ichiro: removed extra spaces and fixed a shellcheck warning]
Signed-off-by: Shin'ichiro Kawasaki <[email protected]>1 parent 67aff55 commit 18914ab
2 files changed
+14
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
81 | 94 | | |
82 | 95 | | |
83 | 96 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| 64 | + | |
64 | 65 | | |
65 | 66 | | |
66 | 67 | | |
| |||
0 commit comments