omap-secure.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /*
  2. * omap-secure.h: OMAP Secure infrastructure header.
  3. *
  4. * Copyright (C) 2011 Texas Instruments, Inc.
  5. * Santosh Shilimkar <santosh.shilimkar@ti.com>
  6. *
  7. * This program is free software; you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License version 2 as
  9. * published by the Free Software Foundation.
  10. */
  11. #ifndef OMAP_ARCH_OMAP_SECURE_H
  12. #define OMAP_ARCH_OMAP_SECURE_H
  13. /* Monitor error code */
  14. #define API_HAL_RET_VALUE_NS2S_CONVERSION_ERROR 0xFFFFFFFE
  15. #define API_HAL_RET_VALUE_SERVICE_UNKNWON 0xFFFFFFFF
  16. /* HAL API error codes */
  17. #define API_HAL_RET_VALUE_OK 0x00
  18. #define API_HAL_RET_VALUE_FAIL 0x01
  19. /* Secure HAL API flags */
  20. #define FLAG_START_CRITICAL 0x4
  21. #define FLAG_IRQFIQ_MASK 0x3
  22. #define FLAG_IRQ_ENABLE 0x2
  23. #define FLAG_FIQ_ENABLE 0x1
  24. #define NO_FLAG 0x0
  25. /* Secure low power HAL API index */
  26. #define OMAP4_HAL_SAVESECURERAM_INDEX 0x1a
  27. #define OMAP4_HAL_SAVEHW_INDEX 0x1b
  28. #define OMAP4_HAL_SAVEALL_INDEX 0x1c
  29. #define OMAP4_HAL_SAVEGIC_INDEX 0x1d
  30. extern u32 omap_secure_dispatcher(u32 idx, u32 flag, u32 nargs,
  31. u32 arg1, u32 arg2, u32 arg3, u32 arg4);
  32. extern u32 omap_smc2(u32 id, u32 falg, u32 pargs);
  33. #endif /* OMAP_ARCH_OMAP_SECURE_H */