Changeset bf61d3a in mainline for kernel/generic/include
- Timestamp:
- 2010-11-26T01:34:21Z (15 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 273b958
- Parents:
- 4b9a410 (diff), 7e752b2 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - Location:
- kernel/generic/include
- Files:
-
- 9 edited
-
config.h (modified) (1 diff)
-
cpu.h (modified) (1 diff)
-
interrupt.h (modified) (2 diffs)
-
panic.h (modified) (2 diffs)
-
print.h (modified) (1 diff)
-
stdint.h (modified) (1 diff)
-
synch/spinlock.h (modified) (1 diff)
-
sysinfo/abi.h (modified) (1 diff)
-
typedefs.h (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/include/config.h
r4b9a410 rbf61d3a 66 66 67 67 typedef struct { 68 size_t cpu_count;/**< Number of processors detected. */68 unsigned int cpu_count; /**< Number of processors detected. */ 69 69 volatile size_t cpu_active; /**< Number of processors that are up and running. */ 70 70 -
kernel/generic/include/cpu.h
r4b9a410 rbf61d3a 83 83 * Processor ID assigned by kernel. 84 84 */ 85 size_t id;85 unsigned int id; 86 86 87 87 bool active; -
kernel/generic/include/interrupt.h
r4b9a410 rbf61d3a 37 37 38 38 #include <arch/interrupt.h> 39 #include <print.h> 39 40 #include <typedefs.h> 40 41 #include <proc/task.h> … … 57 58 extern exc_table_t exc_table[]; 58 59 59 extern void fault_if_from_uspace(istate_t *, const char *, ...); 60 extern void fault_if_from_uspace(istate_t *, const char *, ...) 61 PRINTF_ATTRIBUTE(2, 3); 60 62 extern iroutine_t exc_register(unsigned int, const char *, bool, iroutine_t); 61 63 extern void exc_dispatch(unsigned int, istate_t *); -
kernel/generic/include/panic.h
r4b9a410 rbf61d3a 37 37 38 38 #include <typedefs.h> 39 #include <print.h> 39 40 40 41 #define panic(fmt, ...) \ … … 62 63 63 64 extern void panic_common(panic_category_t, struct istate *, int, 64 uintptr_t, const char *, ...) __attribute__ ((noreturn)); 65 uintptr_t, const char *, ...) __attribute__ ((noreturn)) 66 PRINTF_ATTRIBUTE(5, 6); 65 67 66 68 #endif -
kernel/generic/include/print.h
r4b9a410 rbf61d3a 39 39 #include <stdarg.h> 40 40 41 #ifndef NVERIFY_PRINTF 42 43 #define PRINTF_ATTRIBUTE(start, end) \ 44 __attribute__((format(gnu_printf, start, end))) 45 46 #else /* NVERIFY_PRINTF */ 47 48 #define PRINTF_ATTRIBUTE(start, end) 49 50 #endif /* NVERIFY_PRINTF */ 51 41 52 #define EOF (-1) 42 53 43 54 extern int puts(const char *s); 44 extern int printf(const char *fmt, ...); 45 extern int snprintf(char *str, size_t size, const char *fmt, ...); 55 extern int printf(const char *fmt, ...) 56 PRINTF_ATTRIBUTE(1, 2); 57 extern int snprintf(char *str, size_t size, const char *fmt, ...) 58 PRINTF_ATTRIBUTE(3, 4); 46 59 47 60 extern int vprintf(const char *fmt, va_list ap); -
kernel/generic/include/stdint.h
r4b9a410 rbf61d3a 36 36 #define KERN_STDINT_H_ 37 37 38 #define INT8_MIN (0x80)39 #define INT8_MAX (0x7F)38 #define INT8_MIN INT8_C(0x80) 39 #define INT8_MAX INT8_C(0x7F) 40 40 41 #define UINT8_MIN (0u)42 #define UINT8_MAX (0xFFu)41 #define UINT8_MIN UINT8_C(0) 42 #define UINT8_MAX UINT8_C(0xFF) 43 43 44 #define INT16_MIN (0x8000)45 #define INT16_MAX (0x7FFF)44 #define INT16_MIN INT16_C(0x8000) 45 #define INT16_MAX INT16_C(0x7FFF) 46 46 47 #define UINT16_MIN (0u)48 #define UINT16_MAX (0xFFFFu)47 #define UINT16_MIN UINT16_C(0) 48 #define UINT16_MAX UINT16_C(0xFFFF) 49 49 50 #define INT32_MIN (0x80000000l)51 #define INT32_MAX (0x7FFFFFFFl)50 #define INT32_MIN INT32_C(0x80000000) 51 #define INT32_MAX INT32_C(0x7FFFFFFF) 52 52 53 #define UINT32_MIN (0ul)54 #define UINT32_MAX (0xFFFFFFFFul)53 #define UINT32_MIN UINT32_C(0) 54 #define UINT32_MAX UINT32_C(0xFFFFFFFF) 55 55 56 #define INT64_MIN (0x8000000000000000ll)57 #define INT64_MAX (0x7FFFFFFFFFFFFFFFll)56 #define INT64_MIN INT64_C(0x8000000000000000) 57 #define INT64_MAX INT64_C(0x7FFFFFFFFFFFFFFF) 58 58 59 #define UINT64_MIN (0ull)60 #define UINT64_MAX (0xFFFFFFFFFFFFFFFFull)59 #define UINT64_MIN UINT64_C(0) 60 #define UINT64_MAX UINT64_C(0xFFFFFFFFFFFFFFFF) 61 61 62 62 #endif -
kernel/generic/include/synch/spinlock.h
r4b9a410 rbf61d3a 146 146 if ((pname)++ > (value)) { \ 147 147 (pname) = 0; \ 148 printf("Deadlock probe %s: exceeded threshold %u\n" ,\148 printf("Deadlock probe %s: exceeded threshold %u\n" \ 149 149 "cpu%u: function=%s, line=%u\n", \ 150 150 #pname, (value), CPU->id, __func__, __LINE__); \ -
kernel/generic/include/sysinfo/abi.h
r4b9a410 rbf61d3a 66 66 */ 67 67 typedef struct { 68 size_t id;/**< CPU ID as stored by kernel */68 unsigned int id; /**< CPU ID as stored by kernel */ 69 69 bool active; /**< CPU is activate */ 70 70 uint16_t frequency_mhz; /**< Frequency in MHz */ -
kernel/generic/include/typedefs.h
r4b9a410 rbf61d3a 40 40 #include <arch/types.h> 41 41 42 #define NULL ((void *) 0)42 #define NULL ((void *) 0) 43 43 44 44 #define false 0 … … 69 69 typedef int32_t devno_t; 70 70 71 typedef int32_t wchar_t;72 73 71 typedef volatile uint8_t ioport8_t; 74 72 typedef volatile uint16_t ioport16_t;
Note:
See TracChangeset
for help on using the changeset viewer.
