blob: 4f3a744ff57e6b88e8e891a2382503399d24235e [file] [log] [blame]
Martin Roth433659a2014-05-12 21:55:00 -06001/*
2 * This file is part of the coreboot project.
3 *
4 * Copyright (C) 2007-2009 coresystems GmbH
5 * Copyright (C) 2013 Google Inc.
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; version 2 of the License.
10 *
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.
Martin Roth433659a2014-05-12 21:55:00 -060015 */
16
17// PCI Interrupt Routing
18Method(_PRT)
19{
20 /*
21 * PICM comes from _PIC, which returns the following:
Martin Roth0cd338e2016-07-29 14:07:30 -060022 * 0 - PIC mode
23 * 1 - APIC mode
24 * 2 - SAPIC mode
Martin Roth433659a2014-05-12 21:55:00 -060025 */
26 If (PICM) {
27 Return (Package() {
28 #undef PIC_MODE
29 #include "irq_helper.h"
30 PCI_DEV_PIRQ_ROUTES
31 })
32 } Else {
33 Return (Package() {
34 #define PIC_MODE
35 #include "irq_helper.h"
36 PCI_DEV_PIRQ_ROUTES
37 })
38 }
Martin Rothd08057a2015-02-12 22:51:57 -070039
Martin Roth433659a2014-05-12 21:55:00 -060040}
Martin Rothd08057a2015-02-12 22:51:57 -070041
42PCIE_BRIDGE_IRQ_ROUTES
43#undef PIC_MODE
44#include "irq_helper.h"
45PCIE_BRIDGE_IRQ_ROUTES