blob: d1683202399b112b07e1bc2edd13bfb369e0ebfa [file] [log] [blame]
Tom Rini83d290c2018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0 */
wdenk6069ff22003-02-28 00:49:47 +00002/*
Shinya Kuribayashi282223a2008-03-25 11:43:17 +09003 * Various ISA level dependent constants.
wdenk6069ff22003-02-28 00:49:47 +00004 * Most of the following constants reflect the different layout
5 * of Coprocessor 0 registers.
6 *
7 * Copyright (c) 1998 Harald Koerfgen
8 */
wdenk6069ff22003-02-28 00:49:47 +00009
10#ifndef __ASM_ISADEP_H
11#define __ASM_ISADEP_H
12
Shinya Kuribayashi282223a2008-03-25 11:43:17 +090013#if defined(CONFIG_CPU_R3000) || defined(CONFIG_CPU_TX39XX)
wdenk6069ff22003-02-28 00:49:47 +000014/*
15 * R2000 or R3000
16 */
17
18/*
19 * kernel or user mode? (CP0_STATUS)
20 */
21#define KU_MASK 0x08
Daniel Schwierzecka3ab2ae2016-01-12 21:48:26 +010022#define KU_USER 0x08
wdenk6069ff22003-02-28 00:49:47 +000023#define KU_KERN 0x00
24
25#else
26/*
27 * kernel or user mode?
28 */
29#define KU_MASK 0x18
Daniel Schwierzecka3ab2ae2016-01-12 21:48:26 +010030#define KU_USER 0x10
wdenk6069ff22003-02-28 00:49:47 +000031#define KU_KERN 0x00
32
33#endif
34
35#endif /* __ASM_ISADEP_H */