aboutsummaryrefslogtreecommitdiff
path: root/include/asm-cris/arch-v32/hwregs/asm/strcop_defs_asm.h
blob: 55083e6aec93ff56ccd95ee36cdc86f25c23c88a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
#ifndef __strcop_defs_asm_h
#define __strcop_defs_asm_h

/*
 * This file is autogenerated from
 *   file:           ../../inst/strcop/rtl/strcop_regs.r
 *     id:           strcop_regs.r,v 1.5 2003/10/15 12:09:45 kriskn Exp
 *     last modfied: Mon Apr 11 16:09:38 2005
 *
 *   by /n/asic/design/tools/rdesc/src/rdes2c -asm --outfile asm/strcop_defs_asm.h ../../inst/strcop/rtl/strcop_regs.r
 *      id: $Id: strcop_defs_asm.h,v 1.1 2005/04/24 18:31:04 starvik Exp $
 * Any changes here will be lost.
 *
 * -*- buffer-read-only: t -*-
 */

#ifndef REG_FIELD
#define REG_FIELD( scope, reg, field, value ) \
  REG_FIELD_X_( value, reg_##scope##_##reg##___##field##___lsb )
#define REG_FIELD_X_( value, shift ) ((value) << shift)
#endif

#ifndef REG_STATE
#define REG_STATE( scope, reg, field, symbolic_value ) \
  REG_STATE_X_( regk_##scope##_##symbolic_value, reg_##scope##_##reg##___##field##___lsb )
#define REG_STATE_X_( k, shift ) (k << shift)
#endif

#ifndef REG_MASK
#define REG_MASK( scope, reg, field ) \
  REG_MASK_X_( reg_##scope##_##reg##___##field##___width, reg_##scope##_##reg##___##field##___lsb )
#define REG_MASK_X_( width, lsb ) (((1 << width)-1) << lsb)
#endif

#ifndef REG_LSB
#define REG_LSB( scope, reg, field ) reg_##scope##_##reg##___##field##___lsb
#endif

#ifndef REG_BIT
#define REG_BIT( scope, reg, field ) reg_##scope##_##reg##___##field##___bit
#endif

#ifndef REG_ADDR
#define REG_ADDR( scope, inst, reg ) REG_ADDR_X_(inst, reg_##scope##_##reg##_offset)
#define REG_ADDR_X_( inst, offs ) ((inst) + offs)
#endif

#ifndef REG_ADDR_VECT
#define REG_ADDR_VECT( scope, inst, reg, index ) \
         REG_ADDR_VECT_X_(inst, reg_##scope##_##reg##_offset, index, \
			 STRIDE_##scope##_##reg )
#define REG_ADDR_VECT_X_( inst, offs, index, stride ) \
                          ((inst) + offs + (index) * stride)
#endif

/* Register rw_cfg, scope strcop, type rw */
#define reg_strcop_rw_cfg___td3___lsb 0
#define reg_strcop_rw_cfg___td3___width 1
#define reg_strcop_rw_cfg___td3___bit 0
#define reg_strcop_rw_cfg___td2___lsb 1
#define reg_strcop_rw_cfg___td2___width 1
#define reg_strcop_rw_cfg___td2___bit 1
#define reg_strcop_rw_cfg___td1___lsb 2
#define reg_strcop_rw_cfg___td1___width 1
#define reg_strcop_rw_cfg___td1___bit 2
#define reg_strcop_rw_cfg___ipend___lsb 3
#define reg_strcop_rw_cfg___ipend___width 1
#define reg_strcop_rw_cfg___ipend___bit 3
#define reg_strcop_rw_cfg___ignore_sync___lsb 4
#define reg_strcop_rw_cfg___ignore_sync___width 1
#define reg_strcop_rw_cfg___ignore_sync___bit 4
#define reg_strcop_rw_cfg___en___lsb 5
#define reg_strcop_rw_cfg___en___width 1
#define reg_strcop_rw_cfg___en___bit 5
#define reg_strcop_rw_cfg_offset 0


/* Constants */
#define regk_strcop_big                           0x00000001
#define regk_strcop_d                             0x00000001
#define regk_strcop_e                             0x00000000
#define regk_strcop_little                        0x00000000
#define regk_strcop_rw_cfg_default                0x00000002
#endif /* __strcop_defs_asm_h */