Commit 785a2b10 authored by Lijun Pan's avatar Lijun Pan Committed by David S. Miller

Revert "ibmvnic: remove never executed if statement"

This reverts commit 550f4d46.

adapter->from_passive_init may be changed in ibmvnic_handle_crq
while ibmvnic_reset_init is waiting for the completion of
adapter->init_done.
Signed-off-by: default avatarLijun Pan <ljp@linux.ibm.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 5d7d28e5
...@@ -5047,6 +5047,12 @@ static int ibmvnic_reset_init(struct ibmvnic_adapter *adapter, bool reset) ...@@ -5047,6 +5047,12 @@ static int ibmvnic_reset_init(struct ibmvnic_adapter *adapter, bool reset)
return adapter->init_done_rc; return adapter->init_done_rc;
} }
if (adapter->from_passive_init) {
adapter->state = VNIC_OPEN;
adapter->from_passive_init = false;
return -1;
}
if (reset && if (reset &&
test_bit(0, &adapter->resetting) && !adapter->wait_for_reset && test_bit(0, &adapter->resetting) && !adapter->wait_for_reset &&
adapter->reset_reason != VNIC_RESET_MOBILITY) { adapter->reset_reason != VNIC_RESET_MOBILITY) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment