Skip to content

Commit 77844b7

Browse files
GorrayLiRbb666
authored andcommitted
Align annotations of struct fields.
1 parent 3afefd7 commit 77844b7

File tree

1 file changed

+84
-84
lines changed

1 file changed

+84
-84
lines changed

components/lwp/lwp.h

Lines changed: 84 additions & 84 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,8 @@ extern "C" {
6868
*/
6969
struct rt_lwp_objs
7070
{
71-
rt_aspace_t source; /**< The address space associated with this LWP */
72-
struct rt_mem_obj mem_obj; /**< The memory object containing memory management information */
71+
rt_aspace_t source; /**< The address space associated with this LWP */
72+
struct rt_mem_obj mem_obj; /**< The memory object containing memory management information */
7373
};
7474

7575
/**
@@ -83,8 +83,8 @@ struct rt_lwp_notify
8383
* @param signo Signal number
8484
*/
8585
void (*notify)(rt_wqueue_t *signalfd_queue, int signo);
86-
rt_wqueue_t *signalfd_queue; /**< Wait queue for signal file descriptors */
87-
rt_slist_t list_node; /**< List node for notification */
86+
rt_wqueue_t *signalfd_queue; /**< Wait queue for signal file descriptors */
87+
rt_slist_t list_node; /**< List node for notification */
8888
};
8989

9090
struct lwp_tty;
@@ -108,31 +108,31 @@ typedef struct rt_processgroup *rt_processgroup_t;
108108
*/
109109
struct rt_session {
110110
struct rt_object object;
111-
rt_lwp_t leader; /**< Session leader process */
112-
rt_list_t processgroup; /**< List head of process groups in this session */
113-
pid_t sid; /**< Session ID */
111+
rt_lwp_t leader; /**< Session leader process */
112+
rt_list_t processgroup; /**< List head of process groups in this session */
113+
pid_t sid; /**< Session ID */
114114
pid_t foreground_pgid; /**< Foreground process group ID */
115-
struct rt_mutex mutex; /**< Mutex for session operations synchronization */
116-
struct lwp_tty *ctty; /**< Control terminal */
115+
struct rt_mutex mutex; /**< Mutex for session operations synchronization */
116+
struct lwp_tty *ctty; /**< Control terminal */
117117
};
118118

119119
/**
120120
* @brief Process group control structure
121121
*/
122122
struct rt_processgroup {
123123
struct rt_object object;
124-
rt_lwp_t leader; /**< Process group leader process */
125-
rt_list_t process; /**< List head of processes in this process group */
124+
rt_lwp_t leader; /**< Process group leader process */
125+
rt_list_t process; /**< List head of processes in this process group */
126126
rt_list_t pgrp_list_node; /**< List node for process group */
127-
pid_t pgid; /**< Process group ID */
128-
pid_t sid; /**< Session ID */
129-
struct rt_session *session; /**< Session pointer */
130-
struct rt_mutex mutex; /**< Mutex for process group operations synchronization */
127+
pid_t pgid; /**< Process group ID */
128+
pid_t sid; /**< Session ID */
129+
struct rt_session *session; /**< Session pointer */
130+
struct rt_mutex mutex; /**< Mutex for process group operations synchronization */
131131

132-
rt_atomic_t ref; /**< Reference count for process group */
132+
rt_atomic_t ref; /**< Reference count for process group */
133133

134134
/* flags on process group */
135-
unsigned int is_orphaned:1; /**< Whether the process group is orphaned */
135+
unsigned int is_orphaned:1; /**< Whether the process group is orphaned */
136136
};
137137

138138
/**
@@ -141,85 +141,85 @@ struct rt_processgroup {
141141
struct rt_lwp
142142
{
143143
#ifdef ARCH_MM_MMU
144-
size_t end_heap; /**< End address of heap */
145-
rt_aspace_t aspace; /**< Address space associated with this LWP */
144+
size_t end_heap; /**< End address of heap */
145+
rt_aspace_t aspace; /**< Address space associated with this LWP */
146146
#else
147147
#ifdef ARCH_MM_MPU
148-
struct rt_mpu_info mpu_info; /**< MPU information for this LWP */
148+
struct rt_mpu_info mpu_info; /**< MPU information for this LWP */
149149
#endif /* ARCH_MM_MPU */
150150
#endif /* ARCH_MM_MMU */
151151

152152
#ifdef RT_USING_SMP
153-
int bind_cpu; /**< CPU ID to which the LWP is bound */
153+
int bind_cpu; /**< CPU ID to which the LWP is bound */
154154
#endif
155155

156-
uint8_t lwp_type; /**< Type of LWP */
156+
uint8_t lwp_type; /**< Type of LWP */
157157
uint8_t reserv[3];
158158

