fsl_srio.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. /*
  2. * Copyright 2011-2012 Freescale Semiconductor, Inc.
  3. *
  4. * See file CREDITS for list of people who contributed to this
  5. * project.
  6. *
  7. * This program is free software; you can redistribute it and/or
  8. * modify it under the terms of the GNU General Public License as
  9. * published by the Free Software Foundation; either version 2 of
  10. * the License, or (at your option) any later version.
  11. *
  12. * This program is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. * GNU General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU General Public License
  18. * along with this program; if not, write to the Free Software
  19. * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
  20. * MA 02111-1307 USA
  21. */
  22. #ifndef _FSL_SRIO_H_
  23. #define _FSL_SRIO_H_
  24. enum atmu_size {
  25. ATMU_SIZE_4K = 0xb,
  26. ATMU_SIZE_8K,
  27. ATMU_SIZE_16K,
  28. ATMU_SIZE_32K,
  29. ATMU_SIZE_64K,
  30. ATMU_SIZE_128K,
  31. ATMU_SIZE_256K,
  32. ATMU_SIZE_512K,
  33. ATMU_SIZE_1M,
  34. ATMU_SIZE_2M,
  35. ATMU_SIZE_4M,
  36. ATMU_SIZE_8M,
  37. ATMU_SIZE_16M,
  38. ATMU_SIZE_32M,
  39. ATMU_SIZE_64M,
  40. ATMU_SIZE_128M,
  41. ATMU_SIZE_256M,
  42. ATMU_SIZE_512M,
  43. ATMU_SIZE_1G,
  44. ATMU_SIZE_2G,
  45. ATMU_SIZE_4G,
  46. ATMU_SIZE_8G,
  47. ATMU_SIZE_16G,
  48. ATMU_SIZE_32G,
  49. ATMU_SIZE_64G,
  50. };
  51. #define atmu_size_mask(sz) (__ilog2_u64(sz) - 1)
  52. #define atmu_size_bytes(x) (1ULL << ((x & 0x3f) + 1))
  53. extern void srio_init(void);
  54. #ifdef CONFIG_SRIOBOOT_MASTER
  55. extern void srio_boot_master(void);
  56. #ifdef CONFIG_SRIOBOOT_SLAVE_HOLDOFF
  57. extern void srio_boot_master_release_slave(void);
  58. #endif
  59. #endif
  60. #endif