xref: /openbmc/linux/tools/pci/pcitest.sh (revision fb8d6c8d)
1#!/bin/sh
2# SPDX-License-Identifier: GPL-2.0
3
4echo "BAR tests"
5echo
6
7bar=0
8
9while [ $bar -lt 6 ]
10do
11	pcitest -b $bar
12	bar=`expr $bar + 1`
13done
14echo
15
16echo "Interrupt tests"
17echo
18
19pcitest -i 0
20pcitest -l
21
22pcitest -i 1
23msi=1
24
25while [ $msi -lt 33 ]
26do
27        pcitest -m $msi
28        msi=`expr $msi + 1`
29done
30echo
31
32pcitest -i 2
33msix=1
34
35while [ $msix -lt 2049 ]
36do
37        pcitest -x $msix
38        msix=`expr $msix + 1`
39done
40echo
41
42echo "Read Tests"
43echo
44
45pcitest -i 1
46
47pcitest -r -s 1
48pcitest -r -s 1024
49pcitest -r -s 1025
50pcitest -r -s 1024000
51pcitest -r -s 1024001
52echo
53
54echo "Write Tests"
55echo
56
57pcitest -w -s 1
58pcitest -w -s 1024
59pcitest -w -s 1025
60pcitest -w -s 1024000
61pcitest -w -s 1024001
62echo
63
64echo "Copy Tests"
65echo
66
67pcitest -c -s 1
68pcitest -c -s 1024
69pcitest -c -s 1025
70pcitest -c -s 1024000
71pcitest -c -s 1024001
72echo
73