microcode.h 769 B

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * Copyright (c) 2015 Google, Inc
  3. *
  4. * SPDX-License-Identifier: GPL-2.0+
  5. */
  6. #ifndef __ASM_ARCH_MICROCODE_H
  7. #define __ASM_ARCH_MICROCODE_H
  8. #ifndef __ASSEMBLY__
  9. /* This is a declaration for ucode_base in start.S */
  10. extern u32 ucode_base;
  11. /**
  12. * microcode_update_intel() - Apply microcode updates
  13. *
  14. * Applies any microcode updates in the device tree.
  15. *
  16. * @return 0 if OK, -EEXIST if the updates were already applied, -ENOENT if
  17. * not updates were found, -EINVAL if an update was invalid
  18. */
  19. int microcode_update_intel(void);
  20. /**
  21. * microcode_read_rev() - Read the microcode version
  22. *
  23. * This reads the microcode version of the currently running CPU
  24. *
  25. * @return microcode version number
  26. */
  27. int microcode_read_rev(void);
  28. #endif /* __ASSEMBLY__ */
  29. #endif