159159
/* flags */
160-
unsigned int terminated:1; /**< Process termination flag */
161-
unsigned int background:1; /**< Background process flag */
162-
unsigned int term_ctrlterm:1; /**< have control terminal? */
163-
unsigned int did_exec:1; /**< Whether exec has been performed */
164-
unsigned int jobctl_stopped:1; /**< job control: current proc is stopped */
165-
unsigned int wait_reap_stp:1; /**< job control: has wait event for parent */
166-
unsigned int sig_protected:1; /**< signal: protected proc cannot be killed or stopped */
167-
168-
struct rt_lwp *parent; /**< parent process */
169-
struct rt_lwp *first_child; /**< first child process */
170-
struct rt_lwp *sibling; /**< sibling(child) process */
171-
172-
struct rt_wqueue waitpid_waiters; /**< Wait queue for waitpid system call */
173-
lwp_status_t lwp_status; /**< Status of LWP */
174-
175-
void *text_entry; /**< Entry point of text segment */
176-
uint32_t text_size; /**< Size of text segment */
177-
void *data_entry; /**< Entry point of data segment */
178-
uint32_t data_size; /**< Size of data segment */
179-
180-
rt_atomic_t ref; /**< Reference count for LWP */
181-
void *args; /**< Arguments passed to LWP */
182-
uint32_t args_length; /**< Length of arguments */
183-
pid_t pid; /**< Process ID */
184-
pid_t sid; /**< session ID */
185-
pid_t pgid; /**< process group ID */
186-
struct rt_processgroup *pgrp;
187-
rt_list_t pgrp_node; /**< process group node */
188-
rt_list_t t_grp; /**< thread group */
189-
rt_list_t timer; /**< POSIX timer object binding to a process */
190-
191-
struct dfs_fdtable fdt; /**< File descriptor table */
192-
char cmd[RT_NAME_MAX]; /**< process name */
193-
char *exe_file; /**< process file path */
160+
unsigned int terminated:1; /**< Process termination flag */
161+
unsigned int background:1; /**< Background process flag */
162+
unsigned int term_ctrlterm:1; /**< have control terminal? */
163+
unsigned int did_exec:1; /**< Whether exec has been performed */
164+
unsigned int jobctl_stopped:1; /**< job control: current proc is stopped */
165+
unsigned int wait_reap_stp:1; /**< job control: has wait event for parent */
166+
unsigned int sig_protected:1; /**< signal: protected proc cannot be killed or stopped */
167+
168+
struct rt_lwp *parent; /**< parent process */
169+
struct rt_lwp *first_child; /**< first child process */
170+
struct rt_lwp *sibling; /**< sibling(child) process */
171+
172+
struct rt_wqueue waitpid_waiters; /**< Wait queue for waitpid system call */
173+
lwp_status_t lwp_status; /**< Status of LWP */
174+
175+
void *text_entry; /**< Entry point of text segment */
176+
uint32_t text_size; /**< Size of text segment */
177+
void *data_entry; /**< Entry point of data segment */
178+
uint32_t data_size; /**< Size of data segment */
179+
180+
rt_atomic_t ref; /**< Reference count for LWP */
181+
void *args; /**< Arguments passed to LWP */
182+
uint32_t args_length; /**< Length of arguments */
183+
pid_t pid; /**< Process ID */
184+
pid_t sid; /**< session ID */
185+
pid_t pgid; /**< process group ID */
186+
struct rt_processgroup *pgrp; /**< process group */
187+
rt_list_t pgrp_node; /**< process group node */
188+
rt_list_t t_grp; /**< thread group */
189+
rt_list_t timer; /**< POSIX timer object binding to a process */
190+
191+
struct dfs_fdtable fdt; /**< File descriptor table */
192+
char cmd[RT_NAME_MAX]; /**< process name */
193+
char *exe_file; /**< process file path */
194194

195195
/* POSIX signal */
196-
struct lwp_signal signal; /**< Signal handling structure */
196+
struct lwp_signal signal; /**< Signal handling structure */
197197

198-
struct lwp_avl_struct *object_root; /**< AVL tree root for objects */
199-
struct rt_mutex object_mutex; /**< Mutex for object operations synchronization */
200-
struct rt_user_context user_ctx; /**< User context for LWP */
198+
struct lwp_avl_struct *object_root; /**< AVL tree root for objects */
199+
struct rt_mutex object_mutex; /**< Mutex for object operations synchronization */
200+
struct rt_user_context user_ctx; /**< User context for LWP */
201201

202-
struct rt_wqueue wait_queue; /**< wait queue for console */
203-
struct tty_struct *tty; /**< Controlling terminal, NULL if no tty */
202+
struct rt_wqueue wait_queue; /**< wait queue for console */
203+
struct tty_struct *tty; /**< Controlling terminal, NULL if no tty */
204204

