ohare.h 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /*
  2. * ohare.h: definitions for using the "O'Hare" I/O controller chip.
  3. *
  4. * Copyright (C) 1997 Paul Mackerras.
  5. *
  6. * BenH: Changed to match those of heathrow (but not all of them). Please
  7. * check if I didn't break anything (especially the media bay).
  8. */
  9. /* offset from ohare base for feature control register */
  10. #define OHARE_MBCR 0x34
  11. #define OHARE_FCR 0x38
  12. /*
  13. * Bits in feature control register.
  14. * These were mostly derived by experiment on a powerbook 3400
  15. * and may differ for other machines.
  16. */
  17. #define OH_SCC_RESET 1
  18. #define OH_BAY_POWER_N 2 /* a guess */
  19. #define OH_BAY_PCI_ENABLE 4 /* a guess */
  20. #define OH_BAY_IDE_ENABLE 8
  21. #define OH_BAY_FLOPPY_ENABLE 0x10
  22. #define OH_IDE0_ENABLE 0x20
  23. #define OH_IDE0_RESET_N 0x40 /* a guess */
  24. #define OH_BAY_DEV_MASK 0x1c
  25. #define OH_BAY_RESET_N 0x80
  26. #define OH_IOBUS_ENABLE 0x100 /* IOBUS seems to be IDE */
  27. #define OH_SCC_ENABLE 0x200
  28. #define OH_MESH_ENABLE 0x400
  29. #define OH_FLOPPY_ENABLE 0x800
  30. #define OH_SCCA_IO 0x4000
  31. #define OH_SCCB_IO 0x8000
  32. #define OH_VIA_ENABLE 0x10000 /* Is apparently wrong, to be verified */
  33. #define OH_IDE1_RESET_N 0x800000
  34. /*
  35. * Bits to set in the feature control register on PowerBooks.
  36. */
  37. #define PBOOK_FEATURES (OH_IDE_ENABLE | OH_SCC_ENABLE | \
  38. OH_MESH_ENABLE | OH_SCCA_IO | OH_SCCB_IO)
  39. /*
  40. * A magic value to put into the feature control register of the
  41. * "ohare" I/O controller on Starmaxes to enable the IDE CD interface.
  42. * Contributed by Harry Eaton.
  43. */
  44. #define STARMAX_FEATURES 0xbeff7a