diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2015-06-09 09:26:44 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2015-06-09 09:26:44 +0200 |
commit | 7a429bfb3b11a4af5ab0a328a22c354b3838a7a7 (patch) | |
tree | ba8f6854c8a267c1ea6a5a591456de52ca45e02e /include | |
parent | 760e652a7aca15c3ba67f3e7ad4488d49f7a629a (diff) | |
parent | 79eba3029f330682d9ba1f5d248720c761de14a7 (diff) | |
download | barebox-7a429bfb3b11a4af5ab0a328a22c354b3838a7a7.tar.gz barebox-7a429bfb3b11a4af5ab0a328a22c354b3838a7a7.tar.xz |
Merge branch 'for-next/misc'
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-generic/barebox.lds.h | 4 | ||||
-rw-r--r-- | include/crc.h | 2 | ||||
-rw-r--r-- | include/digest.h | 10 | ||||
-rw-r--r-- | include/init.h | 2 | ||||
-rw-r--r-- | include/io.h | 8 | ||||
-rw-r--r-- | include/watchdog.h | 17 |
6 files changed, 28 insertions, 15 deletions
diff --git a/include/asm-generic/barebox.lds.h b/include/asm-generic/barebox.lds.h index e359187d7f..254397ee97 100644 --- a/include/asm-generic/barebox.lds.h +++ b/include/asm-generic/barebox.lds.h @@ -34,7 +34,9 @@ KEEP(*(.initcall.9)) \ KEEP(*(.initcall.10)) \ KEEP(*(.initcall.11)) \ - KEEP(*(.initcall.12)) + KEEP(*(.initcall.12)) \ + KEEP(*(.initcall.13)) \ + KEEP(*(.initcall.14)) #define BAREBOX_CMDS KEEP(*(SORT_BY_NAME(.barebox_cmd*))) diff --git a/include/crc.h b/include/crc.h index 10560c9fa9..4290f41c57 100644 --- a/include/crc.h +++ b/include/crc.h @@ -95,6 +95,6 @@ cyg_ether_crc32_accumulate(uint32_t crc, unsigned char *s, int len); /* 16 bit CRC with polynomial x^16+x^12+x^5+1 */ -extern uint16_t cyg_crc16(unsigned char *s, int len); +extern uint16_t cyg_crc16(const unsigned char *s, int len); #endif /* _SERVICES_CRC_CRC_H_ */ diff --git a/include/digest.h b/include/digest.h index 7f8d696eb6..7c6711b32a 100644 --- a/include/digest.h +++ b/include/digest.h @@ -68,14 +68,14 @@ void digest_free(struct digest *d); int digest_file_window(struct digest *d, const char *filename, unsigned char *hash, - unsigned char *sig, + const unsigned char *sig, ulong start, ulong size); int digest_file(struct digest *d, const char *filename, - unsigned char *hash, - unsigned char *sig); + unsigned char *hash, + const unsigned char *sig); int digest_file_by_name(const char *algo, const char *filename, - unsigned char *hash, - unsigned char *sig); + unsigned char *hash, + const unsigned char *sig); static inline int digest_init(struct digest *d) { diff --git a/include/init.h b/include/init.h index 37c7eedf67..f619c951d3 100644 --- a/include/init.h +++ b/include/init.h @@ -39,6 +39,8 @@ typedef int (*initcall_t)(void); #define device_initcall(fn) __define_initcall("10",fn,10) #define crypto_initcall(fn) __define_initcall("11",fn,11) #define late_initcall(fn) __define_initcall("12",fn,12) +#define environment_initcall(fn) __define_initcall("13",fn,13) +#define postenvironment_initcall(fn) __define_initcall("14",fn,14) /* section for code used very early when * - we're not running from where we linked at diff --git a/include/io.h b/include/io.h index 8d885de68f..8eb56b061f 100644 --- a/include/io.h +++ b/include/io.h @@ -3,12 +3,4 @@ #include <asm/io.h> -/* cpu_read/cpu_write: cpu native io accessors */ -#define cpu_readb(a) __raw_readb(a) -#define cpu_readw(a) __raw_readw(a) -#define cpu_readl(a) __raw_readl(a) -#define cpu_writeb(v, a) __raw_writeb((v), (a)) -#define cpu_writew(v, a) __raw_writew((v), (a)) -#define cpu_writel(v, a) __raw_writel((v), (a)) - #endif /* __IO_H */ diff --git a/include/watchdog.h b/include/watchdog.h index 3e2d08e876..7e37b7c22a 100644 --- a/include/watchdog.h +++ b/include/watchdog.h @@ -17,8 +17,25 @@ struct watchdog { int (*set_timeout)(struct watchdog *, unsigned); }; +#ifdef CONFIG_WATCHDOG int watchdog_register(struct watchdog *); int watchdog_deregister(struct watchdog *); int watchdog_set_timeout(unsigned); +#else +static inline int watchdog_register(struct watchdog *w) +{ + return 0; +} + +int watchdog_deregister(struct watchdog *w) +{ + return 0; +} + +int watchdog_set_timeout(unsigned t) +{ + return 0; +} +#endif #endif /* INCLUDE_WATCHDOG_H */ |