atari_acsi.h 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. #ifndef _ASM_ATARI_ACSI_H
  2. #define _ASM_ATARI_ACSI_H
  3. /* Functions exported by drivers/block/acsi.c */
  4. void acsi_delay_start( void );
  5. void acsi_delay_end( long usec );
  6. int acsi_wait_for_IRQ( unsigned timeout );
  7. int acsi_wait_for_noIRQ( unsigned timeout );
  8. int acsicmd_nodma( const char *cmd, int enable);
  9. int acsi_getstatus( void );
  10. int acsi_extstatus( char *buffer, int cnt );
  11. void acsi_end_extstatus( void );
  12. int acsi_extcmd( unsigned char *buffer, int cnt );
  13. /* The ACSI buffer is guarantueed to reside in ST-RAM and may be used by other
  14. * drivers that work on the ACSI bus, too. It's data are valid only as long as
  15. * the ST-DMA is locked. */
  16. extern char *acsi_buffer;
  17. extern unsigned long phys_acsi_buffer;
  18. /* Utility macros */
  19. /* Send one data byte over the bus and set mode for next operation
  20. * with one move.l -- Atari recommends this...
  21. */
  22. #define DMA_LONG_WRITE(data,mode) \
  23. do { \
  24. *((unsigned long *)&dma_wd.fdc_acces_seccount) = \
  25. ((data)<<16) | (mode); \
  26. } while(0)
  27. #define ENABLE_IRQ() atari_turnon_irq( IRQ_MFP_ACSI )
  28. #define DISABLE_IRQ() atari_turnoff_irq( IRQ_MFP_ACSI )
  29. #endif /* _ASM_ATARI_ACSI_H */