2 * This program is free software; you can redistribute it and/or modify it
3 * under the terms of the GNU General Public License as published by the
4 * Free Software Foundation; either version 2 of the License, or (at your
5 * option) any later version.
8 #ifndef __BCM47XX_NVRAM_H
9 #define __BCM47XX_NVRAM_H
11 #include <linux/errno.h>
12 #include <linux/types.h>
13 #include <linux/kernel.h>
14 #include <linux/vmalloc.h>
16 #ifdef CONFIG_BCM47XX_NVRAM
17 int bcm47xx_nvram_init_from_mem(u32 base
, u32 lim
);
18 int bcm47xx_nvram_getenv(const char *name
, char *val
, size_t val_len
);
19 int bcm47xx_nvram_gpio_pin(const char *name
);
20 char *bcm47xx_nvram_get_contents(size_t *val_len
);
21 static inline void bcm47xx_nvram_release_contents(char *nvram
)
26 static inline int bcm47xx_nvram_init_from_mem(u32 base
, u32 lim
)
30 static inline int bcm47xx_nvram_getenv(const char *name
, char *val
,
35 static inline int bcm47xx_nvram_gpio_pin(const char *name
)
40 static inline char *bcm47xx_nvram_get_contents(size_t *val_len
)
45 static inline void bcm47xx_nvram_release_contents(char *nvram
)
50 #endif /* __BCM47XX_NVRAM_H */