1#ifndef __EXPORTS_H__ 2#define __EXPORTS_H__ 3 4#include <irq_func.h> 5#include <asm/global_data.h> 6#include <linux/delay.h> 7 8#ifndef __ASSEMBLY__ 9#ifdef CONFIG_PHY_AQUANTIA 10#include <env.h> 11#include <phy_interface.h> 12#endif 13 14#include <irq_func.h> 15 16struct cmd_tbl; 17struct spi_slave; 18 19/** 20 * jumptable_init() - Set up the jump table for use by the API 21 * 22 * It is called during the generic post-relocation init sequence. 23 * 24 * Return: 0 if OK 25 */ 26int jumptable_init(void); 27 28/* These are declarations of exported functions available in C code */ 29unsigned long get_version(void); 30int getc(void); 31int tstc(void); 32void putc(const char); 33void puts(const char*); 34int printf(const char* fmt, ...); 35void install_hdlr(int, interrupt_handler_t, void*); 36void free_hdlr(int); 37void *malloc(size_t); 38#if !CONFIG_IS_ENABLED(SYS_MALLOC_SIMPLE) 39void free(void*); 40#endif 41void __udelay(unsigned long); 42unsigned long get_timer(unsigned long); 43int vprintf(const char *, va_list); 44unsigned long simple_strtoul(const char *cp, char **endp, unsigned int base); 45int strict_strtoul(const char *cp, unsigned int base, unsigned long *res); 46char *env_get(const char *name); 47int env_set(const char *varname, const char *value); 48long simple_strtol(const char *cp, char **endp, unsigned int base); 49int strcmp(const char *cs, const char *ct); 50unsigned long ustrtoul(const char *cp, char **endp, unsigned int base); 51unsigned long long ustrtoull(const char *cp, char **endp, unsigned int base); 52#if defined(CONFIG_CMD_I2C) && !CONFIG_IS_ENABLED(DM_I2C) 53int i2c_write (uchar, uint, int , uchar* , int); 54int i2c_read (uchar, uint, int , uchar* , int); 55#endif 56#ifdef CONFIG_PHY_AQUANTIA 57struct mii_dev *mdio_get_current_dev(void); 58struct phy_device *phy_find_by_mask(struct mii_dev *bus, unsigned phy_mask); 59struct phy_device *mdio_phydev_for_ethname(const char *ethname); 60int miiphy_set_current_dev(const char *devname); 61#endif 62 63void app_startup(char * const *); 64 65#endif /* ifndef __ASSEMBLY__ */ 66 67struct jt_funcs { 68#define EXPORT_FUNC(impl, res, func, ...) res(*func)(__VA_ARGS__); 69#include <_exports.h> 70#undef EXPORT_FUNC 71}; 72 73 74#define XF_VERSION 9 75 76#if defined(CONFIG_X86) 77extern gd_t *global_data; 78#endif 79 80#endif /* __EXPORTS_H__ */ 81