From c9c4555f8d38053ed2da4b0f81fd86301a14d8cb Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Fri, 12 Nov 2010 13:11:18 +0100 Subject: Implement more instructions --- nios2.h | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'nios2.h') diff --git a/nios2.h b/nios2.h index 15edbe8..eb13b95 100644 --- a/nios2.h +++ b/nios2.h @@ -25,9 +25,18 @@ struct nios2 { uint32_t ctrl_regs[NIOS2_CTRL_REG_COUNT]; /* Program counter */ uint32_t pc; + /* User or Supervisor mode */ + int mode; + + /* Configurable processor features */ + bool has_mul; /* mul, muli */ + bool has_mulx; /* mulxss, mulxsu, mulxuu */ + bool has_div; /* div, divu */ + + bool has_mmu; /* Memory Management Unit */ }; -/* Aliases for general-purpors registers */ +/* Aliases for general-purpose registers */ enum { zero = 0, at, @@ -59,9 +68,17 @@ enum { config, mpubase, mpuacc, +}; +enum { + NIOS2_SUPERVISOR_MODE, + NIOS2_USER_MODE, }; extern void nios2_cpu_reset(struct nios2 *cpu); +extern bool nios2_in_user_mode(struct nios2 *cpu); +extern bool nios2_in_supervisor_mode(struct nios2 *cpu); +extern uint32_t nios2_cpu_fetch_instr(struct nios2 *cpu, uint32_t *mem_base); +extern int nios2_cpu_execute_instr(struct nios2 *cpu, uint32_t instr); #endif /* _NIOS2_H_ */ -- cgit v1.2.3-54-g00ecf net-next plumbingsTobias Klauser
summaryrefslogtreecommitdiff
path: root/Documentation/arm/OMAP
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@nokia.com>2010-11-10 11:45:19 +0200
committerPaul Mundt <lethal@linux-sh.org>2010-11-10 20:51:13 +0900
commit88abf44d3d8d4fefcbf3d57584d471e38cb51627 (patch)
treeb43468aec564c391415252636995e08ad3e45f0c /Documentation/arm/OMAP
parent108409a8a4e325db38f27258da68d7207a0ad433 (diff)
OMAP: VRAM: Fix boot-time memory allocation
Use memblock_free() and memblock_remove() to remove the allocated or reserved VRAM area from normal kernel memory. This is a slightly modified version of patches from Felipe Contreras and Namhyung Kim. Reported-by: Felipe Contreras <felipe.contreras@gmail.com> Reported-by: Namhyung Kim <namhyung@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'Documentation/arm/OMAP')