Re: [PATCH net-next 2/2] ibmvnic: Update firmware error reporting with cause string

2018-08-06 Thread Nathan Fontenot
On 08/06/2018 09:39 PM, Thomas Falcon wrote: Print a string instead of the error code. Since there is a possibility that the driver can recover, classify it as a warning instead of an error. Signed-off-by: Thomas Falcon --- drivers/net/ethernet/ibm/ibmvnic.c | 34

[PATCH net] ibmvnic: Only do H_EOI for mobility events

2018-05-22 Thread Nathan Fontenot
when enabling during a mobility event though. Doing so at other time could wrong and can produce extra driver output when IRQs are enabled when doing TX completion. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 15 +-- 1 file c

[PATCH v2 net 1/2] ibmvnic: Handle all login error conditions

2018-04-11 Thread Nathan Fontenot
because the driver does a renegotiation of capabilities which sets the number of queues possible and allows the driver to attempt a login for possible value for the number of queues supported. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c

[PATCH v2 net 0/2] ibmvnic: Fix parameter change request handling

2018-04-11 Thread Nathan Fontenot
for a parameter change reset. This patch set corrects both of these issues by updating the return code handling in ibmvnic_login() nand gaurding against calling netdev_notify_peers() for parameter change requests. -Nathan Updates for V2: Correct spelling mistakes in commit messages. --- Nathan Fontenot (2

[PATCH v2 net 2/2] ibmvnic: Do not notify peers on parameter change resets

2018-04-11 Thread Nathan Fontenot
When attempting to change the driver parameters, such as the MTU value or number of queues, do not call netdev_notify_peers(). Doing so will deadlock on the rtnl_lock. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |3 ++- 1 file chan

Re: [PATCH net 1/2] ibmvnic: Handle all login error conditions

2018-04-11 Thread Nathan Fontenot
On 04/11/2018 10:07 AM, David Miller wrote: > From: Nathan Fontenot <nf...@linux.vnet.ibm.com> > Date: Wed, 11 Apr 2018 09:37:21 -0500 > >> There is a bug in handling the possible return codes from sending the >> login CRQ. The current code treats any non-success ret

[PATCH net 0/2] ibmvnic: Fix parameter change request handling

2018-04-11 Thread Nathan Fontenot
for a parameter change reset. This patch set corrects both of these issues by updating the return code handling in ibmvnic_login() nand gaurding against calling netdev_notify_peers() for parameter change requests. -Nathan --- Nathan Fontenot (2): ibmvnic: Handle all login error conditions

[PATCH net 2/2] ibmvnic: Do not notify peers on parameter change resets

2018-04-11 Thread Nathan Fontenot
When attempting to change the driver parameters, such as the MTU value or number of queues, do not call netdev_notify_peers(). Doing so will deadlock on the rtnl_lock. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |3 ++- 1 file chan

[PATCH net 1/2] ibmvnic: Handle all login error conditions

2018-04-11 Thread Nathan Fontenot
because the driver does a renegatiation of capabilities which sets the number of queus possible and allows the driver to attempt a login for possible value for the number of queues supported. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c

[PATCH net-next] ibmvnic: Split counters for scrq/pools/napi

2018-02-21 Thread Nathan Fontenot
. This patch simplifies this by having a counter for tx and rx sub-crqs, pools, and napi. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 38 drivers/net/ethernet/ibm/ibmvnic.h |7 +-- 2 files chang

[PATCH net-next ] ibmvnic: Correct goto target for tx irq initialization failure

2018-02-20 Thread Nathan Fontenot
When a failure occurs during initialization of the tx sub crq irqs, we should branch to the cleanup of the tx irqs. The current code branches to the rx irq cleanup and attempts to cleanup the rx irqs which have not been initialized. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.

[PATCH V3 net-next 5/5] ibmvnic: Allocate max queues stats buffers

2018-02-19 Thread Nathan Fontenot
To avoid losing any stats when the number of sub-crqs change, allocate the max number of stats buffers so a stats buffer exists all possible sub-crqs. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |4 ++-- 1 file changed, 2 insertions

Re: [PATCH V2 net-next 3/5] ibmvnic: Free and re-allocate scrqs when tx/rx scrqs change

2018-02-19 Thread Nathan Fontenot
On 02/19/2018 01:16 PM, David Miller wrote: > From: Nathan Fontenot <nf...@linux.vnet.ibm.com> > Date: Sun, 18 Feb 2018 19:34:47 -0600 > >> @@ -2241,24 +2241,27 @@ static int reset_sub_crq_queues(struct >> ibmvnic_adapter *adapter) >> } >> >&

