Clean up the Isa related DXE in IntelFrameworkMoudlePkg.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@3359 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
yshang1
2007-07-19 07:57:59 +00:00
parent fcc7efa0d8
commit c21fc3e8ae
16 changed files with 292 additions and 494 deletions

View File

@@ -184,6 +184,7 @@ Ps2KeyboardComponentNameGetControllerName (
ControllerHandle,
EFI_OPEN_PROTOCOL_BY_DRIVER
);
if (!EFI_ERROR (Status)) {
gBS->CloseProtocol (
ControllerHandle,

View File

@@ -1,58 +0,0 @@
/**@file
Entry Point Source file.
This file contains the user entry point
Copyright (c) 2006 - 2007, Intel Corporation
All rights reserved. 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
http://opensource.org/licenses/bsd-license.php
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
//
// Include common header file for this module.
//
#include "Ps2Keyboard.h"
/**
The user Entry Point for module Ps2Keyboard. The user code starts with this function.
@param[in] ImageHandle The firmware allocated handle for the EFI image.
@param[in] SystemTable A pointer to the EFI System Table.
@retval EFI_SUCCESS The entry point is executed successfully.
@retval other Some error occurs when executing this entry point.
**/
EFI_STATUS
EFIAPI
InitializePs2Keyboard(
IN EFI_HANDLE ImageHandle,
IN EFI_SYSTEM_TABLE *SystemTable
)
{
EFI_STATUS Status;
//
// Install driver model protocol(s).
//
Status = EfiLibInstallAllDriverProtocols (
ImageHandle,
SystemTable,
&gKeyboardControllerDriver,
ImageHandle,
&gPs2KeyboardComponentName,
NULL,
NULL
);
ASSERT_EFI_ERROR (Status);
return Status;
}

View File

@@ -466,3 +466,41 @@ KbdControllerDriverStop (
return EFI_SUCCESS;
}
/**
The user Entry Point for module Ps2Keyboard. The user code starts with this function.
@param[in] ImageHandle The firmware allocated handle for the EFI image.
@param[in] SystemTable A pointer to the EFI System Table.
@retval EFI_SUCCESS The entry point is executed successfully.
@retval other Some error occurs when executing this entry point.
**/
EFI_STATUS
EFIAPI
InitializePs2Keyboard(
IN EFI_HANDLE ImageHandle,
IN EFI_SYSTEM_TABLE *SystemTable
)
{
EFI_STATUS Status;
//
// Install driver model protocol(s).
//
Status = EfiLibInstallAllDriverProtocols (
ImageHandle,
SystemTable,
&gKeyboardControllerDriver,
ImageHandle,
&gPs2KeyboardComponentName,
NULL,
NULL
);
ASSERT_EFI_ERROR (Status);
return Status;
}

View File

@@ -16,14 +16,9 @@
#
#**/
################################################################################
#
# Defines Section - statements that will be processed to create a Makefile.
#
################################################################################
[Defines]
INF_VERSION = 0x00010005
BASE_NAME = Ps2Keyboard
BASE_NAME = Ps2KeyboardDxe
FILE_GUID = 3DC82376-637B-40a6-A8FC-A565417F2C38
MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
@@ -32,25 +27,7 @@
ENTRY_POINT = InitializePs2Keyboard
#
# The following information is for reference only and not required by the build tools.
#
# VALID_ARCHITECTURES = IA32 X64 IPF EBC
#
# DRIVER_BINDING = gKeyboardControllerDriver
# COMPONENT_NAME = gPs2KeyboardComponentName
# Create Event Guid C Name: Event Type: EVENT_TYPE_RELATIVE_TIMER
# Create Event Guid C Name: Event Type: EVENT_TYPE_PERIODIC_TIMER
#
# Signal Event Guid C Name: Event Type: EVENT_TYPE_PERIODIC_TIMER
#
#
################################################################################
#
# Sources Section - list of files that are required for the build to succeed.
#
################################################################################
[Sources.common]
ComponentName.c
@@ -58,30 +35,14 @@
Ps2KbdCtrller.c
Ps2KbdTextIn.c
Ps2Keyboard.c
EntryPoint.c
################################################################################
#
# Package Dependency Section - list of Package files that are required for
# this module.
#
################################################################################
[Packages]
MdePkg/MdePkg.dec
MdeModulePkg/MdeModulePkg.dec
IntelFrameworkPkg/IntelFrameworkPkg.dec
IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
################################################################################
#
# Library Class Section - list of Library Classes that are required for
# this module.
#
################################################################################
[LibraryClasses]
MemoryAllocationLib
UefiRuntimeServicesTableLib
@@ -91,14 +52,6 @@
UefiLib
UefiDriverEntryPoint
################################################################################
#
# Protocol C Name Section - list of Protocol and Protocol Notify C Names
# that this module uses or produces.
#
################################################################################
[Protocols]
gEfiPs2PolicyProtocolGuid # PROTOCOL TO_START
gEfiIsaIoProtocolGuid # PROTOCOL TO_START