1 /**************************************************************************/
2 /* File: pip.h - support for PIP5,PIP6,PIP7 and PIP8 boards for */
3 /* Packaged Industrial PCs supportof MPL AG, Switzerland */
5 /* LinCAN - (Not only) Linux CAN bus driver */
6 /* Copyright (C) 2002-2009 DCE FEE CTU Prague <http://dce.felk.cvut.cz> */
7 /* Copyright (C) 2002-2009 Pavel Pisa <pisa@cmp.felk.cvut.cz> */
8 /* Copyright (C) 2005-2006 Stefan Peter, MPL AG, Switzerland */
9 /* Funded by OCERA and FRESCOR IST projects */
10 /* Based on CAN driver code by Arnaud Westenberg <arnaud@wanadoo.nl> */
12 /* LinCAN is free software; you can redistribute it and/or modify it */
13 /* under terms of the GNU General Public License as published by the */
14 /* Free Software Foundation; either version 2, or (at your option) any */
15 /* later version. LinCAN is distributed in the hope that it will be */
16 /* useful, but WITHOUT ANY WARRANTY; without even the implied warranty */
17 /* of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU */
18 /* General Public License for more details. You should have received a */
19 /* copy of the GNU General Public License along with LinCAN; see file */
20 /* COPYING. If not, write to the Free Software Foundation, 675 Mass Ave, */
21 /* Cambridge, MA 02139, USA. */
23 /* To allow use of LinCAN in the compact embedded systems firmware */
24 /* and RT-executives (RTEMS for example), main authors agree with next */
25 /* special exception: */
27 /* Including LinCAN header files in a file, instantiating LinCAN generics */
28 /* or templates, or linking other files with LinCAN objects to produce */
29 /* an application image/executable, does not by itself cause the */
30 /* resulting application image/executable to be covered by */
31 /* the GNU General Public License. */
32 /* This exception does not however invalidate any other reasons */
33 /* why the executable file might be covered by the GNU Public License. */
34 /* Publication of enhanced or derived LinCAN files is required although. */
35 /**************************************************************************/
37 int pip_request_io(struct candevice_t *candev);
38 int pip_release_io(struct candevice_t *candev);
39 int pip_reset(struct candevice_t *candev);
40 int pip_init_hw_data(struct candevice_t *candev);
41 int pip_init_chip_data(struct candevice_t *candev, int chipnr);
42 int pip_init_obj_data(struct canchip_t *chip, int objnr);
43 void pip_write_register(unsigned data, can_ioptr_t address);
44 unsigned pip_read_register(can_ioptr_t address);
45 int pip_program_irq(struct candevice_t *candev);