Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-or-later */
0002 /*
0003  * altera.h
0004  *
0005  * altera FPGA driver
0006  *
0007  * Copyright (C) Altera Corporation 1998-2001
0008  * Copyright (C) 2010 NetUP Inc.
0009  * Copyright (C) 2010 Igor M. Liplianin <liplianin@netup.ru>
0010  */
0011 
0012 #ifndef _ALTERA_H_
0013 #define _ALTERA_H_
0014 
0015 struct altera_config {
0016     void *dev;
0017     u8 *action;
0018     int (*jtag_io) (void *dev, int tms, int tdi, int tdo);
0019 };
0020 
0021 #if defined(CONFIG_ALTERA_STAPL) || \
0022         (defined(CONFIG_ALTERA_STAPL_MODULE) && defined(MODULE))
0023 
0024 extern int altera_init(struct altera_config *config, const struct firmware *fw);
0025 #else
0026 
0027 static inline int altera_init(struct altera_config *config,
0028                         const struct firmware *fw)
0029 {
0030     printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
0031     return 0;
0032 }
0033 #endif /* CONFIG_ALTERA_STAPL */
0034 
0035 #endif /* _ALTERA_H_ */