2 * This file is part of the coreboot project.
4 * Copyright (C) 2011 Google Inc.
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License as
8 * published by the Free Software Foundation; version 2 of
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
17 /* These devices are created at runtime */
18 External (\_PR.CP00, DeviceObj)
19 External (\_PR.CP01, DeviceObj)
20 External (\_PR.CP02, DeviceObj)
21 External (\_PR.CP03, DeviceObj)
24 /* Notify OS to re-read CPU tables, assuming ^2 CPU count */
27 If (LGreaterEqual (\PCNT, 2)) {
28 Notify (\_PR.CP00, 0x81) /* _CST */
29 Notify (\_PR.CP01, 0x81) /* _CST */
31 If (LGreaterEqual (\PCNT, 4)) {
32 Notify (\_PR.CP02, 0x81) /* _CST */
33 Notify (\_PR.CP03, 0x81) /* _CST */
37 /* Notify OS to re-read CPU _PPC limit, assuming ^2 CPU count */
40 If (LGreaterEqual (\PCNT, 2)) {
41 Notify (\_PR.CP00, 0x80) /* _PPC */
42 Notify (\_PR.CP01, 0x80) /* _PPC */
44 If (LGreaterEqual (\PCNT, 4)) {
45 Notify (\_PR.CP02, 0x80) /* _PPC */
46 Notify (\_PR.CP03, 0x80) /* _PPC */
50 /* Notify OS to re-read Throttle Limit tables, assuming ^2 CPU count */
53 If (LGreaterEqual (\PCNT, 2)) {
54 Notify (\_PR.CP00, 0x82) /* _TPC */
55 Notify (\_PR.CP01, 0x82) /* _TPC */
57 If (LGreaterEqual (\PCNT, 4)) {
58 Notify (\_PR.CP02, 0x82) /* _TPC */
59 Notify (\_PR.CP03, 0x82) /* _TPC */
63 /* Return a package containing enabled processor entries */
66 If (LGreaterEqual (\PCNT, 4)) {
67 Return (Package() {\_PR.CP00, \_PR.CP01, \_PR.CP02, \_PR.CP03})
68 } ElseIf (LGreaterEqual (\PCNT, 2)) {
69 Return (Package() {\_PR.CP00, \_PR.CP01})
71 Return (Package() {\_PR.CP00})