3 Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
5 This program and the accompanying materials are licensed and made available under
6 the terms and conditions of the BSD License that accompanies this distribution.
7 The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php.
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
21 Sio Platform Policy Setting.
26 #include "PlatformDxe.h"
27 #include <Protocol/LpcWpc83627Policy.h>
30 EFI_WPC83627_POLICY_PROTOCOL mSio83627PolicyData
= {
31 { EFI_WPC83627_COM1_ENABLE
, // Com1
32 EFI_WPC83627_LPT1_ENABLE
, // Lpt1
33 EFI_WPC83627_FDD_DISABLE
, // Floppy
34 EFI_WPC83627_FDD_WRITE_ENABLE
, // FloppyWriteProtect
35 EFI_WPC83627_RESERVED_DEFAULT
, // Port80
36 EFI_WPC83627_ECIR_DISABLE
, // CIR
37 EFI_WPC83627_PS2_KBC_ENABLE
, // Ps2Keyboard
38 EFI_WPC83627_RESERVED_DEFAULT
, // Ps2Mouse
39 EFI_WPC83627_COM2_ENABLE
, // Com2
40 EFI_WPC83627_COM3_ENABLE
, // Com3
41 EFI_WPC83627_COM4_ENABLE
, // Com4
42 EFI_WPC83627_RESERVED_DEFAULT
, // Dac
45 LptModeEcp
, // LptMode
50 Publish the platform SIO policy setting.
56 InitSioPlatformPolicy(
65 if((mSystemConfiguration
.Serial
) || (mBoardFeatures
& B_BOARD_FEATURES_SIO_NO_COM1
)) {
66 mSio83627PolicyData
.DeviceEnables
.Com1
= EFI_WPC83627_COM1_DISABLE
;
69 if((mSystemConfiguration
.Serial2
) || ((mBoardFeatures
& B_BOARD_FEATURES_SIO_COM2
)==0)) {
70 mSio83627PolicyData
.DeviceEnables
.Com2
= EFI_WPC83627_COM2_DISABLE
;
73 mSio83627PolicyData
.LptMode
= mSystemConfiguration
.ParallelMode
;
74 if((!mSystemConfiguration
.Parallel
) || (mBoardFeatures
& B_BOARD_FEATURES_SIO_NO_PARALLEL
)) {
75 mSio83627PolicyData
.DeviceEnables
.Lpt1
= EFI_WPC83627_LPT1_DISABLE
;
78 Status
= gBS
->InstallProtocolInterface (
80 &gEfiLpcWpc83627PolicyProtocolGuid
,
84 ASSERT_EFI_ERROR(Status
);