abyss.h 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. /*
  2. * abyss.h: Header for the abyss tms380tr module
  3. *
  4. * Authors:
  5. * - Adam Fritzler
  6. */
  7. #ifndef __LINUX_MADGETR_H
  8. #define __LINUX_MADGETR_H
  9. #ifdef __KERNEL__
  10. /*
  11. * For Madge Smart 16/4 PCI Mk2. Since we increment the base address
  12. * to get everything correct for the TMS SIF, we do these as negatives
  13. * as they fall below the SIF in addressing.
  14. */
  15. #define PCIBM2_INT_STATUS_REG ((short)-15)/* 0x01 */
  16. #define PCIBM2_INT_CONTROL_REG ((short)-14)/* 0x02 */
  17. #define PCIBM2_RESET_REG ((short)-12)/* 0x04 */
  18. #define PCIBM2_SEEPROM_REG ((short)-9) /* 0x07 */
  19. #define PCIBM2_INT_CONTROL_REG_SINTEN 0x02
  20. #define PCIBM2_INT_CONTROL_REG_PCI_ERR_ENABLE 0x80
  21. #define PCIBM2_INT_STATUS_REG_PCI_ERR 0x80
  22. #define PCIBM2_RESET_REG_CHIP_NRES 0x01
  23. #define PCIBM2_RESET_REG_FIFO_NRES 0x02
  24. #define PCIBM2_RESET_REG_SIF_NRES 0x04
  25. #define PCIBM2_FIFO_THRESHOLD 0x21
  26. #define PCIBM2_BURST_LENGTH 0x22
  27. /*
  28. * Bits in PCIBM2_SEEPROM_REG.
  29. */
  30. #define AT24_ENABLE 0x04
  31. #define AT24_DATA 0x02
  32. #define AT24_CLOCK 0x01
  33. /*
  34. * AT24 Commands.
  35. */
  36. #define AT24_WRITE 0xA0
  37. #define AT24_READ 0xA1
  38. /*
  39. * Addresses in AT24 SEEPROM.
  40. */
  41. #define PCIBM2_SEEPROM_BIA 0x12
  42. #define PCIBM2_SEEPROM_RING_SPEED 0x18
  43. #define PCIBM2_SEEPROM_RAM_SIZE 0x1A
  44. #define PCIBM2_SEEPROM_HWF1 0x1C
  45. #define PCIBM2_SEEPROM_HWF2 0x1E
  46. #endif /* __KERNEL__ */
  47. #endif /* __LINUX_MADGETR_H */