machvec.h 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. /*
  2. * include/asm-sh/machvec.h
  3. *
  4. * Copyright 2000 Stuart Menefy (stuart.menefy@st.com)
  5. *
  6. * May be copied or modified under the terms of the GNU General Public
  7. * License. See linux/COPYING for more information.
  8. */
  9. #ifndef _ASM_SH_MACHVEC_H
  10. #define _ASM_SH_MACHVEC_H 1
  11. #include <linux/types.h>
  12. #include <linux/time.h>
  13. #include <asm/machtypes.h>
  14. #include <asm/machvec_init.h>
  15. struct device;
  16. struct sh_machine_vector {
  17. int mv_nr_irqs;
  18. u8 (*mv_inb)(unsigned long);
  19. u16 (*mv_inw)(unsigned long);
  20. u32 (*mv_inl)(unsigned long);
  21. void (*mv_outb)(u8, unsigned long);
  22. void (*mv_outw)(u16, unsigned long);
  23. void (*mv_outl)(u32, unsigned long);
  24. u8 (*mv_inb_p)(unsigned long);
  25. u16 (*mv_inw_p)(unsigned long);
  26. u32 (*mv_inl_p)(unsigned long);
  27. void (*mv_outb_p)(u8, unsigned long);
  28. void (*mv_outw_p)(u16, unsigned long);
  29. void (*mv_outl_p)(u32, unsigned long);
  30. void (*mv_insb)(unsigned long, void *dst, unsigned long count);
  31. void (*mv_insw)(unsigned long, void *dst, unsigned long count);
  32. void (*mv_insl)(unsigned long, void *dst, unsigned long count);
  33. void (*mv_outsb)(unsigned long, const void *src, unsigned long count);
  34. void (*mv_outsw)(unsigned long, const void *src, unsigned long count);
  35. void (*mv_outsl)(unsigned long, const void *src, unsigned long count);
  36. u8 (*mv_readb)(void __iomem *);
  37. u16 (*mv_readw)(void __iomem *);
  38. u32 (*mv_readl)(void __iomem *);
  39. void (*mv_writeb)(u8, void __iomem *);
  40. void (*mv_writew)(u16, void __iomem *);
  41. void (*mv_writel)(u32, void __iomem *);
  42. int (*mv_irq_demux)(int irq);
  43. void (*mv_init_irq)(void);
  44. void (*mv_init_pci)(void);
  45. void (*mv_heartbeat)(void);
  46. void *(*mv_consistent_alloc)(struct device *, size_t, dma_addr_t *, gfp_t);
  47. int (*mv_consistent_free)(struct device *, size_t, void *, dma_addr_t);
  48. void __iomem *(*mv_ioport_map)(unsigned long port, unsigned int size);
  49. void (*mv_ioport_unmap)(void __iomem *);
  50. };
  51. extern struct sh_machine_vector sh_mv;
  52. #endif /* _ASM_SH_MACHVEC_H */