summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/cavium/liquidio/octeon_nic.c
diff options
context:
space:
mode:
authorPrasad Kanneganti <prasad.kanneganti@cavium.com>2017-01-04 20:31:55 +0100
committerDavid S. Miller <davem@davemloft.net>2017-01-06 21:31:24 +0100
commit90028b07a74ddcbaac1c5aee038a7108ae279b2e (patch)
treef8fac318a0fdc85795dd9bcc845bb0064a0e2c66 /drivers/net/ethernet/cavium/liquidio/octeon_nic.c
parenttools: psock_tpacket: block Rx until socket filter has been added and socket ... (diff)
downloadlinux-90028b07a74ddcbaac1c5aee038a7108ae279b2e.tar.xz
linux-90028b07a74ddcbaac1c5aee038a7108ae279b2e.zip
liquidio VF: fix incorrect struct being used
The VF driver is using the wrong struct when sending commands to the NIC firmware, sometimes causing adverse effects in the firmware. The right struct is the one that the PF is using, so make the VF use that as well. Signed-off-by: Prasad Kanneganti <prasad.kanneganti@cavium.com> Signed-off-by: Felix Manlunas <felix.manlunas@cavium.com> Signed-off-by: Derek Chickles <derek.chickles@cavium.com> Signed-off-by: Satanand Burla <satananda.burla@cavium.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/cavium/liquidio/octeon_nic.c')
-rw-r--r--drivers/net/ethernet/cavium/liquidio/octeon_nic.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/cavium/liquidio/octeon_nic.c b/drivers/net/ethernet/cavium/liquidio/octeon_nic.c
index c3d6a8228362..0243be8dd56f 100644
--- a/drivers/net/ethernet/cavium/liquidio/octeon_nic.c
+++ b/drivers/net/ethernet/cavium/liquidio/octeon_nic.c
@@ -49,7 +49,7 @@ octeon_alloc_soft_command_resp(struct octeon_device *oct,
/* Add in the response related fields. Opcode and Param are already
* there.
*/
- if (OCTEON_CN23XX_PF(oct)) {
+ if (OCTEON_CN23XX_PF(oct) || OCTEON_CN23XX_VF(oct)) {
ih3 = (struct octeon_instr_ih3 *)&sc->cmd.cmd3.ih3;
rdp = (struct octeon_instr_rdp *)&sc->cmd.cmd3.rdp;
irh = (struct octeon_instr_irh *)&sc->cmd.cmd3.irh;
@@ -70,7 +70,7 @@ octeon_alloc_soft_command_resp(struct octeon_device *oct,
*sc->status_word = COMPLETION_WORD_INIT;
- if (OCTEON_CN23XX_PF(oct))
+ if (OCTEON_CN23XX_PF(oct) || OCTEON_CN23XX_VF(oct))
sc->cmd.cmd3.rptr = sc->dmarptr;
else
sc->cmd.cmd2.rptr = sc->dmarptr;