Commit | Line | Data |
---|---|---|
1da177e4 LT |
1 | /* |
2 | * ItLpNaca.h | |
3 | * Copyright (C) 2001 Mike Corrigan IBM Corporation | |
fcee3895 | 4 | * |
1da177e4 LT |
5 | * This program is free software; you can redistribute it and/or modify |
6 | * it under the terms of the GNU General Public License as published by | |
7 | * the Free Software Foundation; either version 2 of the License, or | |
8 | * (at your option) any later version. | |
fcee3895 | 9 | * |
1da177e4 LT |
10 | * This program is distributed in the hope that it will be useful, |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13 | * GNU General Public License for more details. | |
fcee3895 | 14 | * |
1da177e4 LT |
15 | * You should have received a copy of the GNU General Public License |
16 | * along with this program; if not, write to the Free Software | |
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
18 | */ | |
ecb3ca27 KD |
19 | #ifndef _ASM_POWERPC_ISERIES_IT_LP_NACA_H |
20 | #define _ASM_POWERPC_ISERIES_IT_LP_NACA_H | |
1da177e4 | 21 | |
0bc0ffd5 SR |
22 | #include <linux/types.h> |
23 | ||
fcee3895 SR |
24 | /* |
25 | * This control block contains the data that is shared between the | |
26 | * hypervisor (PLIC) and the OS. | |
27 | */ | |
1da177e4 | 28 | |
fcee3895 | 29 | struct ItLpNaca { |
1da177e4 | 30 | // CACHE_LINE_1 0x0000 - 0x007F Contains read-only data |
1da177e4 LT |
31 | u32 xDesc; // Eye catcher x00-x03 |
32 | u16 xSize; // Size of this class x04-x05 | |
33 | u16 xIntHdlrOffset; // Offset to IntHdlr array x06-x07 | |
34 | u8 xMaxIntHdlrEntries; // Number of entries in array x08-x08 | |
35 | u8 xPrimaryLpIndex; // LP Index of Primary x09-x09 | |
36 | u8 xServiceLpIndex; // LP Ind of Service Focal Pointx0A-x0A | |
37 | u8 xLpIndex; // LP Index x0B-x0B | |
38 | u16 xMaxLpQueues; // Number of allocated queues x0C-x0D | |
39 | u16 xLpQueueOffset; // Offset to start of LP queues x0E-x0F | |
f9cb83ac SR |
40 | u8 xPirEnvironMode; // Piranha or hardware x10-x10 |
41 | u8 xPirConsoleMode; // Piranha console indicator x11-x11 | |
42 | u8 xPirDasdMode; // Piranha dasd indicator x12-x12 | |
1da177e4 | 43 | u8 xRsvd1_0[5]; // Reserved for Piranha related x13-x17 |
f9cb83ac SR |
44 | u8 flags; // flags, see below x18-x1F |
45 | u8 xSpVpdFormat; // VPD areas are in CSP format ... | |
46 | u8 xIntProcRatio; // Ratio of int procs to procs ... | |
1da177e4 LT |
47 | u8 xRsvd1_2[5]; // Reserved ... |
48 | u16 xRsvd1_3; // Reserved x20-x21 | |
49 | u16 xPlicVrmIndex; // VRM index of PLIC x22-x23 | |
50 | u16 xMinSupportedSlicVrmInd;// Min supported OS VRM index x24-x25 | |
51 | u16 xMinCompatableSlicVrmInd;// Min compatible OS VRM index x26-x27 | |
52 | u64 xLoadAreaAddr; // ER address of load area x28-x2F | |
53 | u32 xLoadAreaChunks; // Chunks for the load area x30-x33 | |
54 | u32 xPaseSysCallCRMask; // Mask used to test CR before x34-x37 | |
fcee3895 SR |
55 | // doing an ASR switch on PASE |
56 | // system call. | |
57 | u64 xSlicSegmentTablePtr; // Pointer to Slic seg table. x38-x3f | |
58 | u8 xRsvd1_4[64]; // x40-x7F | |
59 | ||
1da177e4 | 60 | // CACHE_LINE_2 0x0080 - 0x00FF Contains local read-write data |
1da177e4 LT |
61 | u8 xRsvd2_0[128]; // Reserved x00-x7F |
62 | ||
1da177e4 | 63 | // CACHE_LINE_3-6 0x0100 - 0x02FF Contains LP Queue indicators |
fcee3895 | 64 | // NB: Padding required to keep xInterrruptHdlr at x300 which is required |
1da177e4 | 65 | // for v4r4 PLIC. |
1da177e4 LT |
66 | u8 xOldLpQueue[128]; // LP Queue needed for v4r4 100-17F |
67 | u8 xRsvd3_0[384]; // Reserved 180-2FF | |
fcee3895 | 68 | |
1da177e4 LT |
69 | // CACHE_LINE_7-8 0x0300 - 0x03FF Contains the address of the OS interrupt |
70 | // handlers | |
1da177e4 LT |
71 | u64 xInterruptHdlr[32]; // Interrupt handlers 300-x3FF |
72 | }; | |
73 | ||
0bc0ffd5 SR |
74 | extern struct ItLpNaca itLpNaca; |
75 | ||
f9cb83ac SR |
76 | #define ITLPNACA_LPAR 0x80 /* Is LPAR installed on the system */ |
77 | #define ITLPNACA_PARTITIONED 0x40 /* Is the system partitioned */ | |
78 | #define ITLPNACA_HWSYNCEDTBS 0x20 /* Hardware synced TBs */ | |
79 | #define ITLPNACA_HMTINT 0x10 /* Utilize MHT for interrupts */ | |
80 | ||
ecb3ca27 | 81 | #endif /* _ASM_POWERPC_ISERIES_IT_LP_NACA_H */ |