Displaying 3 results from an estimated 3 matches for "bochs_fb_helper_funcs".
2018 Sep 05
0
[PATCH] bochs: convert to drm_fb_helper_fbdev_setup/teardown
...t_unreference_unlocked(gfb->obj);
> - gfb->obj = NULL;
> - }
> -
> - drm_framebuffer_unregister_private(&gfb->base);
> - drm_framebuffer_cleanup(&gfb->base);
> -
> return 0;
> }
>
> @@ -158,41 +137,17 @@ static const struct drm_fb_helper_funcs bochs_fb_helper_funcs = {
> .fb_probe = bochsfb_create,
> };
>
> +const struct drm_mode_config_funcs bochs_mode_funcs = {
> + .fb_create = drm_gem_fb_create,
> +};
> +
> int bochs_fbdev_init(struct bochs_device *bochs)
> {
> - int ret;
> -
> - drm_fb_helper_prepare(bochs->de...
2018 Dec 19
0
[PATCH 13/14] drm/bochs: drop old fbdev emulation code
...b_height);
-
- info->screen_base = bo->kmap.virtual;
- info->screen_size = size;
-
- drm_vma_offset_remove(&bo->bo.bdev->vma_manager, &bo->bo.vma_node);
- info->fix.smem_start = 0;
- info->fix.smem_len = size;
- return 0;
-}
-
-static const struct drm_fb_helper_funcs bochs_fb_helper_funcs = {
- .fb_probe = bochsfb_create,
-};
-
static struct drm_framebuffer *
bochs_gem_fb_create(struct drm_device *dev, struct drm_file *file,
const struct drm_mode_fb_cmd2 *mode_cmd)
@@ -153,14 +27,3 @@ const struct drm_mode_config_funcs bochs_mode_funcs = {
.atomic_check = drm_atomic_helpe...
2018 Sep 19
0
[PATCH v3 3/5] drm/bochs: fix DRM_FORMAT_* handling for big endian machines.
...gt;surface_bpp,
- sizes->surface_depth);
+ mode_cmd.pitches[0] = sizes->surface_width * 4;
+ mode_cmd.pixel_format = DRM_FORMAT_HOST_XRGB8888;
size = mode_cmd.pitches[0] * mode_cmd.height;
/* alloc, pin & map bo */
@@ -137,8 +136,18 @@ static const struct drm_fb_helper_funcs bochs_fb_helper_funcs = {
.fb_probe = bochsfb_create,
};
+static struct drm_framebuffer *
+bochs_gem_fb_create(struct drm_device *dev, struct drm_file *file,
+ const struct drm_mode_fb_cmd2 *mode_cmd)
+{
+ if (mode_cmd->pixel_format != DRM_FORMAT_HOST_XRGB8888)
+ return ERR_PTR(-EINVAL);
+
+ return drm_gem...