alpine_cpu_resume.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*
  2. * Annapurna labs cpu-resume register structure.
  3. *
  4. * Copyright (C) 2015 Annapurna Labs Ltd.
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License as published by
  8. * the Free Software Foundation; either version 2 of the License, or
  9. * (at your option) any later version.
  10. *
  11. * This program is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. * GNU General Public License for more details.
  15. */
  16. #ifndef ALPINE_CPU_RESUME_H_
  17. #define ALPINE_CPU_RESUME_H_
  18. /* Per-cpu regs */
  19. struct al_cpu_resume_regs_per_cpu {
  20. uint32_t flags;
  21. uint32_t resume_addr;
  22. };
  23. /* general regs */
  24. struct al_cpu_resume_regs {
  25. /* Watermark for validating the CPU resume struct */
  26. uint32_t watermark;
  27. uint32_t flags;
  28. struct al_cpu_resume_regs_per_cpu per_cpu[];
  29. };
  30. /* The expected magic number for validating the resume addresses */
  31. #define AL_CPU_RESUME_MAGIC_NUM 0xf0e1d200
  32. #define AL_CPU_RESUME_MAGIC_NUM_MASK 0xffffff00
  33. #endif /* ALPINE_CPU_RESUME_H_ */