• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (c) 2016 Linaro Limited
3 * Copyright (c) 2016 Hisilicon Limited
4 *
5 * All rights reserved. This program and the accompanying materials
6 * are made available under the terms of the BSD License which accompanies
7 * this distribution, and is available at
8 * http://opensource.org/licenses/bsd-license.php
9 *
10 * Contributors:
11 *     Yi Li - yi.li@linaro.org
12*/
13
14#include <IndustryStandard/Acpi.h>
15#include "Hi1616Platform.h"
16
17#define EFI_ACPI_SYSTEM_LOCALITIES_ENTRY_COUNT 0x0000000000000004
18
19#pragma pack(1)
20typedef struct {
21  UINT8   Entry[EFI_ACPI_SYSTEM_LOCALITIES_ENTRY_COUNT];
22} EFI_ACPI_6_0_NUMBER_OF_SYSTEM_LOCALITIES_STRUCTURE;
23
24typedef struct {
25  EFI_ACPI_6_0_SYSTEM_LOCALITY_DISTANCE_INFORMATION_TABLE_HEADER    Header;
26  EFI_ACPI_6_0_NUMBER_OF_SYSTEM_LOCALITIES_STRUCTURE                NumSlit[EFI_ACPI_SYSTEM_LOCALITIES_ENTRY_COUNT];
27
28} EFI_ACPI_6_0_SYSTEM_LOCALITY_INFORMATION_TABLE;
29#pragma pack()
30
31//
32// System Locality Information Table
33// Please modify all values in Slit.h only.
34//
35EFI_ACPI_6_0_SYSTEM_LOCALITY_INFORMATION_TABLE Slit = {
36  {
37    {
38      EFI_ACPI_6_0_SYSTEM_LOCALITY_INFORMATION_TABLE_SIGNATURE,
39      sizeof (EFI_ACPI_6_0_SYSTEM_LOCALITY_INFORMATION_TABLE),
40      EFI_ACPI_6_0_SYSTEM_LOCALITY_DISTANCE_INFORMATION_TABLE_REVISION,
41      0x00,                                                     // Checksum will be updated at runtime
42      {EFI_ACPI_ARM_OEM_ID},
43      EFI_ACPI_ARM_OEM_TABLE_ID,
44      EFI_ACPI_ARM_OEM_REVISION,
45      EFI_ACPI_ARM_CREATOR_ID,
46      EFI_ACPI_ARM_CREATOR_REVISION,
47    },
48    //
49    // Beginning of SLIT specific fields
50    //
51    EFI_ACPI_SYSTEM_LOCALITIES_ENTRY_COUNT,
52  },
53  {
54    {{0x0A, 0x0F, 0x14, 0x14}}, //Locality   0
55    {{0x0F, 0x0A, 0x14, 0x14}}, //Locality   1
56    {{0x14, 0x14, 0x0A, 0x0F}}, //Locality   2
57    {{0x14, 0x14, 0x0F, 0x0A}}, //Locality   3
58  },
59};
60
61//
62// Reference the table being generated to prevent the optimizer from removing the
63// data structure from the executable
64//
65VOID* CONST ReferenceAcpiTable = &Slit;
66