ibmvnic: Correct ibmvnic handling of device open/close

When closing the ibmvnic device we need to release the resources used
in communicating to the virtual I/O server. These need to be
re-negotiated with the server at open time.

This patch moves the releasing of resources a separate routine
and updates the open and close handlers to release all resources at
close and re-negotiate and allocate these resources at open.

Signed-off-by: Nathan Fontenot <nfont@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
John Allen
2017-03-17 17:13:43 -05:00
committed by David S. Miller
parent f6ef6408e8
commit ea5509f53c
2 changed files with 69 additions and 50 deletions

View File

@@ -1052,4 +1052,5 @@ struct ibmvnic_adapter {
struct work_struct ibmvnic_xport;
struct tasklet_struct tasklet;
bool failover;
bool is_closed;
};