All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [SPDK] why spdk need to unload all ioat devices?
@ 2017-11-29  8:56 Wodkowski, PawelX
  0 siblings, 0 replies; 2+ messages in thread
From: Wodkowski, PawelX @ 2017-11-29  8:56 UTC (permalink / raw)
  To: spdk

[-- Attachment #1: Type: text/plain, Size: 3336 bytes --]

Setup.sh is just a helper script to easily start using SPDK, it is not mandatory to use it. The ioat devices are unloaded by default in setup.sh because SPDK can get use of them but I think is no critical for SPDK to have ioat devices.
If you need them for your app just comment out some lines in spdk.sh (see diff at the end of message). This would be enough to not touch those devices. Of course  you can always bind IOAT to UIO or VFIO by yourself (ex give only one or two if you don't need all of IOAT devices in your app).

Try this:

diff --git a/scripts/setup.sh b/scripts/setup.sh
index bd644ec..3d7ff7d 100755
--- a/scripts/setup.sh
+++ b/scripts/setup.sh
@@ -103,17 +103,17 @@

                # IOAT
-              TMP=`mktemp`
-              #collect all the device_id info of ioat devices.
-              grep "PCI_DEVICE_ID_INTEL_IOAT" $rootdir/include/spdk/pci_ids.h \
-              | awk -F"x" '{print $2}' > $TMP
-
-              for dev_id in `cat $TMP`; do
-                              for bdf in $(linux_iter_pci_dev_id 8086 $dev_id); do
-                                             linux_bind_driver "$bdf" "$driver_name"
-                              done
-              done
-              rm $TMP
+#          TMP=`mktemp`
+#          #collect all the device_id info of ioat devices.
+#          grep "PCI_DEVICE_ID_INTEL_IOAT" $rootdir/include/spdk/pci_ids.h \
+#          | awk -F"x" '{print $2}' > $TMP
+#
+#          for dev_id in `cat $TMP`; do
+#                          for bdf in $(linux_iter_pci_dev_id 8086 $dev_id); do
+#                                          linux_bind_driver "$bdf" "$driver_name"
+#                          done
+#          done
+#          rm $TMP
                # virtio-scsi
               TMP=`mktemp`
--

From: SPDK [mailto:spdk-bounces(a)lists.01.org] On Behalf Of huangqingxin(a)ruijie.com.cn
Sent: Wednesday, November 29, 2017 9:16 AM
To: spdk(a)lists.01.org
Subject: [SPDK] why spdk need to unload all ioat devices?


hi,

when i run setup.sh, I found some output from dmesg
```sh
[root(a)localhost scripts]# ./setup.sh
0000:00:04.0 (8086 2f20): ioatdma -> uio_pci_generic
0000:00:04.1 (8086 2f21): ioatdma -> uio_pci_generic
0000:00:04.2 (8086 2f22): ioatdma -> uio_pci_generic
0000:00:04.3 (8086 2f23): ioatdma -> uio_pci_generic
0000:00:04.4 (8086 2f24): ioatdma -> uio_pci_generic
0000:00:04.5 (8086 2f25): ioatdma -> uio_pci_generic
0000:00:04.6 (8086 2f26): ioatdma -> uio_pci_generic
0000:00:04.7 (8086 2f27): ioatdma -> uio_pci_generic
[root(a)localhost scripts]# dmesg | grep ioat
[   59.031281] ioatdma: Intel(R) QuickData Technology Driver 4.00
[  347.890436] ioatdma 0000:00:04.0: Removing dma and dca services
[  347.907950] ioatdma 0000:00:04.1: Removing dma and dca services
[  347.924960] ioatdma 0000:00:04.2: Removing dma and dca services
[  347.941547] ioatdma 0000:00:04.3: Removing dma and dca services
[  347.957906] ioatdma 0000:00:04.4: Removing dma and dca services
[  347.974823] ioatdma 0000:00:04.5: Removing dma and dca services
[  347.990314] ioatdma 0000:00:04.6: Removing dma and dca services
[  348.006346] ioatdma 0000:00:04.7: Removing dma and dca services
```

I wonder why need to do these unload operations? What can I do if other APP needs DMA channel?

[-- Attachment #2: attachment.html --]
[-- Type: text/html, Size: 16121 bytes --]

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [SPDK] why spdk need to unload all ioat devices?
@ 2017-11-29  8:16 huangqingxin
  0 siblings, 0 replies; 2+ messages in thread
From: huangqingxin @ 2017-11-29  8:16 UTC (permalink / raw)
  To: spdk

[-- Attachment #1: Type: text/plain, Size: 1302 bytes --]


hi,

when i run setup.sh, I found some output from dmesg
```sh
[root(a)localhost scripts]# ./setup.sh
0000:00:04.0 (8086 2f20): ioatdma -> uio_pci_generic
0000:00:04.1 (8086 2f21): ioatdma -> uio_pci_generic
0000:00:04.2 (8086 2f22): ioatdma -> uio_pci_generic
0000:00:04.3 (8086 2f23): ioatdma -> uio_pci_generic
0000:00:04.4 (8086 2f24): ioatdma -> uio_pci_generic
0000:00:04.5 (8086 2f25): ioatdma -> uio_pci_generic
0000:00:04.6 (8086 2f26): ioatdma -> uio_pci_generic
0000:00:04.7 (8086 2f27): ioatdma -> uio_pci_generic
[root(a)localhost scripts]# dmesg | grep ioat
[   59.031281] ioatdma: Intel(R) QuickData Technology Driver 4.00
[  347.890436] ioatdma 0000:00:04.0: Removing dma and dca services
[  347.907950] ioatdma 0000:00:04.1: Removing dma and dca services
[  347.924960] ioatdma 0000:00:04.2: Removing dma and dca services
[  347.941547] ioatdma 0000:00:04.3: Removing dma and dca services
[  347.957906] ioatdma 0000:00:04.4: Removing dma and dca services
[  347.974823] ioatdma 0000:00:04.5: Removing dma and dca services
[  347.990314] ioatdma 0000:00:04.6: Removing dma and dca services
[  348.006346] ioatdma 0000:00:04.7: Removing dma and dca services
```

I wonder why need to do these unload operations? What can I do if other APP needs DMA channel?

[-- Attachment #2: attachment.html --]
[-- Type: text/html, Size: 2386 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-11-29  8:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-11-29  8:56 [SPDK] why spdk need to unload all ioat devices? Wodkowski, PawelX
  -- strict thread matches above, loose matches on Subject: below --
2017-11-29  8:16 huangqingxin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.