[PATCH V3 net-next 2/5] ibmvnic: Move active sub-crq count settings

2018-02-19 Thread Nathan Fontenot
Inpreparation for using the active scrq count to track more active resources, move the setting of the active count to after initialization occurs in initial driver init and during driver reset. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibm

[PATCH V3 net-next 1/5] ibmvnic: Rename active queue count variables

2018-02-19 Thread Nathan Fontenot
Rename the tx/rx active pool variables to be tx/rx active scrq counts. The tx/rx pools are per sub-crq so this is a more appropriate name. This also is a preparatory step for using thiese variables for handling updates to sub-crqs and napi based on the active count. Signed-off-by: Nathan Fontenot

[PATCH V3 net-next 3/5] ibmvnic: Free and re-allocate scrqs when tx/rx scrqs change

2018-02-19 Thread Nathan Fontenot
of main crq results in all of the sub crq's being free'ed. When updating sub-crq count in the reset path we do not want to h_free the sub-crqs, they are already free'ed. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- Updates for V3: Change do_h_free parameter to bool Updates

[PATCH V3 net-next 4/5] ibmvnic: Make napi usage dynamic

2018-02-19 Thread Nathan Fontenot
In order to handle the number of rx sub crqs changing during a driver reset, the ibmvnic driver also needs to update the number of napi. To do this the code to init and free napi's is moved to their own routines so they can be called during the reset process. Signed-off-by: Nathan Fontenot <

[PATCH V3 net-next 0/5] ibmvnic: Make driver resources dynamic

2018-02-19 Thread Nathan Fontenot
parameter a bool Updates for V2: Patch 3/5 - Use correct queue count when driver is in probed state for releasing sub crqs. Nathan Fontenot (5): ibmvnic: Rename active queue count variables ibmvnic: Move active sub-crq count settings ibmvnic: Free and re-allocate scrqs when tx/rx

Re: [PATCH net-next3/5] ibmvnic: Free and re-allocate scrqs when tx/rx scrqs change

2018-02-18 Thread Nathan Fontenot
On 02/17/2018 05:32 PM, Nathan Fontenot wrote: > When the driver resets it is possible that the number of tx/rx > sub-crqs can change. This patch handles this so that the driver does > not try to access non-existent sub-crqs. > > Additionally, a parameter is added to releas

[PATCH V2 net-next 5/5] ibmvnic: Allocate max queues stats buffers

2018-02-18 Thread Nathan Fontenot
To avoid losing any stats when the number of sub-crqs change, allocate the max number of stats buffers so a stats buffer exists all possible sub-crqs. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |4 ++-- 1 file changed, 2 insertions

[PATCH V2 net-next 4/5] ibmvnic: Make napi usage dynamic

2018-02-18 Thread Nathan Fontenot
In order to handle the number of rx sub crqs changing during a driver reset, the ibmvnic driver also needs to update the number of napi. To do this the code to init and free napi's is moved to their own routines so they can be called during the reset process. Signed-off-by: Nathan Fontenot <

[PATCH V2 net-next 3/5] ibmvnic: Free and re-allocate scrqs when tx/rx scrqs change

2018-02-18 Thread Nathan Fontenot
of main crq results in all of the sub crq's being free'ed. When updating sub-crq count in the reset path we do not want to h_free the sub-crqs, they are already free'ed. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- Updates for V2: Use the correct scrq count for releasing

[PATCH V2 net-next 2/5] ibmvnic: Move active sub-crq count settings

2018-02-18 Thread Nathan Fontenot
In preparation for using the active scrq count to track more active resources, move the setting of the active count to after initialization occurs in initial driver init and during driver reset. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibm

[PATCH V2 net-next 1/5] ibmvnic: Rename active queue count variables

2018-02-18 Thread Nathan Fontenot
Rename the tx/rx active pool variables to be tx/rx active scrq counts. The tx/rx pools are per sub-crq so this is a more appropriate name. This also is a preparatory step for using thiese variables for handling updates to sub-crqs and napi based on the active count. Signed-off-by: Nathan Fontenot

[PATCH V2 net-next 0/5] ibmvnic: Make driver resources dynamic

