<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/tools/pci, branch master</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>selftests: Move PCI Endpoint tests from tools/pci to Kselftests</title>
<updated>2025-01-21T20:17:55+00:00</updated>
<author>
<name>Manivannan Sadhasivam</name>
<email>manivannan.sadhasivam@linaro.org</email>
</author>
<published>2025-01-16T17:16:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e19bde2269ca3611156fd0c078a71af0b6956545'/>
<id>e19bde2269ca3611156fd0c078a71af0b6956545</id>
<content type='text'>
This just moves the existing tests under tools/pci to
tools/testing/selftests/pci_endpoint and adjusts the paths in Makefile
accordingly. Migration to Kselftest framework will be done in subsequent
commits.

Link: https://lore.kernel.org/r/20250116171650.33585-4-manivannan.sadhasivam@linaro.org
Signed-off-by: Manivannan Sadhasivam &lt;manivannan.sadhasivam@linaro.org&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Tested-by: Niklas Cassel &lt;cassel@kernel.org&gt;
Reviewed-by: Niklas Cassel &lt;cassel@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This just moves the existing tests under tools/pci to
tools/testing/selftests/pci_endpoint and adjusts the paths in Makefile
accordingly. Migration to Kselftest framework will be done in subsequent
commits.

Link: https://lore.kernel.org/r/20250116171650.33585-4-manivannan.sadhasivam@linaro.org
Signed-off-by: Manivannan Sadhasivam &lt;manivannan.sadhasivam@linaro.org&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Tested-by: Niklas Cassel &lt;cassel@kernel.org&gt;
Reviewed-by: Niklas Cassel &lt;cassel@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>misc: pci_endpoint_test: Fix IOCTL return value</title>
<updated>2025-01-21T20:17:55+00:00</updated>
<author>
<name>Manivannan Sadhasivam</name>
<email>manivannan.sadhasivam@linaro.org</email>
</author>
<published>2025-01-16T17:16:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f26d37ee9bda938e968d0e11ba1f8f1588b2a135'/>
<id>f26d37ee9bda938e968d0e11ba1f8f1588b2a135</id>
<content type='text'>
IOCTLs are supposed to return 0 for success and negative error codes for
failure. Currently, this driver is returning 0 for failure and 1 for
success, that's not correct. Hence, fix it!

Link: https://lore.kernel.org/r/20250116171650.33585-3-manivannan.sadhasivam@linaro.org
Fixes: 2c156ac71c6b ("misc: Add host side PCI driver for PCI test function device")
Reported-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Closes: https://lore.kernel.org/r/YvzNg5ROnxEApDgS@kroah.com
Signed-off-by: Manivannan Sadhasivam &lt;manivannan.sadhasivam@linaro.org&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Tested-by: Niklas Cassel &lt;cassel@kernel.org&gt;
Reviewed-by: Damien Le Moal &lt;dlemoal@kernel.org&gt;
Reviewed-by: Niklas Cassel &lt;cassel@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
IOCTLs are supposed to return 0 for success and negative error codes for
failure. Currently, this driver is returning 0 for failure and 1 for
success, that's not correct. Hence, fix it!

Link: https://lore.kernel.org/r/20250116171650.33585-3-manivannan.sadhasivam@linaro.org
Fixes: 2c156ac71c6b ("misc: Add host side PCI driver for PCI test function device")
Reported-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Closes: https://lore.kernel.org/r/YvzNg5ROnxEApDgS@kroah.com
Signed-off-by: Manivannan Sadhasivam &lt;manivannan.sadhasivam@linaro.org&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Tested-by: Niklas Cassel &lt;cassel@kernel.org&gt;
Reviewed-by: Damien Le Moal &lt;dlemoal@kernel.org&gt;
Reviewed-by: Niklas Cassel &lt;cassel@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>misc: pci_endpoint_test: Add consecutive BAR test</title>
<updated>2025-01-21T15:44:14+00:00</updated>
<author>
<name>Niklas Cassel</name>
<email>cassel@kernel.org</email>
</author>
<published>2024-11-16T03:20:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d6658d3338f84173fb55c9d6c6cdfa57f879712d'/>
<id>d6658d3338f84173fb55c9d6c6cdfa57f879712d</id>
<content type='text'>
Add a more advanced BAR test that writes all BARs in one go, and then reads
them back and verifies that the value matches the BAR number bitwise OR'ed
with offset, this allows us to verify:

  - The BAR number was what we intended to read
  - The offset was what we intended to read

This allows us to detect potential address translation issues on the EP.

Reading back the BAR directly after writing will not allow us to detect the
case where inbound address translation on the endpoint incorrectly causes
multiple BARs to be redirected to the same memory region (within the EP).

Link: https://lore.kernel.org/r/20241116032045.2574168-2-cassel@kernel.org
Signed-off-by: Niklas Cassel &lt;cassel@kernel.org&gt;
Signed-off-by: Krzysztof Wilczyński &lt;kwilczynski@kernel.org&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Reviewed-by: Manivannan Sadhasivam &lt;manivannan.sadhasivam@linaro.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a more advanced BAR test that writes all BARs in one go, and then reads
them back and verifies that the value matches the BAR number bitwise OR'ed
with offset, this allows us to verify:

  - The BAR number was what we intended to read
  - The offset was what we intended to read

