vboot_display.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. /* Copyright (c) 2013 The Chromium OS Authors. All rights reserved.
  2. * Use of this source code is governed by a BSD-style license that can be
  3. * found in the LICENSE file.
  4. *
  5. * Display functions used in kernel selection.
  6. */
  7. #ifndef VBOOT_REFERENCE_VBOOT_DISPLAY_H_
  8. #define VBOOT_REFERENCE_VBOOT_DISPLAY_H_
  9. #include "bmpblk_font.h"
  10. #include "vboot_api.h"
  11. #include "vboot_nvstorage.h"
  12. struct vb2_context;
  13. VbError_t VbDisplayScreenFromGBB(struct vb2_context *ctx,
  14. VbCommonParams *cparams, uint32_t screen,
  15. uint32_t locale);
  16. VbError_t VbDisplayScreen(struct vb2_context *ctx, VbCommonParams *cparams,
  17. uint32_t screen, int force);
  18. VbError_t VbDisplayDebugInfo(struct vb2_context *ctx, VbCommonParams *cparams);
  19. VbError_t VbCheckDisplayKey(struct vb2_context *ctx, VbCommonParams *cparams,
  20. uint32_t key);
  21. /* Internal functions, for unit testing */
  22. typedef FontArrayHeader VbFont_t;
  23. VbFont_t *VbInternalizeFontData(FontArrayHeader *fonthdr);
  24. void VbDoneWithFontForNow(VbFont_t *ptr);
  25. ImageInfo *VbFindFontGlyph(VbFont_t *font, uint32_t ascii,
  26. void **bufferptr, uint32_t *buffersize);
  27. /**
  28. * Try to display the specified text at a particular position.
  29. */
  30. void VbRenderTextAtPos(const char *text, int right_to_left,
  31. uint32_t x, uint32_t y, VbFont_t *font);
  32. /**
  33. * Return a description of the recovery reason code.
  34. */
  35. const char *RecoveryReasonString(uint8_t code);
  36. /**
  37. * Get the number of localizations in the GBB bitmap data.
  38. */
  39. VbError_t VbGetLocalizationCount(VbCommonParams *cparams, uint32_t *count);
  40. #endif /* VBOOT_REFERENCE_VBOOT_DISPLAY_H_ */