2018-02-18 Thread Nathan Fontenot
count when driver is in probed state for releasing sub crqs. Nathan Fontenot (5): ibmvnic: Rename active queue count variables ibmvnic: Move active sub-crq count settings ibmvnic: Free and re-allocate scrqs when tx/rx scrqs change ibmvnic: Make napi usage dynamic

[PATCH net-next4/5] ibmvnic: Make napi usage dynamic

2018-02-17 Thread Nathan Fontenot
In order to handle the number of rx sub crqs changing during a driver reset, the ibmvnic driver also needs to update the number of napi. To do this the code to init and free napi's is moved to their own routines so they can be called during the reset process. Signed-off-by: Nathan Fontenot <

[PATCH net-next3/5] ibmvnic: Free and re-allocate scrqs when tx/rx scrqs change

2018-02-17 Thread Nathan Fontenot
-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 69 ++-- 1 file changed, 43 insertions(+), 26 deletions(-) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c index 9cfbb2

[PATCH net-next5/5] ibmvnic: Allocate max queues stats buffers

2018-02-17 Thread Nathan Fontenot
To avoid losing any stats when the number of sub-crqs change, allocate the max number of stats buffers so a stats buffer exists all possible sub-crqs. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |4 ++-- 1 file changed, 2 insertions

[PATCH net-next2/5] ibmvnic: Move active sub-crq count settings

2018-02-17 Thread Nathan Fontenot
Inpreparation for using the active scrq count to track more active resources, move the setting of the active count to after initialization occurs in initial driver init and during driver reset. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibm

[PATCH net-next1/5] ibmvnic: Rename active queue count variables

2018-02-17 Thread Nathan Fontenot
Rename the tx/rx active pool variables to be tx/rx active scrq counts. The tx/rx pools are per sub-crq so this is a more appropriate name. This also is a preparatory step for using thiese variables for handling updates to sub-crqs and napi based on the active count. Signed-off-by: Nathan Fontenot

[PATCH net-next 0/5] ibmvnic: Make driver resources dynamic

2018-02-17 Thread Nathan Fontenot
. With this change we can now release and init the sub crqs and napi (for rx sub crqs) when the number of sub crqs change. Lastly, the stats buffer allocation is updated to always allocate the maximum number of sub-crqs count of stats buffers. -Nathan --- Nathan Fontenot (5): ibmvnic: Rename

[PATCH net-next V2] ibmvnic: Remove skb->protocol checks in ibmvnic_xmit

2018-02-09 Thread Nathan Fontenot
From: John Allen <jal...@linux.vnet.ibm.com> Having these checks in ibmvnic_xmit causes problems with VLAN tagging and balance-alb/tlb bonding modes. The restriction they imposed can be removed. Signed-off-by: John Allen <jal...@linux.vnet.ibm.com> Signed-off-by: Nathan

Re: [PATCH] ibmvnic: Remove skb->protocol checks in ibmvnic_xmit

