Update MnpDxe to deliver VLAN tagged packet even when there is no VLAN is configured through VlanConfig protocol, this ensure that interesting applications could still get chance to receive all layer 2 frames.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10771 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
xdu2 2010-08-04 01:15:50 +00:00
parent 42a83e80f3
commit ef89996c70
1 changed files with 8 additions and 1 deletions

View File

@ -944,7 +944,14 @@ MnpReceivePacket (
} }
VlanId = 0; VlanId = 0;
IsVlanPacket = MnpRemoveVlanTag (MnpDeviceData, Nbuf, &VlanId); if (MnpDeviceData->NumberOfVlan != 0) {
//
// VLAN is configured, remove the VLAN tag if any
//
IsVlanPacket = MnpRemoveVlanTag (MnpDeviceData, Nbuf, &VlanId);
} else {
IsVlanPacket = FALSE;
}
MnpServiceData = MnpFindServiceData (MnpDeviceData, VlanId); MnpServiceData = MnpFindServiceData (MnpDeviceData, VlanId);
if (MnpServiceData == NULL) { if (MnpServiceData == NULL) {