netjet.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * NETjet common header file
  4. *
  5. * Author Karsten Keil
  6. * based on work of Matt Henderson and Daniel Potts,
  7. * Traverse Technologies P/L www.traverse.com.au
  8. *
  9. * Copyright 2009 by Karsten Keil <[email protected]>
  10. */
  11. #define NJ_CTRL 0x00
  12. #define NJ_DMACTRL 0x01
  13. #define NJ_AUXCTRL 0x02
  14. #define NJ_AUXDATA 0x03
  15. #define NJ_IRQMASK0 0x04
  16. #define NJ_IRQMASK1 0x05
  17. #define NJ_IRQSTAT0 0x06
  18. #define NJ_IRQSTAT1 0x07
  19. #define NJ_DMA_READ_START 0x08
  20. #define NJ_DMA_READ_IRQ 0x0c
  21. #define NJ_DMA_READ_END 0x10
  22. #define NJ_DMA_READ_ADR 0x14
  23. #define NJ_DMA_WRITE_START 0x18
  24. #define NJ_DMA_WRITE_IRQ 0x1c
  25. #define NJ_DMA_WRITE_END 0x20
  26. #define NJ_DMA_WRITE_ADR 0x24
  27. #define NJ_PULSE_CNT 0x28
  28. #define NJ_ISAC_OFF 0xc0
  29. #define NJ_ISACIRQ 0x10
  30. #define NJ_IRQM0_RD_MASK 0x03
  31. #define NJ_IRQM0_RD_IRQ 0x01
  32. #define NJ_IRQM0_RD_END 0x02
  33. #define NJ_IRQM0_WR_MASK 0x0c
  34. #define NJ_IRQM0_WR_IRQ 0x04
  35. #define NJ_IRQM0_WR_END 0x08
  36. /* one page here is no need to be smaller */
  37. #define NJ_DMA_SIZE 4096
  38. /* 2 * 64 byte is a compromise between IRQ count and latency */
  39. #define NJ_DMA_RXSIZE 128 /* 2 * 64 */
  40. #define NJ_DMA_TXSIZE 128 /* 2 * 64 */