2018-02-09 Thread Nathan Fontenot
On 02/09/2018 01:32 PM, Jakub Kicinski wrote: > On Fri, 09 Feb 2018 13:09:34 -0600, Nathan Fontenot wrote: >> From: John Allen (jal...@linux.vnet.ibm.com> > > Nit: s/(/ >> Having these checks in ibmvnic_xmit causes problems with VLAN >> tagging and balance-alb/tlb

[PATCH] ibmvnic: Remove skb->protocol checks in ibmvnic_xmit

2018-02-09 Thread Nathan Fontenot
From: John Allen (jal...@linux.vnet.ibm.com> Having these checks in ibmvnic_xmit causes problems with VLAN tagging and balance-alb/tlb bonding modes. The restriction they imposed can be removed. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/

[PATCH net-next] ibmvnic: queue reset when CRQ gets closed during reset

2018-02-07 Thread Nathan Fontenot
the driver. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c index 5caaa9033841..0f7e1d016207

Re: [PATCH net v2 3/3] ibmvnic: Allocate and request vpd in init_resources

2018-01-19 Thread Nathan Fontenot
patch moves the allocation of the VPD data to init_resources > so that it will be symmetrically freed during release resources. > > Signed-off-by: John Allen <jal...@linux.vnet.ibm.com> Reviewed-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> > --- > diff --git a/drivers/net/

Re: [PATCH net v2 2/3] ibmvnic: Revert to previous mtu when unsupported value requested

2018-01-19 Thread Nathan Fontenot
ned-off-by: John Allen <jal...@linux.vnet.ibm.com> Reviewed-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> > --- > diff --git a/drivers/net/ethernet/ibm/ibmvnic.c > b/drivers/net/ethernet/ibm/ibmvnic.c > index f8f1396..bb56460 100644 > --- a/drivers/net/ethernet/ibm/ibmvnic.c &

Re: [PATCH net v2 1/3] ibmvnic: Modify buffer size and number of queues on failover

2018-01-19 Thread Nathan Fontenot
so perform the necessary re-allocations. > > Signed-off-by: John Allen <jal...@linux.vnet.ibm.com> Reviewed-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> > --- > v2: Added the line to free the long term buff in reset rx pools which > caused me to hit a couple of other problems.

[PATCH net-next v2] ibmvnic: Don't handle RX interrupts when not up.

2018-01-10 Thread Nathan Fontenot
] [c8009204] system_call+0x38/0xb4 At this point the driver is not prepared to handle traffic and should not try to handle the interrupt. This patch adds a check to ensure the driver is up when handling RX interrupts. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- v2 u

Re: [PATCH net-next] ibmvnic: Don't handle RX interrupts when not up.

2018-01-10 Thread Nathan Fontenot
On 01/09/2018 02:33 PM, Thomas Falcon wrote: > On 01/08/2018 10:09 AM, Nathan Fontenot wrote: >> Initiating a kdump via the command line can cause a pending interrupt >> to be handled by the ibmvnic driver when initializing the sub-CRQ >> irqs during driver init

[PATCH net-next] ibmvnic: Don't handle RX interrupts when not up.

2018-01-08 Thread Nathan Fontenot
] [c8009204] system_call+0x38/0xb4 At this poibnt the driver is not prepared to handle traffic and should not try to handle the interrupt. This patch adds a check to ensure the driver is up when handling RX interrupots. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drive

Re: [PATCH] [net-next,v3] ibmvnic: Feature implementation of Vital Product Data (VPD) for the ibmvnic driver

2017-11-13 Thread Nathan Fontenot
On 11/10/2017 01:13 PM, Desnes Augusto Nunes do Rosário wrote: > > > On 11/10/2017 12:54 PM, Nathan Fontenot wrote: >> On 11/10/2017 08:41 AM, Desnes Augusto Nunes do Rosário wrote: >>> >>> >>> On 11/09/2017 06:31 PM, Nathan Fontenot wrote: >>&g

Re: [PATCH] [net-next,v3] ibmvnic: Feature implementation of Vital Product Data (VPD) for the ibmvnic driver

2017-11-10 Thread Nathan Fontenot
On 11/10/2017 08:41 AM, Desnes Augusto Nunes do Rosário wrote: > > > On 11/09/2017 06:31 PM, Nathan Fontenot wrote: >> On 11/09/2017 01:00 PM, Desnes Augusto Nunes do Rosario wrote: >>> This patch implements and enables VDP support for the ibmvnic driver. &

Re: [PATCH] [net-next,v3] ibmvnic: Feature implementation of Vital Product Data (VPD) for the ibmvnic driver

2017-11-09 Thread Nathan Fontenot
On 11/09/2017 01:00 PM, Desnes Augusto Nunes do Rosario wrote: > This patch implements and enables VDP support for the ibmvnic driver. > Moreover, it includes the implementation of suitable structs, signal > transmission/handling and functions which allows the retrival of firmware > information

[PATCH net-next] ibmvnic: Add vnic client data to login buffer

2017-11-08 Thread Nathan Fontenot
Update the login buffer to include client data for the vnic driver, this includes the OS name, LPAR name, and device name. This update alolows thius information to be available in the VIOS. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c

Re: [PATCH v2 net-next 1/2] ibmvnic: Update reset infrastructure to support tunable parameters

2017-10-24 Thread Nathan Fontenot
On 10/23/2017 11:33 AM, John Allen wrote: > Update ibmvnic reset infrastructure to include a new reset option that will > allow changing of tunable parameters. There currently is no way to request > different capabilities from the vnic server on the fly so this patch > achieves this by resetting

Re: [PATCH net-next] ibmvnic: Add netdev_dbg output for debugging

2017-08-08 Thread Nathan Fontenot
On 08/08/2017 11:27 AM, Stephen Hemminger wrote: > On Mon, 07 Aug 2017 15:02:58 -0400 > Nathan Fontenot <nf...@linux.vnet.ibm.com> wrote: > >> To ease debugging of the ibmvnic driver add a series of netdev_dbg() >> statements to track driver status, especially during

[PATCH net-next] ibmvnic: Correct 'unused variable' warning in build.

2017-08-08 Thread Nathan Fontenot
Commit a248878d7a1d ("ibmvnic: Check for transport event on driver resume") removed the loop to kick irqs on driver resume but didn't remove the now unused loop variable 'i'. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |1 -

[PATCH v3 net-next] ibmvnic: Add netdev_dbg output for debugging

2017-08-08 Thread Nathan Fontenot
To ease debugging of the ibmvnic driver add a series of netdev_dbg() statements to track driver status, especially during initialization, removal, and resetting of the driver. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- v2: Removed several dbg statements where ftrace

[PATCH v2 net-next] ibmvnic: Add netdev_dbg output for debugging

2017-08-08 Thread Nathan Fontenot
To ease debugging of the ibmvnic driver add a series of netdev_dbg() statements to track driver status, especially during initialization, removal, and resetting of the driver. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- v2: Removed several dbg statements where ftrace

[PATCH net-next] ibmvnic: Clean up resources on probe failure

2017-08-08 Thread Nathan Fontenot
Ensure that any resources allocated during probe are released if the probe of the driver fails. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 26 +++--- 1 file changed, 15 insertions(+), 11 deletions(-) diff

Re: [PATCH net-next] ibmvnic: Add netdev_dbg output for debugging

2017-08-08 Thread Nathan Fontenot
On 08/07/2017 10:29 AM, Joe Perches wrote: > On Mon, 2017-08-07 at 15:02 -0400, Nathan Fontenot wrote: >> To ease debugging of the ibmvnic driver add a series of netdev_dbg() >> statements to track driver status, especially during initialization, >> removal, and re

[PATCH net-next] ibmvnic: Add netdev_dbg output for debugging

2017-08-07 Thread Nathan Fontenot
To ease debugging of the ibmvnic driver add a series of netdev_dbg() statements to track driver status, especially during initialization, removal, and resetting of the driver. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c

[PATCH net-next V2] ibmvnic: Correct return code checking for ibmvnic_init during probe

2017-06-21 Thread Nathan Fontenot
this fix, the vNIC driver can return 0 (success) from its probe routine due to ibmvnic_init returning zero, but before completing the probe process and registering with the netdev layer. Fixes: 6a2fb0e99f9c (ibmvnic: driver initialization for kdump/kexec) Signed-off-by: Nathan Fontenot <

Re: [PATCH net-next] ibmvnic: Correct return code checking for ibmvnic_init during probe

2017-06-21 Thread Nathan Fontenot
On 06/21/2017 02:39 PM, David Miller wrote: > From: Nathan Fontenot <nf...@linux.vnet.ibm.com> > Date: Tue, 20 Jun 2017 17:21:54 -0400 > >> Fixes: 6a2fb0e99f9c (ibmvnic: driver initialization for kdump/kexec) > > I'm incredibly curious where you got the

Re: [PATCH net-next] ibmvnic: Return from ibmvnic_resume if not in VNIC_OPEN state

2017-06-20 Thread Nathan Fontenot
; > Signed-off-by: John Allen <jal...@linux.vnet.ibm.com> Reviewed-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> > --- > diff --git a/drivers/net/ethernet/ibm/ibmvnic.c > b/drivers/net/ethernet/ibm/ibmvnic.c > index 722daf5..0135095 100644 > --- a/drivers/net/ethernet/i

[PATCH net-next] ibmvnic: Correct return code checking for ibmvnic_init during probe

2017-06-20 Thread Nathan Fontenot
should be to see if rc is non-zero and not equal to EAGAIN. Without this fix, the vNIC driver can return 0 (success) from its probe routine due to ibmvnic_init returning zero, but before completing the probe process and registering with the netdev layer. Signed-off-by: Nathan Fontenot <

[PATCH] ibmvnic: driver initialization for kdump/kexec

2017-06-15 Thread Nathan Fontenot
of the driver as is normally done for a failover transport event. To correct this we catch driver resets while still in the 'probing' state and return EAGAIN. This results in the driver tearing down the main crq and calling ibmvnic_init() again. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.

[PATCH net-next] ibmvnic: Remove netdev notify for failover resets

2017-06-12 Thread Nathan Fontenot
When handling a driver reset due to a failover of the backing server on the vios, doing the netdev_notify_peers() can cause network traffic to stall or halt. Remove the netdev notify call for failover resets. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethern

Re: [PATCH net-next] ibmvnic: Client-initiated failover

2017-06-12 Thread Nathan Fontenot
acking device, > if one is available." > > To provide tools access to this functionality the vNIC driver creates a > sysfs file that, when written to, will send a request to pHyp to failover > to a different backing device. > > Signed-off-by: Thomas Falcon <tlfal...@li

[PATCH net-next 08/11] ibmvnic: Check adapter state during ibmvnic_poll

2017-05-26 Thread Nathan Fontenot
We do not want to process any receive frames if the ibmvnic_poll routine is invoked while a reset is in process. Also, before replenishing the rx pools in the ibmvnic_poll, we want to make sure the adapter is not in the process of closing. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.

[PATCH net-next 11/11] ibmvnic: Reset sub-crqs during driver reset

2017-05-26 Thread Nathan Fontenot
When the ibmvnic driver is resetting, we can just reset the sub crqs instead of releasing all of their resources and re-allocting them. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 46 ++-- 1 file chang

[PATCH net-next 09/11] ibmvnic: Reset the CRQ queue during driver reset

2017-05-26 Thread Nathan Fontenot
When a driver reset operation occurs there is not a need to release the CRQ resources and re-allocate them. Instead a reset of the CRQ will suffice. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 10 -- 1 file changed, 8 inse

[PATCH net-next 10/11] ibmvnic: Reset tx/rx pools on driver reset

2017-05-26 Thread Nathan Fontenot
When resetting the ibmvnic driver there is not a need to release and re-allocate the resources for the tx and rx pools. These resources can just be reset to avoid the re-allocations. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c

[PATCH net-next 07/11] ibmvnic: Deactivate RX pool buffer replenishment on H_CLOSED

2017-05-26 Thread Nathan Fontenot
From: Thomas Falcon If H_CLOSED is returned, halt RX buffer replenishment activity until firmware sends a notification that the driver can reset. Signed-off-by: Thomas Falcon --- drivers/net/ethernet/ibm/ibmvnic.c | 21

[PATCH net-next 06/11] ibmvnic: Halt TX and report carrier off on H_CLOSED return code

2017-05-26 Thread Nathan Fontenot
From: Thomas Falcon This patch disables transmissions and reports carrier off if xmit function returns that the hardware TX queue is closed. The driver can then await a signal from firmware to determine the correct reset method. Signed-off-by: Thomas Falcon

[PATCH net-next 05/11] ibmvnic: Non-fatal error handling

2017-05-26 Thread Nathan Fontenot
From: John Allen Handle non-fatal error conditions. The process to do this when resetting the driver is to just do __ibmvnic_close followed by __ibmvnic_open. Signed-off-by: John Allen --- drivers/net/ethernet/ibm/ibmvnic.c | 56

[PATCH net-next 04/11] ibmvnic: Fix cleanup of SKB's on driver close

2017-05-26 Thread Nathan Fontenot
From: Thomas Falcon A race condition occurs when closing the driver. Free'ing of skb's can race between the close routine and ibmvnic_tx_interrupt. To fix this we move the claenup of tx pools during close to after the sub-CRQ interrupts are disabled. Signed-off-by:

[PATCH net-next 03/11] ibmvnic: Send gratuitous arp on reset

2017-05-26 Thread Nathan Fontenot
From: John Allen Send gratuitous arp after any reset. Signed-off-by: John Allen --- drivers/net/ethernet/ibm/ibmvnic.c |1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c

[PATCH net-next 02/11] ibmvnic: Handle failover after failed init crq

2017-05-26 Thread Nathan Fontenot
From: John Allen Handle case where phyp sends a failover after failing to send the init crq. Signed-off-by: John Allen --- drivers/net/ethernet/ibm/ibmvnic.c | 11 ++- drivers/net/ethernet/ibm/ibmvnic.h |2 +- 2 files

[PATCH net-next 01/11] ibmvnic: Track state of adapter napis

2017-05-26 Thread Nathan Fontenot
; Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 37 +++- drivers/net/ethernet/ibm/ibmvnic.h |1 + 2 files changed, 29 insertions(+), 9 deletions(-) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/dr

[PATCH net-next 00/11] ibmvnic: Driver updates

2017-05-26 Thread Nathan Fontenot
: Handle failover after failed init crq ibmvnic: Send gratuitous arp on reset ibmvnic: Non-fatal error handling Nathan Fontenot (4): ibmvnic: Check adapter state during ibmvnic_poll ibmvnic: Reset the CRQ queue during driver reset ibmvnic: Reset tx/rx pools on driver

Re: [PATCH net-next] ibmvnic: fix missing unlock on error in __ibmvnic_reset()

2017-05-18 Thread Nathan Fontenot
Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> Reviewed-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> > --- > drivers/net/ethernet/ibm/ibmvnic.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/net/ethernet/ibm/ibmvnic.c > b/drivers/net/etherne

[PATCH v4 net-next 11/11] ibmvnic: Move queue restarting in ibmvnic_tx_complete

2017-05-03 Thread Nathan Fontenot
Restart of the subqueue should occur outside of the loop processing any tx buffers instead of doing this in the middle of the loop. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- v2: Use __netif_subqueue_stopped() instead of netif_subqueue_stopped() to avoid possible us

[PATCH v4 net-next 07/11] ibmvnic: Wait for any pending scrqs entries at driver close

2017-05-03 Thread Nathan Fontenot
When closing the ibmvnic driver we need to wait for any pending sub crq entries to ensure they are handled. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 47 +--- 1 file changed, 27 insertions(+), 20 del

[PATCH v4 net-next 10/11] ibmvnic: Record SKB RX queue during poll

2017-05-03 Thread Nathan Fontenot
From: Thomas Falcon Map each RX SKB to the RX queue associated with the driver's RX SCRQ. This should improve the RX CPU load balancing issues seen by the performance team. Signed-off-by: Thomas Falcon ---

[PATCH v4 net-next 06/11] ibmvnic: Clean up tx pools when closing

2017-05-03 Thread Nathan Fontenot
skbs in the tx pool that were never free'ed. As a result the upper network layers never tried a re-send since it believed the driver still had the skb. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 30 ++

[PATCH v4 net-next 09/11] ibmvnic: Continue skb processing after skb completion error

2017-05-03 Thread Nathan Fontenot
There is not a need to stop processing skbs if we encounter a skb that has a receive completion error. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethern

[PATCH v4 net-next 03/11] ibmvnic: Updated reset handling

2017-05-03 Thread Nathan Fontenot
to handle the reset out of interrupt context. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 413 +++- drivers/net/ethernet/ibm/ibmvnic.h | 19 +- 2 files changed, 275 insertions(+), 157 deletions(-) diff

[PATCH v4 net-next 01/11] ibmvnic: Move resource initialization to its own routine

2017-05-03 Thread Nathan Fontenot
Move all of the calls to initialize resources for the driver to a separate routine. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 71 1 file changed, 39 insertions(+), 32 deletions(-) diff

[PATCH v4 net-next 00/11] ibmvnic: Updated reset handler and code fixes

2017-05-03 Thread Nathan Fontenot
__netif_subqueue_stopped() instead of netif_subqueue_stopped() to avoid possible use of an un-initialized skb variable. --- Nathan Fontenot (10): ibmvnic: Move resource initialization to its own routine ibmvnic: Replace is_closed with state field ibmvnic: Updated reset handling

[PATCH v4 net-next 02/11] ibmvnic: Replace is_closed with state field

2017-05-03 Thread Nathan Fontenot
Replace the is_closed flag in the ibmvnic adapter strcut with a more comprehensive state field that tracks the current state of the driver. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 20 +--- drivers/net/ethern

[PATCH v4 net-next 05/11] ibmvnic: Whitespace correction in release_rx_pools

2017-05-03 Thread Nathan Fontenot
Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c index d52d98c..bbbd57e 100644 --- a/drivers/net/et

[PATCH v4 net-next 08/11] ibmvnic: Check for driver reset first in ibmvnic_xmit

2017-05-03 Thread Nathan Fontenot
Move the check for the driver resetting to the first thing in ibmvnic_xmit(). Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/net/ethernet/ibm/ibmvni

[PATCH v4 net-next 04/11] ibmvnic: Delete napi's when releasing driver resources

2017-05-03 Thread Nathan Fontenot
The napi structs allocated at drivier initializatio need to be free'ed when releasing the drivers resources. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |9 + 1 file changed, 9 insertions(+) diff --git a/drivers/net/ethern

[PATCH v3 net-next 09/11] ibmvnic: Continue skb processing after skb completion error

2017-05-02 Thread Nathan Fontenot
There is not a need to stop processing skbs if we encounter a skb that has a receive completion error. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethern

[PATCH v3 net-next 11/11] ibmvnic: Move queue restarting in ibmvnic_tx_complete

2017-05-02 Thread Nathan Fontenot
Restart of the subqueue should occur outside of the loop processing any tx buffers instead of doing this in the middle of the loop. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- v2: Use __netif_subqueue_stopped() instead of netif_subqueue_stopped() to avoid possible us

[PATCH v3 net-next 05/11] ibmvnic: Whitespace correction in release_rx_pools

2017-05-02 Thread Nathan Fontenot
Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c index 9f2686d..d20d884 100644 --- a/drivers/net/et

[PATCH v3 net-next 10/11] ibmvnic: Record SKB RX queue during poll

2017-05-02 Thread Nathan Fontenot
From: Thomas Falcon Map each RX SKB to the RX queue associated with the driver's RX SCRQ. This should improve the RX CPU load balancing issues seen by the performance team. Signed-off-by: Thomas Falcon ---

[PATCH v3 net-next 06/11] ibmvnic: Clean up tx pools when closing

2017-05-02 Thread Nathan Fontenot
skbs in the tx pool that were never free'ed. As a result the upper network layers never tried a re-send since it believed the driver still had the skb. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 30 ++

[PATCH v3 net-next 08/11] ibmvnic: Check for driver reset first in ibmvnic_xmit

2017-05-02 Thread Nathan Fontenot
Move the check for the driver resetting to the first thing in ibmvnic_xmit(). Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/net/ethernet/ibm/ibmvni

[PATCH v3 net-next 07/11] ibmvnic: Wait for any pending scrqs entries at driver close

2017-05-02 Thread Nathan Fontenot
When closing the ibmvnic driver we need to wait for any pending sub crq entries to ensure they are handled. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 47 +--- 1 file changed, 27 insertions(+), 20 del

[PATCH v3 net-next 01/11] ibmvnic: Move resource initialization to its own routine

2017-05-02 Thread Nathan Fontenot
Move all of the calls to initialize resources for the driver to a separate routine. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 71 1 file changed, 39 insertions(+), 32 deletions(-) diff

[PATCH v3 net-next 03/11] ibmvnic: Updated reset handling

2017-05-02 Thread Nathan Fontenot
to handle the reset out of interrupt context. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 413 +++- drivers/net/ethernet/ibm/ibmvnic.h | 19 +- 2 files changed, 275 insertions(+), 157 deletions(-) diff

[PATCH v3 net-next 04/11] ibmvnic: Delete napi's when releasing driver resources

2017-05-02 Thread Nathan Fontenot
The napi structs allocated at drivier initializatio need to be free'ed when releasing the drivers resources. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |9 + 1 file changed, 9 insertions(+) diff --git a/drivers/net/ethern

[PATCH v3 net-next 02/11] ibmvnic: Replace is_closed with state field

2017-05-02 Thread Nathan Fontenot
Replace the is_closed flag in the ibmvnic adapter strcut with a more comprehensive state field that tracks the current state of the driver. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 20 +--- drivers/net/ethern

[PATCH v3 net-next 00/11] ibmvnic: Updated reset handler and code fixes

2017-05-02 Thread Nathan Fontenot
skb variable. --- Nathan Fontenot (10): ibmvnic: Move resource initialization to its own routine ibmvnic: Replace is_closed with state field ibmvnic: Updated reset handling ibmvnic: Delete napi's when releasing driver resources ibmvnic: Whitespace correction

[PATCH v2 net-next 01/11] ibmvnic: Move resource initialization to its own routine

2017-05-01 Thread Nathan Fontenot
Move all of the calls to initialize resources for the driver to a separate routine. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 71 1 file changed, 39 insertions(+), 32 deletions(-) diff

[PATCH v2 net-next 08/11] ibmvnic: Check for driver reset first in ibmvnic_xmit

2017-05-01 Thread Nathan Fontenot
Move the check for the driver resetting to the first thing in ibmvnic_xmit(). Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/net/ethernet/ibm/ibmvni

[PATCH v2 net-next 09/11] ibmvnic: Continue skb processing after skb completion error

2017-05-01 Thread Nathan Fontenot
There is not a need to stop processing skbs if we encounter a skb that has a receive completion error. Signed-off-by: Nathan Fontenot <nf...@linux.vnet.ibm.com> --- drivers/net/ethernet/ibm/ibmvnic.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethern

  1   2   >