Home | History | Annotate | Line # | Download | only in ebus
ebusvar.h revision 1.1
      1  1.1  pooka /*	$NetBSD: ebusvar.h,v 1.1 2011/01/26 01:18:50 pooka Exp $	*/
      2  1.1  pooka 
      3  1.1  pooka #ifndef _EMIPS_EBUS_EBUSVAR_H_
      4  1.1  pooka #define _EMIPS_EBUS_EBUSVAR_H_
      5  1.1  pooka 
      6  1.1  pooka #include <machine/bus.h>
      7  1.1  pooka 
      8  1.1  pooka struct ebus_attach_args;
      9  1.1  pooka 
     10  1.1  pooka struct ebus_softc {
     11  1.1  pooka 	struct device	sc_dev;
     12  1.1  pooka };
     13  1.1  pooka 
     14  1.1  pooka /*
     15  1.1  pooka  * Arguments used to attach an ebus "device" to its parent
     16  1.1  pooka  */
     17  1.1  pooka struct ebus_dev_attach_args {
     18  1.1  pooka 	const char *ida_busname;		/* XXX should be common */
     19  1.1  pooka 	bus_space_tag_t	ida_memt;
     20  1.1  pooka 
     21  1.1  pooka 	int	ida_ndevs;
     22  1.1  pooka 	struct ebus_attach_args	*ida_devs;
     23  1.1  pooka };
     24  1.1  pooka 
     25  1.1  pooka /*
     26  1.1  pooka  * Arguments used to attach devices to an ebus
     27  1.1  pooka  */
     28  1.1  pooka struct ebus_attach_args {
     29  1.1  pooka 	const char *ia_name;         /* device name */
     30  1.1  pooka 	int	        ia_cookie;       /* device cookie */
     31  1.1  pooka 	u_int32_t   ia_paddr;        /* device address (PHYSICAL) */
     32  1.1  pooka     void       *ia_vaddr;        /* device address (VIRTUAL) */
     33  1.1  pooka 	int	        ia_basz;         /* device size (for min regset at probe, else 0) */
     34  1.1  pooka };
     35  1.1  pooka 
     36  1.1  pooka void	ebusattach (struct device *, struct device *, void *);
     37  1.1  pooka int	    ebusprint (void *, const char *);
     38  1.1  pooka void	ebus_intr_establish (struct device *, void * cookie, int level,
     39  1.1  pooka 	    int (*handler)(void *, void *), void *arg);
     40  1.1  pooka 
     41  1.1  pooka #endif	/* !_EMIPS_EBUS_EBUSVAR_H_ */
     42