Skip to content

Commit

Permalink
metag: add exported <asm/ech.h> for extended context handling
Browse files Browse the repository at this point in the history
Add an exported header file <asm/ech.h> containing the definitions of
some bits which can be set in D0.8 to indicate to the kernel that
certain DSP state should be preserved. The definitions have the same
names and values as the ones in the kernel-internal <asm/tbx.h>, to
make it easier for DSP assembly code to be compatible between Linux and
non-Linux operating systems.

Signed-off-by: James Hogan <james.hogan@imgtec.com>
  • Loading branch information
James Hogan committed Mar 27, 2013
1 parent e605ff8 commit 82bbb83
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions arch/metag/include/uapi/asm/Kbuild
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
include include/uapi/asm-generic/Kbuild.asm

header-y += byteorder.h
header-y += ech.h
header-y += ptrace.h
header-y += resource.h
header-y += sigcontext.h
Expand Down
15 changes: 15 additions & 0 deletions arch/metag/include/uapi/asm/ech.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#ifndef _UAPI_METAG_ECH_H
#define _UAPI_METAG_ECH_H

/*
* These bits can be set in the top half of the D0.8 register when DSP context
* switching is enabled, in order to support partial DSP context save/restore.
*/

#define TBICTX_XEXT_BIT 0x1000 /* Enable extended context save */
#define TBICTX_XTDP_BIT 0x0800 /* DSP accumulators/RAM/templates */
#define TBICTX_XHL2_BIT 0x0400 /* Hardware loops */
#define TBICTX_XAXX_BIT 0x0200 /* Extended AX registers (A*.4-7) */
#define TBICTX_XDX8_BIT 0x0100 /* Extended DX registers (D*.8-15) */

#endif /* _UAPI_METAG_ECH_H */

0 comments on commit 82bbb83

Please sign in to comment.