This allows us to detect potential address translation issues on the EP.

Reading back the BAR directly after writing will not allow us to detect the
case where inbound address translation on the endpoint incorrectly causes
multiple BARs to be redirected to the same memory region (within the EP).

Link: https://lore.kernel.org/r/20241116032045.2574168-2-cassel@kernel.org
Signed-off-by: Niklas Cassel &lt;cassel@kernel.org&gt;
Signed-off-by: Krzysztof Wilczyński &lt;kwilczynski@kernel.org&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Reviewed-by: Manivannan Sadhasivam &lt;manivannan.sadhasivam@linaro.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>tools: PCI: Fix incorrect printf format specifiers</title>
<updated>2024-11-20T20:20:51+00:00</updated>
<author>
<name>Luo Yifan</name>
<email>luoyifan@cmss.chinamobile.com</email>
</author>
<published>2024-11-12T09:09:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d9db393f2b9ed674f965dd823c1692b41bad7bfb'/>
<id>d9db393f2b9ed674f965dd823c1692b41bad7bfb</id>
<content type='text'>
Fix several incorrect printf format specifiers that misused signed and
unsigned versions.

Link: https://lore.kernel.org/r/20241112090924.287056-1-luoyifan@cmss.chinamobile.com
Signed-off-by: Luo Yifan &lt;luoyifan@cmss.chinamobile.com&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Reviewed-by: Manivannan Sadhasivam &lt;manivannan.sadhasivam@linaro.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix several incorrect printf format specifiers that misused signed and
unsigned versions.

Link: https://lore.kernel.org/r/20241112090924.287056-1-luoyifan@cmss.chinamobile.com
Signed-off-by: Luo Yifan &lt;luoyifan@cmss.chinamobile.com&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Reviewed-by: Manivannan Sadhasivam &lt;manivannan.sadhasivam@linaro.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>tools: PCI: Remove unused BILLION macro</title>
<updated>2024-09-13T22:37:06+00:00</updated>
<author>
<name>zhang jiao</name>
<email>zhangjiao2@cmss.chinamobile.com</email>
</author>
<published>2024-09-11T06:04:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d0aac667f2e02f114bc6c3bf8c085a6060599aef'/>
<id>d0aac667f2e02f114bc6c3bf8c085a6060599aef</id>
<content type='text'>
The macro BILLION is never referenced in the code.  Remove it.

Link: https://lore.kernel.org/r/20240911060401.9230-1-zhangjiao2@cmss.chinamobile.com
Signed-off-by: zhang jiao &lt;zhangjiao2@cmss.chinamobile.com&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Signed-off-by: Krzysztof Wilczyński &lt;kwilczynski@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The macro BILLION is never referenced in the code.  Remove it.

Link: https://lore.kernel.org/r/20240911060401.9230-1-zhangjiao2@cmss.chinamobile.com
Signed-off-by: zhang jiao &lt;zhangjiao2@cmss.chinamobile.com&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Signed-off-by: Krzysztof Wilczyński &lt;kwilczynski@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>tools: PCI: Remove .*.cmd files with make clean</title>
<updated>2024-09-13T22:37:06+00:00</updated>
<author>
<name>zhang jiao</name>
<email>zhangjiao2@cmss.chinamobile.com</email>
</author>
<published>2024-09-02T04:12:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=5dd15cce0c5426fff7b30c792d908e93646cd8c5'/>
<id>5dd15cce0c5426fff7b30c792d908e93646cd8c5</id>
<content type='text'>
Remove any leftover .*.cmd files with make clean.

No functional changes intended.

