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 Platform information used by IDCC.
27 #include "PlatformDxe.h"
29 #include <Guid/IdccData.h>
31 extern EFI_GUID mPlatformDriverGuid
;
39 EFI_DATA_HUB_PROTOCOL
*DataHub
;
41 EFI_IDCC_PROCESSOR_RATIO ProcRatio
;
44 // Locate the data hub protocol
46 Status
= gBS
->LocateProtocol (
47 &gEfiDataHubProtocolGuid
,
53 // Find processor actual ratio
55 Ratio
= 15; //Temporary - some dummy value.
58 // Fill in IDCC Type 5 structure
60 ProcRatio
.IdccHeader
.Type
= EFI_IDCC_PROC_RATIO_TYPE
;
61 ProcRatio
.IdccHeader
.RecordLength
= sizeof(EFI_IDCC_PROCESSOR_RATIO
);
62 ProcRatio
.ProcessorRatio
= Ratio
;
65 // Write data to the data hub
67 Status
= DataHub
->LogData (
71 EFI_DATA_RECORD_CLASS_DATA
,
73 sizeof(EFI_IDCC_PROCESSOR_RATIO
)