CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
orangepi-xunlong

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.

GitHub Repository: orangepi-xunlong/orangepi-build
Path: blob/next/external/cache/sources/wl/include/hndrte_debug.h
Views: 3959
1
/*
2
* HND Run Time Environment debug info area
3
*
4
* $Copyright Open Broadcom Corporation$
5
*
6
* $Id: hndrte_debug.h 342211 2012-07-02 02:23:04Z $
7
*/
8
9
#ifndef _HNDRTE_DEBUG_H
10
#define _HNDRTE_DEBUG_H
11
12
/* Magic number at a magic location to find HNDRTE_DEBUG pointers */
13
#define HNDRTE_DEBUG_PTR_PTR_MAGIC 0x50504244 /* DBPP */
14
15
#ifndef _LANGUAGE_ASSEMBLY
16
17
/* Includes only when building dongle code */
18
19
20
#define NUM_EVENT_LOG_SETS 4
21
22
/* We use explicit sizes here since this gets included from different
23
* systems. The sizes must be the size of the creating system
24
* (currently 32 bit ARM) since this is gleaned from dump.
25
*/
26
27
/* Define pointers for use on other systems */
28
#define _HD_EVLOG_P uint32
29
#define _HD_CONS_P uint32
30
#define _HD_TRAP_P uint32
31
32
typedef struct hndrte_debug {
33
uint32 magic;
34
#define HNDRTE_DEBUG_MAGIC 0x47424544 /* 'DEBG' */
35
36
uint32 version; /* Debug struct version */
37
#define HNDRTE_DEBUG_VERSION 1
38
39
uint32 fwid; /* 4 bytes of fw info */
40
char epivers[32];
41
42
_HD_TRAP_P trap_ptr; /* trap_t data struct */
43
_HD_CONS_P console; /* Console */
44
45
uint32 ram_base;
46
uint32 ram_size;
47
48
uint32 rom_base;
49
uint32 rom_size;
50
51
_HD_EVLOG_P event_log_top;
52
53
} hndrte_debug_t;
54
55
/*
56
* timeval_t and prstatus_t are copies of the Linux structures.
57
* Included here because we need the definitions for the target processor
58
* (32 bits) and not the definition on the host this is running on
59
* (which could be 64 bits).
60
*/
61
62
typedef struct { /* Time value with microsecond resolution */
63
uint32 tv_sec; /* Seconds */
64
uint32 tv_usec; /* Microseconds */
65
} timeval_t;
66
67
68
/* Linux/ARM 32 prstatus for notes section */
69
typedef struct prstatus {
70
int32 si_signo; /* Signal number */
71
int32 si_code; /* Extra code */
72
int32 si_errno; /* Errno */
73
uint16 pr_cursig; /* Current signal. */
74
uint16 unused;
75
uint32 pr_sigpend; /* Set of pending signals. */
76
uint32 pr_sighold; /* Set of held signals. */
77
uint32 pr_pid;
78
uint32 pr_ppid;
79
uint32 pr_pgrp;
80
uint32 pr_sid;
81
timeval_t pr_utime; /* User time. */
82
timeval_t pr_stime; /* System time. */
83
timeval_t pr_cutime; /* Cumulative user time. */
84
timeval_t pr_cstime; /* Cumulative system time. */
85
uint32 uregs[18];
86
int32 pr_fpvalid; /* True if math copro being used. */
87
} prstatus_t;
88
89
#ifdef __GNUC__
90
extern hndrte_debug_t hndrte_debug_info __attribute__ ((weak));
91
#endif /* __GNUC__ */
92
93
#endif /* !LANGUAGE_ASSEMBLY */
94
95
#endif /* _HNDRTE_DEBUG_H */
96
97