]> git.baikalelectronics.ru Git - kernel.git/commit
ibmvnic: Allocate and request vpd in init_resources
authorJohn Allen <jallen@linux.vnet.ibm.com>
Thu, 18 Jan 2018 22:27:58 +0000 (16:27 -0600)
committerDavid S. Miller <davem@davemloft.net>
Mon, 22 Jan 2018 20:46:55 +0000 (15:46 -0500)
commit81366ae2ad4734abf69e6c79a54d2dfdc12aae49
treedbccddd469066137cb152eb96789184fc591267d
parent9a3aa002e6458c9ee11584939770f8c8c3bdeaf8
ibmvnic: Allocate and request vpd in init_resources

In reset events in which our memory allocations need to be reallocated,
VPD data is being freed, but never reallocated. This can cause issues if
we later attempt to access that memory or reset and attempt to free the
memory. This 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 <jallen@linux.vnet.ibm.com>
Reviewed-by: Nathan Fontenot <nfont@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/ibm/ibmvnic.c