Home | History | Annotate | Line # | Download | only in gemini
      1 /*	$NetBSD: gemini_lpchcvar.h,v 1.4 2011/07/01 19:32:28 dyoung Exp $	*/
      2 
      3 #ifndef  _ARM_GEMINI_LPHCVAR_H
      4 #define  _ARM_GEMINI_LPHCVAR_H
      5 
      6 #include <sys/types.h>
      7 #include <sys/device.h>
      8 #include <sys/bus.h>
      9 #include <arch/arm/gemini/gemini_lpcvar.h>
     10 
     11 
     12 typedef struct gemini_lpchc_attach_args {
     13 	void	       *lpchc_tag;
     14         bus_space_tag_t lpchc_iot;
     15         bus_addr_t      lpchc_addr;
     16         bus_size_t      lpchc_size;
     17 } gemini_lpchc_attach_args_t;
     18 
     19 typedef struct gemini_lpchc_intrq {
     20 	SIMPLEQ_ENTRY(gemini_lpchc_intrq) iq_q;
     21 	int (*iq_func)(void *);
     22 	void *iq_arg;
     23 	uint32_t iq_bit;
     24 	boolean_t iq_isedge;
     25 } gemini_lpchc_intrq_t;
     26 
     27 typedef struct gemini_lpchc_softc {
     28 	device_t sc_dev;
     29 	bus_addr_t sc_addr;
     30 	bus_size_t sc_size;
     31 	bus_space_tag_t sc_iot;
     32 	bus_space_handle_t sc_ioh;
     33 	int sc_intr;
     34 	void *sc_ih;
     35 	SIMPLEQ_HEAD(, gemini_lpchc_intrq) sc_intrq;
     36 } gemini_lpchc_softc_t;
     37 
     38 extern void gemini_lpchc_init(lpcintrtag_t);
     39 extern void *gemini_lpchc_intr_establish(lpcintrtag_t, uint, int, int,
     40         int (*)(void *), void *);
     41 extern void gemini_lpchc_intr_disestablish(lpcintrtag_t, void *);
     42 extern int  gemini_lpchc_intr(void *);
     43 
     44 
     45 
     46 #endif  /* _ARM_GEMINI_LPHCVAR_H */
     47