irq_user.h 761 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /*
  2. * Copyright (C) 2001 - 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com)
  3. * Licensed under the GPL
  4. */
  5. #ifndef __IRQ_USER_H__
  6. #define __IRQ_USER_H__
  7. #include <sysdep/ptrace.h>
  8. #include <stdbool.h>
  9. struct irq_fd {
  10. struct irq_fd *next;
  11. void *id;
  12. int fd;
  13. int type;
  14. int irq;
  15. int events;
  16. bool active;
  17. bool pending;
  18. bool purge;
  19. };
  20. #define IRQ_READ 0
  21. #define IRQ_WRITE 1
  22. #define IRQ_NONE 2
  23. #define MAX_IRQ_TYPE (IRQ_NONE + 1)
  24. struct siginfo;
  25. extern void sigio_handler(int sig, struct siginfo *unused_si, struct uml_pt_regs *regs);
  26. extern void free_irq_by_fd(int fd);
  27. extern void reactivate_fd(int fd, int irqnum);
  28. extern void deactivate_fd(int fd, int irqnum);
  29. extern int deactivate_all_fds(void);
  30. extern int activate_ipi(int fd, int pid);
  31. #endif