205205
struct lwp_avl_struct *address_search_head; /**< for addressed object fast search */
206-
char working_directory[DFS_PATH_MAX]; /**< Current working directory */
206+
char working_directory[DFS_PATH_MAX]; /**< Current working directory */
207207

208-
int debug; /**< Debug flag */
209-
rt_uint32_t bak_first_inst; /**< backup of first instruction */
208+
int debug; /**< Debug flag */
209+
rt_uint32_t bak_first_inst; /**< backup of first instruction */
210210

211-
struct rt_mutex lwp_lock; /**< Mutex for LWP operations synchronization */
211+
struct rt_mutex lwp_lock; /**< Mutex for LWP operations synchronization */
212212

213-
rt_slist_t signalfd_notify_head; /**< Signal file descriptor notification head */
213+
rt_slist_t signalfd_notify_head; /**< Signal file descriptor notification head */
214214

215215
#ifdef LWP_ENABLE_ASID
216-
uint64_t generation; /**< ASID generation */
217-
unsigned int asid; /**< Address space ID */
216+
uint64_t generation; /**< ASID generation */
217+
unsigned int asid; /**< Address space ID */
218218
#endif
219-
struct rusage rt_rusage; /**< Resource usage information */
219+
struct rusage rt_rusage; /**< Resource usage information */
220220

221221
#ifdef RT_USING_VDSO
222-
void *vdso_vbase; /**< VDSO base address */
222+
void *vdso_vbase; /**< VDSO base address */
223223
#endif
224224
};
225225

@@ -233,9 +233,9 @@ rt_err_t lwp_children_unregister(struct rt_lwp *parent, struct rt_lwp *child);
233233
*/
234234
enum lwp_exit_request_type
235235
{
236-
LWP_EXIT_REQUEST_NONE = 0, /**< No exit request */
237-
LWP_EXIT_REQUEST_TRIGGERED, /**< Exit request triggered */
238-
LWP_EXIT_REQUEST_IN_PROCESS, /**< Exit request in process */
236+
LWP_EXIT_REQUEST_NONE = 0, /**< No exit request */
237+
LWP_EXIT_REQUEST_TRIGGERED, /**< Exit request triggered */
238+
LWP_EXIT_REQUEST_IN_PROCESS, /**< Exit request in process */
239239
};
240240
struct termios *get_old_termios(void);
241241
void lwp_setcwd(char *buf);
@@ -409,8 +409,8 @@ sysret_t lwp_teardown(struct rt_lwp *lwp, void (*cb)(void));
409409
*/
410410
struct process_aux_item
411411
{
412-
size_t key; /**< Auxiliary vector key */
413-
size_t value; /**< Auxiliary vector value */
412+
size_t key; /**< Auxiliary vector key */
413+
size_t value; /**< Auxiliary vector value */
414414
};
415415

416416
/**
@@ -426,15 +426,15 @@ struct process_aux
426426
*/
427427
struct dbg_ops_t
428428
{
429-
int (*dbg)(int argc, char **argv); /**< Debug function */
430-
uint32_t (*arch_get_ins)(void); /**< Architecture-specific instruction getter */
431-
void (*arch_activate_step)(void); /**< Architecture-specific step activation */
432-
void (*arch_deactivate_step)(void); /**< Architecture-specific step deactivation */
429+
int (*dbg)(int argc, char **argv); /**< Debug function */
430+
uint32_t (*arch_get_ins)(void); /**< Architecture-specific instruction getter */
431+
void (*arch_activate_step)(void); /**< Architecture-specific step activation */
432+
void (*arch_deactivate_step)(void); /**< Architecture-specific step deactivation */
433433
int (*check_debug_event)(struct rt_hw_exp_stack *regs, unsigned long esr); /**< Debug event checker */
434-
rt_channel_t (*gdb_get_server_channel)(void); /**< GDB server channel getter */
435-
int (*gdb_get_step_type)(void); /**< GDB step type getter */
436-
void (*lwp_check_debug_attach_req)(void *pc); /**< LWP debug attach request checker */
437-
int (*lwp_check_debug_suspend)(void); /**< LWP debug suspend checker */
434+
rt_channel_t (*gdb_get_server_channel)(void); /**< GDB server channel getter */
435+
int (*gdb_get_step_type)(void); /**< GDB step type getter */
436+
void (*lwp_check_debug_attach_req)(void *pc); /**< LWP debug attach request checker */
437+
int (*lwp_check_debug_suspend)(void); /**< LWP debug suspend checker */
438438
};
439439
extern struct dbg_ops_t *rt_dbg_ops;
440440

0 commit comments

Comments
 (0)