drm_fbdev_ttm.h 682 B

12345678910111213141516171819202122232425262728
  1. /* SPDX-License-Identifier: MIT */
  2. #ifndef DRM_FBDEV_TTM_H
  3. #define DRM_FBDEV_TTM_H
  4. #include <linux/stddef.h>
  5. struct drm_device;
  6. struct drm_fb_helper;
  7. struct drm_fb_helper_surface_size;
  8. #ifdef CONFIG_DRM_FBDEV_EMULATION
  9. int drm_fbdev_ttm_driver_fbdev_probe(struct drm_fb_helper *fb_helper,
  10. struct drm_fb_helper_surface_size *sizes);
  11. #define DRM_FBDEV_TTM_DRIVER_OPS \
  12. .fbdev_probe = drm_fbdev_ttm_driver_fbdev_probe
  13. void drm_fbdev_ttm_setup(struct drm_device *dev, unsigned int preferred_bpp);
  14. #else
  15. #define DRM_FBDEV_TTM_DRIVER_OPS \
  16. .fbdev_probe = NULL
  17. static inline void drm_fbdev_ttm_setup(struct drm_device *dev, unsigned int preferred_bpp)
  18. { }
  19. #endif
  20. #endif