whether or not CX5 need dpdk-devbind.py to bind nic businfo - mellon

dpdk 18.11 , when use mlx5 nic, use dpdk-devbind.py -b igb_uio 0000:xx:00.0 ,it show mlx5_pci_probe(): no Verbs device matches PCI device 0000:xx:00.0, are kernel drivers loaded?
whether or not use dpdk-devbind.py -b igb_uio 0000:xx:00.0

MLX5 PMD does not require dpdk-devbind.py -b igb_uio it works independent to igb_uio,uio_pci_generic on both Linux and Windows.
Please re-test without binding
lspci -ks 0000:41:00.1
41:00.1 Ethernet controller: Mellanox Technologies MT2892 Family [ConnectX-6 Dx]
Subsystem: Mellanox Technologies MT2892 Family [ConnectX-6 Dx]
Kernel driver in use: mlx5_core
From DPDK documentation refer & also refer for DPDK 16.04
This capability allows the PMD to coexist with kernel network interfaces which remain functional, although they stop receiving unicast packets as long as they share the same MAC address. This means legacy linux control tools (for example: ethtool, ifconfig and more) can operate on the same network interfaces that owned by the DPDK application.

Related

Multiple VMs Accessing a single device over PCIE

I am using the libvirt/QEMU/KVM stack to run some VMs on an Ubuntu 20.04 host. I am using the virsh CLI tool for VM management. I'd like to allow multiple VMs to access the same device (FPGA) over PCIE. It seems that libvirt doesn't allow this, and when I attach the PCIE device to multiple VMs and try to power more than one on, I get the following error.
error: Failed to start domain ubuntu-guest-2
error: Requested operation is not valid: PCI device 0000:05:00.0 is in use by driver QEMU, domain ubuntu-guest-1
This kinda makes sense to me, as there shouldn't be conflicting data sent over the PCIE bus. But nonetheless, does anyone know a workaround to make this happen?
There are a number of techniques to share a device across VMs. All of them require either device-specific software support in the VMM, hardware in the device to support sharing (SR-IOV), or both (Scalable IOV).
For a custom FPGA design, you would need to provide this.
SR-IOV is part of the PCIe specification, so there may be libraries available that you could incorporate into your FPGA design.

How to access virtual machines started with QEMU?

I wish I could connect to virtual machines started with QEMU.
Then I should extract the information about the registers (EIP, EBP, etc.)
In XEN for this, there is the function get_vcpu_context, also there are other functions through which you can connect to each virtual machine separately.
Is there any such support for QEMU, and where can I find QEMU hypercalls documentation?
You have a couple of options:
you can connect to the QEMU gdbstub and use the GDB remote protocol to query CPU state. This is probably the most reliable method.
you can connect to the QEMU monitor and use the "info registers" command. Note that the output format of this might change between QEMU releases, though (it is intended for human consumption, not other programs), so it will be less reliable long-term than using GDB remote protocol.

How to reverse-engineer a USB device without monitoring traffic?

How is it possible to determine the commands to operate a usb device, if that device comes from another operating system and traffic monitoring software cannot be installed on that OS. The only method i can think of is sending random commands to the device, until the device responds, but this seems implausible for more complex commands, and potentially dangerous. For example, consider the DualShock 4 controller. Sony has not made an official driver for this device, so what method can i use to create a linux driver for it?
Get a hardware protocol analyzer. Then you won't need to install any software on the host or device under test. Here is one that I have used:
http://www.totalphase.com/products/beagle-usb12/

DPDK Open vSwitch can't access the network

I'm playing with ovs-dpdk package https://github.com/01org/dpdk-ovs and one thing I don't clearly understand is how can I have OVS bridge and VMs connected to it get access to outside, ie. to the network. On a regular openvswitch the bridge device created by vswitch is 'visible' from linux and can be configured by regular tools (ifconfig, ethtool etc.), so I could create TAP interface and add it to vswitch bridge interface and assign the bridge interface IP address. However with ovs-dpdk this is not the case: any bridge created with ovs-vsctl is not avaialble in userspace linux, at least I don't see it with ifconfig or "ip link show".
Is there another method OVS-DPDK does this? Hopefully someone can shed some light for this problem. Thanks.
ovs-dpdk when it is using DPDK to access the NIC will take over the nic and not allow regular kernel drivers to do their thing.
This means that you will not see the interface any more from the linux host if you bind the hardware with the dpdk io driver. But you can bridge/tap/mirror inside ovs these raw dpdk interfaces in dpdk-ovs to your vm's or to another interface which is visible to the kernel's regular drivers. You just can't do it on the dpdk owned interfaces.
The whole point of integrating dpdk into ovs is to bypass all the kernel drivers and get packets to/from the vswitch as fast as possible so it can route them natively through to your VM's and other local interfaces as you set in your bridge configuration.

Configuring SSH over USB on ARM AM335x running angstrom linux 3.2.0

I have a AM335X ARM processor on a custom board. I am running angstrom linux 3.2.0 on it.
My build environment is a 64 bit laptop running Ubuntu 12.0.4.
I was hoping (I am a newbie), someone could explain what I need to do to configure the board (and host desktop) to run SSH over USB.
Any help would be greatly appreciated
It depends whether you have OTG port or not. If yes, you should configure it to emulate a network device. Connect your board to your laptop and you should see a new networking device (usb0 or something like this). Configure IP addresses for both host usb0 and one on your board and you're done having an extra IP subnet, where you can ping, SSH etc.