1 /* SPDX-License-Identifier: GPL-2.0+ */
4 * Stefan Roese, DENX Software Engineering, sr@denx.de.
9 #include <asm/byteorder.h>
11 #if !defined(CONFIG_SYS_BOOTCOUNT_LE) && !defined(CONFIG_SYS_BOOTCOUNT_BE)
12 # if __BYTE_ORDER == __LITTLE_ENDIAN
13 # define CONFIG_SYS_BOOTCOUNT_LE
15 # define CONFIG_SYS_BOOTCOUNT_BE
19 #ifdef CONFIG_SYS_BOOTCOUNT_LE
20 static inline void raw_bootcount_store(volatile u32 *addr, u32 data)
25 static inline u32 raw_bootcount_load(volatile u32 *addr)
30 static inline void raw_bootcount_store(volatile u32 *addr, u32 data)
35 static inline u32 raw_bootcount_load(volatile u32 *addr)