atmel.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. /*
  2. * atmel platform data
  3. *
  4. * GPL v2 Only
  5. */
  6. #ifndef __ATMEL_H__
  7. #define __ATMEL_H__
  8. #include <linux/mtd/nand.h>
  9. #include <linux/mtd/partitions.h>
  10. /* Compact Flash */
  11. struct at91_cf_data {
  12. int irq_pin; /* I/O IRQ */
  13. int det_pin; /* Card detect */
  14. int vcc_pin; /* power switching */
  15. int rst_pin; /* card reset */
  16. u8 chipselect; /* EBI Chip Select number */
  17. u8 flags;
  18. #define AT91_CF_TRUE_IDE 0x01
  19. #define AT91_IDE_SWAP_A0_A2 0x02
  20. };
  21. /* NAND / SmartMedia */
  22. struct atmel_nand_data {
  23. int enable_pin; /* chip enable */
  24. int det_pin; /* card detect */
  25. int rdy_pin; /* ready/busy */
  26. u8 rdy_pin_active_low; /* rdy_pin value is inverted */
  27. u8 ale; /* address line number connected to ALE */
  28. u8 cle; /* address line number connected to CLE */
  29. u8 bus_width_16; /* buswidth is 16 bit */
  30. u8 ecc_mode; /* ecc mode */
  31. u8 on_flash_bbt; /* bbt on flash */
  32. struct mtd_partition *parts;
  33. unsigned int num_parts;
  34. bool has_dma; /* support dma transfer */
  35. /* default is false, only for at32ap7000 chip is true */
  36. bool need_reset_workaround;
  37. };
  38. /* FIXME: this needs a better location, but gets stuff building again */
  39. extern int at91_suspend_entering_slow_clock(void);
  40. #endif /* __ATMEL_H__ */