Link: https://lore.kernel.org/linux-pci/20240902041240.5475-1-zhangjiao2@cmss.chinamobile.com
Signed-off-by: zhang jiao &lt;zhangjiao2@cmss.chinamobile.com&gt;
[kwilczynski: commit log, move .*.cmd before .*.d to
align with other Makefiles, don't remove the newline]
Signed-off-by: Krzysztof Wilczyński &lt;kwilczynski@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Remove any leftover .*.cmd files with make clean.

No functional changes intended.

Link: https://lore.kernel.org/linux-pci/20240902041240.5475-1-zhangjiao2@cmss.chinamobile.com
Signed-off-by: zhang jiao &lt;zhangjiao2@cmss.chinamobile.com&gt;
[kwilczynski: commit log, move .*.cmd before .*.d to
align with other Makefiles, don't remove the newline]
Signed-off-by: Krzysztof Wilczyński &lt;kwilczynski@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>kbuild: replace $(if A,A,B) with $(or A,B)</title>
<updated>2022-02-15T03:25:56+00:00</updated>
<author>
<name>Masahiro Yamada</name>
<email>masahiroy@kernel.org</email>
</author>
<published>2022-02-11T05:14:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=5c8166419acf468b5bc3e48f928a040485d3e0c2'/>
<id>5c8166419acf468b5bc3e48f928a040485d3e0c2</id>
<content type='text'>
$(or ...) is available since GNU Make 3.81, and useful to shorten the
code in some places.

Covert as follows:

  $(if A,A,B)  --&gt;  $(or A,B)

This patch also converts:

  $(if A, A, B) --&gt; $(or A, B)

Strictly speaking, the latter is not an equivalent conversion because
GNU Make keeps spaces after commas; if A is not empty, $(if A, A, B)
expands to " A", while $(or A, B) expands to "A".

Anyway, preceding spaces are not significant in the code hunks I touched.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Reviewed-by: Nicolas Schier &lt;nicolas@fjasle.eu&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
$(or ...) is available since GNU Make 3.81, and useful to shorten the
code in some places.

Covert as follows:

  $(if A,A,B)  --&gt;  $(or A,B)

This patch also converts:

  $(if A, A, B) --&gt; $(or A, B)

Strictly speaking, the latter is not an equivalent conversion because
GNU Make keeps spaces after commas; if A is not empty, $(if A, A, B)
expands to " A", while $(or A, B) expands to "A".

Anyway, preceding spaces are not significant in the code hunks I touched.

Signed-off-by: Masahiro Yamada &lt;masahiroy@kernel.org&gt;
Reviewed-by: Nicolas Schier &lt;nicolas@fjasle.eu&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>tools: PCI: Zero-initialize param</title>
<updated>2021-08-05T10:01:30+00:00</updated>
<author>
<name>Shunyong Yang</name>
<email>yang.shunyong@gmail.com</email>
</author>
<published>2021-07-14T13:23:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=224d8031e482bb83e2166779f46c7bb1a5f4a888'/>
<id>224d8031e482bb83e2166779f46c7bb1a5f4a888</id>
<content type='text'>
The values in param may be random if they are not initialized, which
may cause use_dma flag set even when "-d" option is not provided
in command line. Initializing all members to 0 to solve this.

Link: https://lore.kernel.org/r/20210714132331.5200-1-yang.shunyong@gmail.com
Signed-off-by: Shunyong Yang &lt;yang.shunyong@gmail.com&gt;
Signed-off-by: Lorenzo Pieralisi &lt;lorenzo.pieralisi@arm.com&gt;
Acked-by: Kishon Vijay Abraham I &lt;kishon@ti.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The values in param may be random if they are not initialized, which
may cause use_dma flag set even when "-d" option is not provided
in command line. Initializing all members to 0 to solve this.

Link: https://lore.kernel.org/r/20210714132331.5200-1-yang.shunyong@gmail.com
Signed-off-by: Shunyong Yang &lt;yang.shunyong@gmail.com&gt;
Signed-off-by: Lorenzo Pieralisi &lt;lorenzo.pieralisi@arm.com&gt;
Acked-by: Kishon Vijay Abraham I &lt;kishon@ti.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>tools: PCI: Add 'e' to clear IRQ</title>
<updated>2020-04-02T16:57:10+00:00</updated>
<author>
<name>Kishon Vijay Abraham I</name>
<email>kishon@ti.com</email>
</author>
<published>2020-03-17T10:01:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=74d60b28d5bf1a12abe22d8d88240a4c5d1e3315'/>
<id>74d60b28d5bf1a12abe22d8d88240a4c5d1e3315</id>
<content type='text'>
Add a new command line option 'e' to invoke "PCITEST_CLEAR_IRQ"
ioctl. This can be used to clear the irqs set using the 'i' option.

Signed-off-by: Kishon Vijay Abraham I &lt;kishon@ti.com&gt;
Signed-off-by: Lorenzo Pieralisi &lt;lorenzo.pieralisi@arm.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a new command line option 'e' to invoke "PCITEST_CLEAR_IRQ"
ioctl. This can be used to clear the irqs set using the 'i' option.

Signed-off-by: Kishon Vijay Abraham I &lt;kishon@ti.com&gt;
Signed-off-by: Lorenzo Pieralisi &lt;lorenzo.pieralisi@arm.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>tools: PCI: Add 'd' command line option to support DMA</title>
<updated>2020-04-02T16:57:10+00:00</updated>
<author>
<name>Kishon Vijay Abraham I</name>
<email>kishon@ti.com</email>
</author>
<published>2020-03-16T11:24:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=73c5762652c538527f654b8eb9af47ae2c2434af'/>
<id>73c5762652c538527f654b8eb9af47ae2c2434af</id>
<content type='text'>
Add a new command line option 'd' to use DMA for data transfers.
It should be used with read, write or copy commands.

Signed-off-by: Kishon Vijay Abraham I &lt;kishon@ti.com&gt;
Signed-off-by: Lorenzo Pieralisi &lt;lorenzo.pieralisi@arm.com&gt;
Tested-by: Alan Mikhak &lt;alan.mikhak@sifive.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a new command line option 'd' to use DMA for data transfers.
It should be used with read, write or copy commands.

Signed-off-by: Kishon Vijay Abraham I &lt;kishon@ti.com&gt;
Signed-off-by: Lorenzo Pieralisi &lt;lorenzo.pieralisi@arm.com&gt;
Tested-by: Alan Mikhak &lt;alan.mikhak@sifive.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
