Clean up the private GUID definition in module Level.
0. Remove the unused private GUID from module source files. 1. Use gEfiCallerIdGuid replace of the private module GUID. 2. Add the public header files to define HII FormSet and PackageList GUID used in every HII driver. 3. Move two EBC protocols for debug purpose from EBC driver to MdeModulePkg Include directory. Signed-off-by: lgao4 Reviewed-by: ydong10 gdong1 tye jfan12 wli12 rsun3 jyao1 git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12373 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
This file is for Challenge-Handshake Authentication Protocol (CHAP) Configuration.
|
||||
|
||||
Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2011, 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 text of the license may be found at
|
||||
@@ -15,8 +15,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#include "IScsiImpl.h"
|
||||
#include "Md5.h"
|
||||
|
||||
EFI_GUID mIScsiCHAPAuthInfoGuid = ISCSI_CHAP_AUTH_INFO_GUID;
|
||||
|
||||
/**
|
||||
Initator caculates its own expected hash value.
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
The header file of CHAP configuration.
|
||||
|
||||
Copyright (c) 2004 - 2009, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2011, 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 text of the license may be found at
|
||||
@@ -15,13 +15,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#ifndef _ISCSI_CHAP_H_
|
||||
#define _ISCSI_CHAP_H_
|
||||
|
||||
#define ISCSI_CHAP_AUTH_INFO_GUID \
|
||||
{ \
|
||||
0x786ec0ac, 0x65ae, 0x4d1b, {0xb1, 0x37, 0xd, 0x11, 0xa, 0x48, 0x37, 0x97} \
|
||||
}
|
||||
|
||||
extern EFI_GUID mIScsiCHAPAuthInfoGuid;
|
||||
|
||||
#define ISCSI_AUTH_METHOD_CHAP "CHAP"
|
||||
|
||||
#define ISCSI_KEY_CHAP_ALGORITHM "CHAP_A"
|
||||
|
@@ -14,7 +14,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
#include "IScsiImpl.h"
|
||||
|
||||
EFI_GUID mVendorGuid = ISCSI_CONFIG_GUID;
|
||||
CHAR16 mVendorStorageName[] = L"ISCSI_CONFIG_IFR_NVDATA";
|
||||
BOOLEAN mIScsiDeviceListUpdated = FALSE;
|
||||
UINTN mNumberOfIScsiDevices = 0;
|
||||
@@ -35,10 +34,7 @@ HII_VENDOR_DEVICE_PATH mIScsiHiiVendorDevicePath = {
|
||||
(UINT8) ((sizeof (VENDOR_DEVICE_PATH)) >> 8)
|
||||
}
|
||||
},
|
||||
//
|
||||
// {49D7B73E-143D-4716-977B-C45F1CB038CC}
|
||||
//
|
||||
{ 0x49d7b73e, 0x143d, 0x4716, { 0x97, 0x7b, 0xc4, 0x5f, 0x1c, 0xb0, 0x38, 0xcc } }
|
||||
IP4_ISCSI_CONFIG_GUID
|
||||
},
|
||||
{
|
||||
END_DEVICE_PATH_TYPE,
|
||||
@@ -224,7 +220,7 @@ IScsiUpdateDeviceList (
|
||||
DataSize = 0;
|
||||
Status = gRT->GetVariable (
|
||||
L"iSCSIDeviceList",
|
||||
&mVendorGuid,
|
||||
&gIp4IScsiConfigGuid,
|
||||
NULL,
|
||||
&DataSize,
|
||||
NULL
|
||||
@@ -234,7 +230,7 @@ IScsiUpdateDeviceList (
|
||||
|
||||
gRT->GetVariable (
|
||||
L"iSCSIDeviceList",
|
||||
&mVendorGuid,
|
||||
&gIp4IScsiConfigGuid,
|
||||
NULL,
|
||||
&DataSize,
|
||||
DeviceList
|
||||
@@ -282,7 +278,7 @@ IScsiUpdateDeviceList (
|
||||
CurMacInfo = &DeviceList->MacInfo[Index];
|
||||
IScsiMacAddrToStr (&CurMacInfo->Mac, CurMacInfo->Len, CurMacInfo->VlanId, MacString);
|
||||
gRT->SetVariable (MacString, &gEfiIScsiInitiatorNameProtocolGuid, 0, 0, NULL);
|
||||
gRT->SetVariable (MacString, &mIScsiCHAPAuthInfoGuid, 0, 0, NULL);
|
||||
gRT->SetVariable (MacString, &gIScsiCHAPAuthInfoGuid, 0, 0, NULL);
|
||||
}
|
||||
|
||||
FreePool (DeviceList);
|
||||
@@ -308,7 +304,7 @@ IScsiUpdateDeviceList (
|
||||
|
||||
gRT->SetVariable (
|
||||
L"iSCSIDeviceList",
|
||||
&mVendorGuid,
|
||||
&gIp4IScsiConfigGuid,
|
||||
ISCSI_CONFIG_VAR_ATTR,
|
||||
DeviceListSize,
|
||||
DeviceList
|
||||
@@ -488,7 +484,7 @@ IScsiFormExtractConfig (
|
||||
}
|
||||
|
||||
*Progress = Request;
|
||||
if ((Request != NULL) && !HiiIsConfigHdrMatch (Request, &mVendorGuid, mVendorStorageName)) {
|
||||
if ((Request != NULL) && !HiiIsConfigHdrMatch (Request, &gIp4IScsiConfigGuid, mVendorStorageName)) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
@@ -532,7 +528,7 @@ IScsiFormExtractConfig (
|
||||
// Allocate and fill a buffer large enough to hold the <ConfigHdr> template
|
||||
// followed by "&OFFSET=0&WIDTH=WWWWWWWWWWWWWWWW" followed by a Null-terminator
|
||||
//
|
||||
ConfigRequestHdr = HiiConstructConfigHdr (&mVendorGuid, mVendorStorageName, Private->DriverHandle);
|
||||
ConfigRequestHdr = HiiConstructConfigHdr (&gIp4IScsiConfigGuid, mVendorStorageName, Private->DriverHandle);
|
||||
Size = (StrLen (ConfigRequestHdr) + 32 + 1) * sizeof (CHAR16);
|
||||
ConfigRequest = AllocateZeroPool (Size);
|
||||
ASSERT (ConfigRequest != NULL);
|
||||
@@ -618,7 +614,7 @@ IScsiFormRouteConfig (
|
||||
// Check routing data in <ConfigHdr>.
|
||||
// Note: if only one Storage is used, then this checking could be skipped.
|
||||
//
|
||||
if (!HiiIsConfigHdrMatch (Configuration, &mVendorGuid, mVendorStorageName)) {
|
||||
if (!HiiIsConfigHdrMatch (Configuration, &gIp4IScsiConfigGuid, mVendorStorageName)) {
|
||||
*Progress = Configuration;
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
@@ -687,7 +683,7 @@ IScsiFormCallback (
|
||||
//
|
||||
IfrNvData = AllocateZeroPool (sizeof (ISCSI_CONFIG_IFR_NVDATA));
|
||||
ASSERT (IfrNvData != NULL);
|
||||
if (!HiiGetBrowserData (&mVendorGuid, mVendorStorageName, sizeof (ISCSI_CONFIG_IFR_NVDATA), (UINT8 *) IfrNvData)) {
|
||||
if (!HiiGetBrowserData (&gIp4IScsiConfigGuid, mVendorStorageName, sizeof (ISCSI_CONFIG_IFR_NVDATA), (UINT8 *) IfrNvData)) {
|
||||
FreePool (IfrNvData);
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
@@ -884,7 +880,7 @@ IScsiFormCallback (
|
||||
BufferSize = sizeof (Private->Current->AuthConfigData);
|
||||
gRT->SetVariable (
|
||||
Private->Current->MacString,
|
||||
&mIScsiCHAPAuthInfoGuid,
|
||||
&gIScsiCHAPAuthInfoGuid,
|
||||
ISCSI_CONFIG_VAR_ATTR,
|
||||
BufferSize,
|
||||
&Private->Current->AuthConfigData
|
||||
@@ -916,7 +912,7 @@ IScsiFormCallback (
|
||||
//
|
||||
// Pass changed uncommitted data back to Form Browser
|
||||
//
|
||||
HiiSetBrowserData (&mVendorGuid, mVendorStorageName, sizeof (ISCSI_CONFIG_IFR_NVDATA), (UINT8 *) IfrNvData, NULL);
|
||||
HiiSetBrowserData (&gIp4IScsiConfigGuid, mVendorStorageName, sizeof (ISCSI_CONFIG_IFR_NVDATA), (UINT8 *) IfrNvData, NULL);
|
||||
}
|
||||
|
||||
FreePool (IfrNvData);
|
||||
@@ -1027,7 +1023,7 @@ IScsiConfigUpdateForm (
|
||||
BufferSize = sizeof (ConfigFormEntry->AuthConfigData);
|
||||
Status = gRT->GetVariable (
|
||||
ConfigFormEntry->MacString,
|
||||
&mIScsiCHAPAuthInfoGuid,
|
||||
&gIScsiCHAPAuthInfoGuid,
|
||||
NULL,
|
||||
&BufferSize,
|
||||
&ConfigFormEntry->AuthConfigData
|
||||
@@ -1102,7 +1098,7 @@ IScsiConfigUpdateForm (
|
||||
|
||||
HiiUpdateForm (
|
||||
mCallbackInfo->RegisteredHandle,
|
||||
&mVendorGuid,
|
||||
&gIp4IScsiConfigGuid,
|
||||
FORMID_MAIN_FORM,
|
||||
StartOpCodeHandle, // Label DEVICE_ENTRY_LABEL
|
||||
EndOpCodeHandle // LABEL_END
|
||||
@@ -1173,7 +1169,7 @@ IScsiConfigFormInit (
|
||||
// Publish our HII data
|
||||
//
|
||||
CallbackInfo->RegisteredHandle = HiiAddPackages (
|
||||
&mVendorGuid,
|
||||
&gIp4IScsiConfigGuid,
|
||||
CallbackInfo->DriverHandle,
|
||||
IScsiDxeStrings,
|
||||
IScsiConfigDxeBin,
|
||||
|
@@ -17,7 +17,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#define EFI_NETWORK_DEVICE_CLASS 0x04
|
||||
|
||||
formset
|
||||
guid = ISCSI_CONFIG_GUID,
|
||||
guid = IP4_ISCSI_CONFIG_GUID,
|
||||
title = STRING_TOKEN(STR_ISCSI_CONFIG_FORM_TITLE),
|
||||
help = STRING_TOKEN(STR_ISCSI_CONFIG_FORM_HELP),
|
||||
class = EFI_NETWORK_DEVICE_CLASS,
|
||||
@@ -25,7 +25,7 @@ formset
|
||||
|
||||
varstore ISCSI_CONFIG_IFR_NVDATA,
|
||||
name = ISCSI_CONFIG_IFR_NVDATA,
|
||||
guid = ISCSI_CONFIG_GUID;
|
||||
guid = IP4_ISCSI_CONFIG_GUID;
|
||||
form formid = FORMID_MAIN_FORM,
|
||||
title = STRING_TOKEN(STR_ISCSI_MAIN_FORM_TITLE);
|
||||
|
||||
|
@@ -15,10 +15,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#ifndef _ISCSI_NVDATASTRUC_H_
|
||||
#define _ISCSI_NVDATASTRUC_H_
|
||||
|
||||
#define ISCSI_CONFIG_GUID \
|
||||
{ \
|
||||
0x6456ed61, 0x3579, 0x41c9, { 0x8a, 0x26, 0x0a, 0x0b, 0xd6, 0x2b, 0x78, 0xfc } \
|
||||
}
|
||||
#include <Guid/Ip4IScsiConfigHii.h>
|
||||
|
||||
#define VAR_EQ_TEST_NAME 0x100
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
The entry point of IScsi driver.
|
||||
|
||||
Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2011, 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 text of the license may be found at
|
||||
@@ -23,9 +23,6 @@ EFI_DRIVER_BINDING_PROTOCOL gIScsiDriverBinding = {
|
||||
NULL
|
||||
};
|
||||
|
||||
EFI_GUID gIScsiPrivateGuid = ISCSI_PRIVATE_GUID;
|
||||
|
||||
|
||||
/**
|
||||
Tests to see if this driver supports a given controller. If a child device is provided,
|
||||
it further tests to see if this driver supports creating a handle for the specified child device.
|
||||
@@ -63,7 +60,7 @@ IScsiDriverBindingSupported (
|
||||
|
||||
Status = gBS->OpenProtocol (
|
||||
ControllerHandle,
|
||||
&gIScsiPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
NULL,
|
||||
This->DriverBindingHandle,
|
||||
ControllerHandle,
|
||||
@@ -179,7 +176,7 @@ IScsiDriverBindingStart (
|
||||
//
|
||||
Status = gBS->InstallProtocolInterface (
|
||||
&ControllerHandle,
|
||||
&gIScsiPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
EFI_NATIVE_INTERFACE,
|
||||
&Private->IScsiIdentifier
|
||||
);
|
||||
@@ -332,7 +329,7 @@ IScsiDriverBindingStop (
|
||||
|
||||
Status = gBS->OpenProtocol (
|
||||
IScsiController,
|
||||
&gIScsiPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
(VOID **)&IScsiIdentifier,
|
||||
This->DriverBindingHandle,
|
||||
ControllerHandle,
|
||||
@@ -370,7 +367,7 @@ IScsiDriverBindingStop (
|
||||
//
|
||||
gBS->UninstallProtocolInterface (
|
||||
IScsiController,
|
||||
&gIScsiPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
&Private->IScsiIdentifier
|
||||
);
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
The header file of IScsiDriver.c.
|
||||
|
||||
Copyright (c) 2004 - 2008, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2011, 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 text of the license may be found at
|
||||
@@ -27,13 +27,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#include <Protocol/DriverBinding.h>
|
||||
#include <Protocol/ScsiPassThruExt.h>
|
||||
|
||||
#define ISCSI_PRIVATE_GUID \
|
||||
{ 0xfa3cde4c, 0x87c2, 0x427d, {0xae, 0xde, 0x7d, 0xd0, 0x96, 0xc8, 0x8c, 0x58} }
|
||||
|
||||
#define ISCSI_INITIATOR_NAME_VAR_NAME L"I_NAME"
|
||||
|
||||
extern EFI_GUID gIScsiPrivateGuid;
|
||||
|
||||
typedef struct _ISCSI_PRIVATE_PROTOCOL {
|
||||
UINT32 Reserved;
|
||||
} ISCSI_PRIVATE_PROTOCOL;
|
||||
|
@@ -1,7 +1,7 @@
|
||||
## @file
|
||||
# Component description file for IScsi module.
|
||||
#
|
||||
# Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2004 - 2011, 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 text of the license may be found at
|
||||
@@ -98,4 +98,6 @@
|
||||
gEfiIfrTianoGuid ## CONSUMES ## GUID
|
||||
gEfiAcpiTableGuid ## CONSUMES ## GUID
|
||||
gEfiAcpi10TableGuid ## CONSUMES ## GUID
|
||||
gEfiAcpi20TableGuid ## CONSUMES ## GUID
|
||||
gEfiAcpi20TableGuid ## CONSUMES ## GUID
|
||||
gIp4IScsiConfigGuid ## PRODUCES ## GUID
|
||||
gIScsiCHAPAuthInfoGuid
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Implementation for iSCSI Boot Firmware Table publication.
|
||||
|
||||
Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2011, 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 text of the license may be found at
|
||||
@@ -150,7 +150,7 @@ IScsiFillInitiatorSection (
|
||||
//
|
||||
// Get the identifier from the handle.
|
||||
//
|
||||
Status = gBS->HandleProtocol (Handle, &gIScsiPrivateGuid, (VOID **) &IScsiIdentifier);
|
||||
Status = gBS->HandleProtocol (Handle, &gEfiCallerIdGuid, (VOID **) &IScsiIdentifier);
|
||||
if (EFI_ERROR (Status)) {
|
||||
ASSERT (FALSE);
|
||||
return ;
|
||||
@@ -288,7 +288,7 @@ IScsiFillNICAndTargetSections (
|
||||
SectionOffset = &Control->NIC0Offset;
|
||||
|
||||
for (Index = 0; Index < HandleCount; Index++) {
|
||||
Status = gBS->HandleProtocol (Handles[Index], &gIScsiPrivateGuid, (VOID **)&IScsiIdentifier);
|
||||
Status = gBS->HandleProtocol (Handles[Index], &gEfiCallerIdGuid, (VOID **)&IScsiIdentifier);
|
||||
if (EFI_ERROR (Status)) {
|
||||
ASSERT (FALSE);
|
||||
return ;
|
||||
@@ -484,7 +484,7 @@ IScsiPublishIbft (
|
||||
//
|
||||
Status = gBS->LocateHandleBuffer (
|
||||
ByProtocol,
|
||||
&gIScsiPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
NULL,
|
||||
&HandleCount,
|
||||
&HandleBuffer
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Miscellaneous routines for iSCSI driver.
|
||||
|
||||
Copyright (c) 2004 - 2009, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2011, 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 text of the license may be found at
|
||||
@@ -684,7 +684,7 @@ IScsiGetConfigData (
|
||||
BufferSize = sizeof (Session->AuthData.AuthConfig);
|
||||
Status = gRT->GetVariable (
|
||||
MacString,
|
||||
&mIScsiCHAPAuthInfoGuid,
|
||||
&gIScsiCHAPAuthInfoGuid,
|
||||
NULL,
|
||||
&BufferSize,
|
||||
&Session->AuthData.AuthConfig
|
||||
|
@@ -1,7 +1,7 @@
|
||||
## @file
|
||||
# Component name for module Ip4Config
|
||||
#
|
||||
# Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2011, 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
|
||||
@@ -67,4 +67,4 @@
|
||||
|
||||
[Guids]
|
||||
gEfiNicIp4ConfigVariableGuid ## CONSUMES ## Guid
|
||||
|
||||
gNicIp4ConfigNvDataGuid ## PRODUCES ## Guid
|
||||
|
@@ -15,9 +15,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#include "Ip4ConfigNv.h"
|
||||
#include "NicIp4Variable.h"
|
||||
|
||||
EFI_GUID mNicIp4ConfigNvDataGuid = EFI_NIC_IP4_CONFIG_NVDATA_GUID;
|
||||
|
||||
|
||||
/**
|
||||
Calculate the prefix length of the IPv4 subnet mask.
|
||||
|
||||
@@ -431,7 +428,7 @@ Ip4DeviceExtractConfig (
|
||||
}
|
||||
}
|
||||
|
||||
if ((Request == NULL) || HiiIsConfigHdrMatch (Request, &mNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE)) {
|
||||
if ((Request == NULL) || HiiIsConfigHdrMatch (Request, &gNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE)) {
|
||||
|
||||
IfrFormNvData = AllocateZeroPool (sizeof (IP4_CONFIG_IFR_NVDATA));
|
||||
if (IfrFormNvData == NULL) {
|
||||
@@ -447,7 +444,7 @@ Ip4DeviceExtractConfig (
|
||||
// Allocate and fill a buffer large enough to hold the <ConfigHdr> template
|
||||
// followed by "&OFFSET=0&WIDTH=WWWWWWWWWWWWWWWW" followed by a Null-terminator
|
||||
//
|
||||
ConfigRequestHdr = HiiConstructConfigHdr (&mNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE, Ip4ConfigInstance->ChildHandle);
|
||||
ConfigRequestHdr = HiiConstructConfigHdr (&gNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE, Ip4ConfigInstance->ChildHandle);
|
||||
Size = (StrLen (ConfigRequestHdr) + 32 + 1) * sizeof (CHAR16);
|
||||
ConfigRequest = AllocateZeroPool (Size);
|
||||
ASSERT (ConfigRequest != NULL);
|
||||
@@ -498,7 +495,7 @@ Ip4DeviceExtractConfig (
|
||||
FreePool (FormResult);
|
||||
} else if (HiiIsConfigHdrMatch (Request, &gEfiNicIp4ConfigVariableGuid, EFI_NIC_IP4_CONFIG_VARIABLE)) {
|
||||
*Results = DeviceResult;
|
||||
} else if (HiiIsConfigHdrMatch (Request, &mNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE)) {
|
||||
} else if (HiiIsConfigHdrMatch (Request, &gNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE)) {
|
||||
*Results = FormResult;
|
||||
} else {
|
||||
return EFI_NOT_FOUND;
|
||||
@@ -582,7 +579,7 @@ Ip4DeviceRouteConfig (
|
||||
//
|
||||
// Check Routing data in <ConfigHdr>.
|
||||
//
|
||||
if (HiiIsConfigHdrMatch (Configuration, &mNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE)) {
|
||||
if (HiiIsConfigHdrMatch (Configuration, &gNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE)) {
|
||||
//
|
||||
// Convert buffer data to <ConfigResp> by helper function BlockToConfig()
|
||||
//
|
||||
@@ -703,7 +700,7 @@ Ip4FormCallback (
|
||||
//
|
||||
// Retrive uncommitted data from Browser
|
||||
//
|
||||
if (!HiiGetBrowserData (&mNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE, sizeof (IP4_CONFIG_IFR_NVDATA), (UINT8 *) IfrFormNvData)) {
|
||||
if (!HiiGetBrowserData (&gNicIp4ConfigNvDataGuid, EFI_NIC_IP4_CONFIG_VARIABLE, sizeof (IP4_CONFIG_IFR_NVDATA), (UINT8 *) IfrFormNvData)) {
|
||||
FreePool (IfrFormNvData);
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
@@ -841,7 +838,7 @@ Ip4ConfigDeviceInit (
|
||||
// Publish our HII data
|
||||
//
|
||||
Instance->RegisteredHandle = HiiAddPackages (
|
||||
&mNicIp4ConfigNvDataGuid,
|
||||
&gNicIp4ConfigNvDataGuid,
|
||||
Instance->ChildHandle,
|
||||
Ip4ConfigDxeStrings,
|
||||
Ip4ConfigDxeBin,
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Routines used to operate the Ip4 configure variable.
|
||||
|
||||
Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2009 - 2011, 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 text of the license may be found at<BR>
|
||||
@@ -15,10 +15,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#ifndef _NIC_IP4_NV_DATA_H_
|
||||
#define _NIC_IP4_NV_DATA_H_
|
||||
|
||||
#define EFI_NIC_IP4_CONFIG_NVDATA_GUID \
|
||||
{ \
|
||||
0x9d5b53f, 0xf4b0, 0x4f59, { 0xa0, 0xb1, 0x7b, 0x57, 0xd3, 0x5c, 0xe, 0x5 } \
|
||||
}
|
||||
#include <Guid/Ip4ConfigHii.h>
|
||||
|
||||
#define FORMID_MAIN_FORM 1
|
||||
#define FORMID_DEVICE_FORM 2
|
||||
|
@@ -16,7 +16,7 @@
|
||||
#include "VlanConfigNvData.h"
|
||||
|
||||
formset
|
||||
guid = VLAN_CONFIG_PRIVATE_GUID,
|
||||
guid = VLAN_CONFIG_FORM_SET_GUID,
|
||||
title = STRING_TOKEN(STR_VLAN_FORM_SET_TITLE),
|
||||
help = STRING_TOKEN(STR_VLAN_FORM_SET_TITLE_HELP),
|
||||
classguid = EFI_HII_PLATFORM_SETUP_FORMSET_GUID,
|
||||
@@ -24,7 +24,7 @@ formset
|
||||
varstore VLAN_CONFIGURATION,
|
||||
varid = VLAN_CONFIGURATION_VARSTORE_ID,
|
||||
name = VlanNvData,
|
||||
guid = VLAN_CONFIG_PRIVATE_GUID;
|
||||
guid = VLAN_CONFIG_FORM_SET_GUID;
|
||||
|
||||
form formid = VLAN_HEAD_FORM_ID,
|
||||
title = STRING_TOKEN(STR_VLAN_FORM_TITLE);
|
||||
|
@@ -15,8 +15,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
#include "VlanConfigImpl.h"
|
||||
|
||||
EFI_GUID gVlanConfigPrivateGuid = VLAN_CONFIG_PRIVATE_GUID;
|
||||
|
||||
EFI_DRIVER_BINDING_PROTOCOL gVlanConfigDriverBinding = {
|
||||
VlanConfigDriverBindingSupported,
|
||||
VlanConfigDriverBindingStart,
|
||||
@@ -136,7 +134,7 @@ VlanConfigDriverBindingStart (
|
||||
//
|
||||
Status = gBS->OpenProtocol (
|
||||
ControllerHandle,
|
||||
&gVlanConfigPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
(VOID **) &PrivateData,
|
||||
This->DriverBindingHandle,
|
||||
ControllerHandle,
|
||||
@@ -203,7 +201,7 @@ VlanConfigDriverBindingStart (
|
||||
//
|
||||
Status = gBS->InstallMultipleProtocolInterfaces (
|
||||
&ControllerHandle,
|
||||
&gVlanConfigPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
PrivateData,
|
||||
NULL
|
||||
);
|
||||
@@ -266,7 +264,7 @@ VlanConfigDriverBindingStop (
|
||||
//
|
||||
Status = gBS->OpenProtocol (
|
||||
ControllerHandle,
|
||||
&gVlanConfigPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
(VOID **) &PrivateData,
|
||||
This->DriverBindingHandle,
|
||||
ControllerHandle,
|
||||
@@ -287,7 +285,7 @@ VlanConfigDriverBindingStop (
|
||||
//
|
||||
Status = gBS->UninstallMultipleProtocolInterfaces (
|
||||
ControllerHandle,
|
||||
&gVlanConfigPrivateGuid,
|
||||
&gEfiCallerIdGuid,
|
||||
PrivateData,
|
||||
NULL
|
||||
);
|
||||
|
@@ -52,6 +52,7 @@
|
||||
|
||||
[Guids]
|
||||
gEfiIfrTianoGuid
|
||||
gVlanConfigFormSetGuid
|
||||
|
||||
[Protocols]
|
||||
gEfiHiiConfigAccessProtocolGuid ## PRODUCES
|
||||
|
@@ -15,7 +15,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
#include "VlanConfigImpl.h"
|
||||
|
||||
EFI_GUID mVlanFormSetGuid = VLAN_CONFIG_PRIVATE_GUID;
|
||||
CHAR16 mVlanStorageName[] = L"VlanNvData";
|
||||
EFI_HII_CONFIG_ROUTING_PROTOCOL *mHiiConfigRouting = NULL;
|
||||
|
||||
@@ -37,7 +36,7 @@ VENDOR_DEVICE_PATH mHiiVendorDevicePathNode = {
|
||||
(UINT8) ((sizeof (VENDOR_DEVICE_PATH)) >> 8)
|
||||
}
|
||||
},
|
||||
VLAN_CONFIG_PRIVATE_GUID
|
||||
VLAN_CONFIG_FORM_SET_GUID
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -89,7 +88,7 @@ VlanExtractConfig (
|
||||
}
|
||||
|
||||
*Progress = Request;
|
||||
if ((Request != NULL) && !HiiIsConfigHdrMatch (Request, &mVlanFormSetGuid, mVlanStorageName)) {
|
||||
if ((Request != NULL) && !HiiIsConfigHdrMatch (Request, &gVlanConfigFormSetGuid, mVlanStorageName)) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
@@ -119,7 +118,7 @@ VlanExtractConfig (
|
||||
// Allocate and fill a buffer large enough to hold the <ConfigHdr> template
|
||||
// followed by "&OFFSET=0&WIDTH=WWWWWWWWWWWWWWWW" followed by a Null-terminator
|
||||
//
|
||||
ConfigRequestHdr = HiiConstructConfigHdr (&mVlanFormSetGuid, mVlanStorageName, PrivateData->DriverHandle);
|
||||
ConfigRequestHdr = HiiConstructConfigHdr (&gVlanConfigFormSetGuid, mVlanStorageName, PrivateData->DriverHandle);
|
||||
Size = (StrLen (ConfigRequestHdr) + 32 + 1) * sizeof (CHAR16);
|
||||
ConfigRequest = AllocateZeroPool (Size);
|
||||
ASSERT (ConfigRequest != NULL);
|
||||
@@ -187,7 +186,7 @@ VlanRouteConfig (
|
||||
}
|
||||
|
||||
*Progress = Configuration;
|
||||
if (!HiiIsConfigHdrMatch (Configuration, &mVlanFormSetGuid, mVlanStorageName)) {
|
||||
if (!HiiIsConfigHdrMatch (Configuration, &gVlanConfigFormSetGuid, mVlanStorageName)) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
@@ -246,7 +245,7 @@ VlanCallback (
|
||||
//
|
||||
Configuration = AllocateZeroPool (sizeof (VLAN_CONFIGURATION));
|
||||
ASSERT (Configuration != NULL);
|
||||
HiiGetBrowserData (&mVlanFormSetGuid, mVlanStorageName, sizeof (VLAN_CONFIGURATION), (UINT8 *) Configuration);
|
||||
HiiGetBrowserData (&gVlanConfigFormSetGuid, mVlanStorageName, sizeof (VLAN_CONFIGURATION), (UINT8 *) Configuration);
|
||||
|
||||
VlanConfig = PrivateData->VlanConfig;
|
||||
|
||||
@@ -316,7 +315,7 @@ VlanCallback (
|
||||
break;
|
||||
}
|
||||
|
||||
HiiSetBrowserData (&mVlanFormSetGuid, mVlanStorageName, sizeof (VLAN_CONFIGURATION), (UINT8 *) Configuration, NULL);
|
||||
HiiSetBrowserData (&gVlanConfigFormSetGuid, mVlanStorageName, sizeof (VLAN_CONFIGURATION), (UINT8 *) Configuration, NULL);
|
||||
FreePool (Configuration);
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
@@ -444,7 +443,7 @@ VlanUpdateForm (
|
||||
|
||||
HiiUpdateForm (
|
||||
PrivateData->HiiHandle, // HII handle
|
||||
&mVlanFormSetGuid, // Formset GUID
|
||||
&gVlanConfigFormSetGuid, // Formset GUID
|
||||
VLAN_CONFIGURATION_FORM_ID, // Form ID
|
||||
StartOpCodeHandle, // Label for where to insert opcodes
|
||||
EndOpCodeHandle // Replace data
|
||||
@@ -515,7 +514,7 @@ InstallVlanConfigForm (
|
||||
// Publish the HII package list
|
||||
//
|
||||
HiiHandle = HiiAddPackages (
|
||||
&mVlanFormSetGuid,
|
||||
&gVlanConfigFormSetGuid,
|
||||
DriverHandle,
|
||||
VlanConfigDxeStrings,
|
||||
VlanConfigBin,
|
||||
|
@@ -17,12 +17,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#define __VLAN_CONFIG_NV_DATA_H__
|
||||
|
||||
#include <Guid/HiiPlatformSetupFormset.h>
|
||||
|
||||
|
||||
#define VLAN_CONFIG_PRIVATE_GUID \
|
||||
{ \
|
||||
0xd79df6b0, 0xef44, 0x43bd, {0x97, 0x97, 0x43, 0xe9, 0x3b, 0xcf, 0x5f, 0xa8 } \
|
||||
}
|
||||
#include <Guid/VlanConfigHii.h>
|
||||
|
||||
#define VLAN_CONFIGURATION_VARSTORE_ID 0x0001
|
||||
#define VLAN_CONFIGURATION_FORM_ID 0x0001
|
||||
|
Reference in New Issue
Block a user