RTEMS 6.1-rc6
Loading...
Searching...
No Matches
grclkgate-regs.h
Go to the documentation of this file.
1/* SPDX-License-Identifier: BSD-2-Clause */
2
11/*
12 * Copyright (C) 2021 embedded brains GmbH & Co. KG
13 *
14 * Redistribution and use in source and binary forms, with or without
15 * modification, are permitted provided that the following conditions
16 * are met:
17 * 1. Redistributions of source code must retain the above copyright
18 * notice, this list of conditions and the following disclaimer.
19 * 2. Redistributions in binary form must reproduce the above copyright
20 * notice, this list of conditions and the following disclaimer in the
21 * documentation and/or other materials provided with the distribution.
22 *
23 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
24 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
25 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
26 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
27 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
28 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
29 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
30 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
31 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
32 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
33 * POSSIBILITY OF SUCH DAMAGE.
34 */
35
36/*
37 * This file is part of the RTEMS quality process and was automatically
38 * generated. If you find something that needs to be fixed or
39 * worded better please post a report or patch to an RTEMS mailing list
40 * or raise a bug report:
41 *
42 * https://www.rtems.org/bugs.html
43 *
44 * For information on updating and regenerating please refer to the How-To
45 * section in the Software Requirements Engineering chapter of the
46 * RTEMS Software Engineering manual. The manual is provided as a part of
47 * a release. For development sources please refer to the online
48 * documentation at:
49 *
50 * https://docs.rtems.org
51 */
52
53/* Generated from spec:/dev/grlib/if/grclkgate-header */
54
55#ifndef _GRLIB_GRCLKGATE_REGS_H
56#define _GRLIB_GRCLKGATE_REGS_H
57
58#include <stdint.h>
59
60#ifdef __cplusplus
61extern "C" {
62#endif
63
64/* Generated from spec:/dev/grlib/if/grclkgate */
65
84#define GRCLKGATE_UNLOCK_UNLOCK_SHIFT 0
85#define GRCLKGATE_UNLOCK_UNLOCK_MASK 0xffffffffU
86#define GRCLKGATE_UNLOCK_UNLOCK_GET( _reg ) \
87 ( ( ( _reg ) & GRCLKGATE_UNLOCK_UNLOCK_MASK ) >> \
88 GRCLKGATE_UNLOCK_UNLOCK_SHIFT )
89#define GRCLKGATE_UNLOCK_UNLOCK_SET( _reg, _val ) \
90 ( ( ( _reg ) & ~GRCLKGATE_UNLOCK_UNLOCK_MASK ) | \
91 ( ( ( _val ) << GRCLKGATE_UNLOCK_UNLOCK_SHIFT ) & \
92 GRCLKGATE_UNLOCK_UNLOCK_MASK ) )
93#define GRCLKGATE_UNLOCK_UNLOCK( _val ) \
94 ( ( ( _val ) << GRCLKGATE_UNLOCK_UNLOCK_SHIFT ) & \
95 GRCLKGATE_UNLOCK_UNLOCK_MASK )
96
107#define GRCLKGATE_CLKEN_ENABLE_SHIFT 0
108#define GRCLKGATE_CLKEN_ENABLE_MASK 0xffffffffU
109#define GRCLKGATE_CLKEN_ENABLE_GET( _reg ) \
110 ( ( ( _reg ) & GRCLKGATE_CLKEN_ENABLE_MASK ) >> \
111 GRCLKGATE_CLKEN_ENABLE_SHIFT )
112#define GRCLKGATE_CLKEN_ENABLE_SET( _reg, _val ) \
113 ( ( ( _reg ) & ~GRCLKGATE_CLKEN_ENABLE_MASK ) | \
114 ( ( ( _val ) << GRCLKGATE_CLKEN_ENABLE_SHIFT ) & \
115 GRCLKGATE_CLKEN_ENABLE_MASK ) )
116#define GRCLKGATE_CLKEN_ENABLE( _val ) \
117 ( ( ( _val ) << GRCLKGATE_CLKEN_ENABLE_SHIFT ) & \
118 GRCLKGATE_CLKEN_ENABLE_MASK )
119
130#define GRCLKGATE_RESET_RESET_SHIFT 0
131#define GRCLKGATE_RESET_RESET_MASK 0xffffffffU
132#define GRCLKGATE_RESET_RESET_GET( _reg ) \
133 ( ( ( _reg ) & GRCLKGATE_RESET_RESET_MASK ) >> \
134 GRCLKGATE_RESET_RESET_SHIFT )
135#define GRCLKGATE_RESET_RESET_SET( _reg, _val ) \
136 ( ( ( _reg ) & ~GRCLKGATE_RESET_RESET_MASK ) | \
137 ( ( ( _val ) << GRCLKGATE_RESET_RESET_SHIFT ) & \
138 GRCLKGATE_RESET_RESET_MASK ) )
139#define GRCLKGATE_RESET_RESET( _val ) \
140 ( ( ( _val ) << GRCLKGATE_RESET_RESET_SHIFT ) & \
141 GRCLKGATE_RESET_RESET_MASK )
142
153#define GRCLKGATE_OVERRIDE_FOVERRIDE_SHIFT 16
154#define GRCLKGATE_OVERRIDE_FOVERRIDE_MASK 0xf0000U
155#define GRCLKGATE_OVERRIDE_FOVERRIDE_GET( _reg ) \
156 ( ( ( _reg ) & GRCLKGATE_OVERRIDE_FOVERRIDE_MASK ) >> \
157 GRCLKGATE_OVERRIDE_FOVERRIDE_SHIFT )
158#define GRCLKGATE_OVERRIDE_FOVERRIDE_SET( _reg, _val ) \
159 ( ( ( _reg ) & ~GRCLKGATE_OVERRIDE_FOVERRIDE_MASK ) | \
160 ( ( ( _val ) << GRCLKGATE_OVERRIDE_FOVERRIDE_SHIFT ) & \
161 GRCLKGATE_OVERRIDE_FOVERRIDE_MASK ) )
162#define GRCLKGATE_OVERRIDE_FOVERRIDE( _val ) \
163 ( ( ( _val ) << GRCLKGATE_OVERRIDE_FOVERRIDE_SHIFT ) & \
164 GRCLKGATE_OVERRIDE_FOVERRIDE_MASK )
165
166#define GRCLKGATE_OVERRIDE_OVERRIDE_SHIFT 0
167#define GRCLKGATE_OVERRIDE_OVERRIDE_MASK 0xfU
168#define GRCLKGATE_OVERRIDE_OVERRIDE_GET( _reg ) \
169 ( ( ( _reg ) & GRCLKGATE_OVERRIDE_OVERRIDE_MASK ) >> \
170 GRCLKGATE_OVERRIDE_OVERRIDE_SHIFT )
171#define GRCLKGATE_OVERRIDE_OVERRIDE_SET( _reg, _val ) \
172 ( ( ( _reg ) & ~GRCLKGATE_OVERRIDE_OVERRIDE_MASK ) | \
173 ( ( ( _val ) << GRCLKGATE_OVERRIDE_OVERRIDE_SHIFT ) & \
174 GRCLKGATE_OVERRIDE_OVERRIDE_MASK ) )
175#define GRCLKGATE_OVERRIDE_OVERRIDE( _val ) \
176 ( ( ( _val ) << GRCLKGATE_OVERRIDE_OVERRIDE_SHIFT ) & \
177 GRCLKGATE_OVERRIDE_OVERRIDE_MASK )
178
184typedef struct grclkgate {
188 uint32_t unlock;
189
193 uint32_t clken;
194
198 uint32_t reset;
199
203 uint32_t override;
205
208#ifdef __cplusplus
209}
210#endif
211
212#endif /* _GRLIB_GRCLKGATE_REGS_H */
This structure defines the GRCLKGATE register block memory map.
Definition: grclkgate-regs.h:184
uint32_t unlock
See Unlock register (UNLOCK).
Definition: grclkgate-regs.h:188
uint32_t clken
See Clock enable register (CLKEN).
Definition: grclkgate-regs.h:193
uint32_t reset
See Reset register (RESET).
Definition: grclkgate-regs.h:198