Fix following problems about VLAN driver:

1. "VLAN Configuration” form crash after 'reconnect -r'
2. disconnect VLAN driver from the managed device will return EFI_NOT_FOUND
3. disconnect MNP driver from the managed device, VLAN driver couldn't be stopped.
Signed-off-by: Fu Siyuan <siyuan.fu@intel.com>
Reviewed-by: Ni, Ruiyu <ruiyu.ni@intel.com>
Reviewed-by: Gao, Liming <liming.gao@intel.com>


git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15174 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
Fu Siyuan
2014-01-24 05:33:18 +00:00
committed by sfu5
parent f20fc992ae
commit ca4e58d8e3
3 changed files with 66 additions and 39 deletions

View File

@@ -1,7 +1,7 @@
/** @file
The driver binding for VLAN configuration module.
Copyright (c) 2009, Intel Corporation. All rights reserved.<BR>
Copyright (c) 2009 - 2014, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions
of the BSD License which accompanies this distribution. The full
@@ -275,10 +275,13 @@ VlanConfigDriverBindingStop (
}
ASSERT (PrivateData->Signature == VLAN_CONFIG_PRIVATE_DATA_SIGNATURE);
//
// Uninstall VLAN configuration Form
//
UninstallVlanConfigForm (PrivateData);
if (NumberOfChildren != 0) {
if (NumberOfChildren != 1 || ChildHandleBuffer[0] != PrivateData->DriverHandle) {
return EFI_DEVICE_ERROR;
}
return UninstallVlanConfigForm (PrivateData);
}
//
// Uninstall the private GUID