vesa.c 658 B

123456789101112131415161718192021222324252627282930313233
  1. // SPDX-License-Identifier: GPL-2.0+
  2. /*
  3. * Copyright (C) 2016, Bin Meng <bmeng.cn@gmail.com>
  4. */
  5. #include <common.h>
  6. #include <dm.h>
  7. #include <pci.h>
  8. #include <vbe.h>
  9. static int vesa_video_probe(struct udevice *dev)
  10. {
  11. return vbe_setup_video(dev, NULL);
  12. }
  13. static const struct udevice_id vesa_video_ids[] = {
  14. { .compatible = "vesa-fb" },
  15. { }
  16. };
  17. U_BOOT_DRIVER(vesa_video) = {
  18. .name = "vesa_video",
  19. .id = UCLASS_VIDEO,
  20. .of_match = vesa_video_ids,
  21. .probe = vesa_video_probe,
  22. };
  23. static struct pci_device_id vesa_video_supported[] = {
  24. { PCI_DEVICE_CLASS(PCI_CLASS_DISPLAY_VGA << 8, ~0) },
  25. { },
  26. };
  27. U_BOOT_PCI_DEVICE(vesa_video, vesa_video_supported);