Lines Matching +full:c +full:- +full:define +full:- +full:name

1 /* SPDX-License-Identifier: GPL-2.0 */
4 * (c) 1999, Rt-Control, Inc.
8 #define __BOOTSTD_H__
10 #define NR_BSC 21 /* last used bootloader system call */
12 #define __BN_reset 0 /* reset and start the bootloader */
13 #define __BN_test 1 /* tests the system call interface */
14 #define __BN_exec 2 /* executes a bootloader image */
15 #define __BN_exit 3 /* terminates a bootloader image */
16 #define __BN_program 4 /* program FLASH from a chain */
17 #define __BN_erase 5 /* erase sector(s) of FLASH */
18 #define __BN_open 6
19 #define __BN_write 7
20 #define __BN_read 8
21 #define __BN_close 9
22 #define __BN_mmap 10 /* map a file descriptor into memory */
23 #define __BN_munmap 11 /* remove a file to memory mapping */
24 #define __BN_gethwaddr 12 /* get the hardware address of my interfaces */
25 #define __BN_getserialnum 13 /* get the serial number of this board */
26 #define __BN_getbenv 14 /* get a bootloader envvar */
27 #define __BN_setbenv 15 /* get a bootloader envvar */
28 #define __BN_setpmask 16 /* set the protection mask */
29 #define __BN_readenv 17 /* read environment variables */
30 #define __BN_flash_chattr_range 18
31 #define __BN_flash_erase_range 19
32 #define __BN_flash_write_range 20
38 #define __bsc_return(type, res) \
40 if ((unsigned long)(res) >= (unsigned long)(-64)) { \
42 int __err = -(res); \
44 res = -1; \
49 #define _bsc0(type,name) \ argument
50 type name(void) \
52 register long __res __asm__ ("%d0") = __BN_##name; \
60 #define _bsc1(type,name,atype,a) \ argument
61 type name(atype a) \
63 register long __res __asm__ ("%d0") = __BN_##name; \
72 #define _bsc2(type,name,atype,a,btype,b) \ argument
73 type name(atype a, btype b) \
75 register long __res __asm__ ("%d0") = __BN_##name; \
85 #define _bsc3(type,name,atype,a,btype,b,ctype,c) \ argument
86 type name(atype a, btype b, ctype c) \
88 register long __res __asm__ ("%d0") = __BN_##name; \
91 register long __c __asm__ ("%d3") = (long)c; \
100 #define _bsc4(type,name,atype,a,btype,b,ctype,c,dtype,d) \ argument
101 type name(atype a, btype b, ctype c, dtype d) \
103 register long __res __asm__ ("%d0") = __BN_##name; \
106 register long __c __asm__ ("%d3") = (long)c; \
116 #define _bsc5(type,name,atype,a,btype,b,ctype,c,dtype,d,etype,e) \ argument
117 type name(atype a, btype b, ctype c, dtype d, etype e) \
119 register long __res __asm__ ("%d0") = __BN_##name; \
122 register long __c __asm__ ("%d3") = (long)c; \