cpucontrol.h revision 224110
1/*-
2 * Copyright 2003-2011 Netlogic Microsystems (Netlogic). All rights
3 * reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met:
8 *
9 * 1. Redistributions of source code must retain the above copyright
10 *    notice, this list of conditions and the following disclaimer.
11 * 2. Redistributions in binary form must reproduce the above copyright
12 *    notice, this list of conditions and the following disclaimer in
13 *    the documentation and/or other materials provided with the
14 *    distribution.
15 *
16 * THIS SOFTWARE IS PROVIDED BY Netlogic Microsystems ``AS IS'' AND
17 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
19 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL NETLOGIC OR CONTRIBUTORS BE
20 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
23 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
24 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
26 * THE POSSIBILITY OF SUCH DAMAGE.
27 *
28 * $FreeBSD: head/sys/mips/nlm/hal/cpucontrol.h 224110 2011-07-16 19:35:44Z jchandra $
29 * NETLOGIC_BSD */
30
31#ifndef __NLM_CPUCONTROL_H__
32#define __NLM_CPUCONTROL_H__
33
34#define XLP_CPU_BLOCKID_IFU	0
35#define XLP_CPU_BLOCKID_ICU	1
36
37#define XLP_CPU_BLOCKID_IEU	2
38#define XLP_CPU_BLOCKID_LSU	3
39#define XLP_LSU_DEFEATURE	0x304
40#define XLP_LSU_CERRLOG_REGID 	0x09
41
42#define XLP_CPU_BLOCKID_MMU	4
43#define XLP_CPU_BLOCKID_PRF	5
44
45#define XLP_CPU_BLOCKID_SCH	7
46#define XLP_SCHED_DEFEATURE	0x700
47
48#define XLP_CPU_BLOCKID_SCU	8
49#define XLP_CPU_BLOCKID_FPU	9
50
51#define XLP_CPU_BLOCKID_MAP	10
52
53/* Offsets of interest from the 'MAP' Block */
54#define XLP_BLKID_MAP_THREADMODE                    0x00
55#define XLP_BLKID_MAP_EXT_EBASE_ENABLE              0x04
56#define XLP_BLKID_MAP_CCDI_CONFIG                   0x08
57#define XLP_BLKID_MAP_THRD0_CCDI_STATUS             0x0c
58#define XLP_BLKID_MAP_THRD1_CCDI_STATUS             0x10
59#define XLP_BLKID_MAP_THRD2_CCDI_STATUS             0x14
60#define XLP_BLKID_MAP_THRD3_CCDI_STATUS             0x18
61#define XLP_BLKID_MAP_THRD0_DEBUG_MODE              0x1c
62#define XLP_BLKID_MAP_THRD1_DEBUG_MODE              0x20
63#define XLP_BLKID_MAP_THRD2_DEBUG_MODE              0x24
64#define XLP_BLKID_MAP_THRD3_DEBUG_MODE              0x28
65#define XLP_BLKID_MAP_MISC_STATE                    0x60
66#define XLP_BLKID_MAP_DEBUG_READ_CTL                0x64
67#define XLP_BLKID_MAP_DEBUG_READ_REG0               0x68
68#define XLP_BLKID_MAP_DEBUG_READ_REG1               0x6c
69
70#endif /* __NLM_CPUCONTROL_H__ */
71