mirror of
https://github.com/openbsd/src.git
synced 2026-06-18 07:13:36 +02:00
Add fb_blank function pointer to struct fb_ops and enable paths that
set it. Also add fb_blank() which uses it, for use in inteldrm(4).
This commit is contained in:
@@ -164,8 +164,8 @@ static const struct fb_ops intelfb_ops = {
|
||||
DRM_FB_HELPER_DEFAULT_OPS,
|
||||
#endif
|
||||
.fb_set_par = intel_fbdev_set_par,
|
||||
#ifdef notyet
|
||||
.fb_blank = intel_fbdev_blank,
|
||||
#ifdef notyet
|
||||
.fb_pan_display = intel_fbdev_pan_display,
|
||||
__FB_DEFAULT_DEFERRED_OPS_DRAW(intel_fbdev),
|
||||
.fb_mmap = intel_fbdev_mmap,
|
||||
|
||||
@@ -242,7 +242,8 @@ drm_fb_helper_from_client(struct drm_client_dev *client)
|
||||
.fb_ioctl = drm_fb_helper_ioctl
|
||||
#else
|
||||
#define DRM_FB_HELPER_DEFAULT_OPS \
|
||||
.fb_set_par = drm_fb_helper_set_par
|
||||
.fb_set_par = drm_fb_helper_set_par, \
|
||||
.fb_blank = drm_fb_helper_blank
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_DRM_FBDEV_EMULATION
|
||||
|
||||
@@ -29,6 +29,7 @@ struct fb_var_screeninfo {
|
||||
|
||||
struct fb_ops {
|
||||
int (*fb_set_par)(struct fb_info *);
|
||||
int (*fb_blank)(int, struct fb_info *);
|
||||
};
|
||||
|
||||
struct fb_fix_screeninfo {
|
||||
@@ -97,6 +98,15 @@ fb_get_options(const char *name, char **opt)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline int
|
||||
fb_blank(struct fb_info *fbi, int b)
|
||||
{
|
||||
int r = 0;
|
||||
if (fbi->fbops && fbi->fbops->fb_blank)
|
||||
r = fbi->fbops->fb_blank(b, fbi);
|
||||
return r;
|
||||
}
|
||||
|
||||
static inline int
|
||||
register_framebuffer(struct fb_info *fbi)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user