search for: bochs_bo

Displaying 15 results from an estimated 15 matches for "bochs_bo".

2018 Dec 19
0
[PATCH 10/14] drm/bochs: drop unused gpu_addr arg from bochs_bo_pin()
...74e06f 100644 --- a/drivers/gpu/drm/bochs/bochs.h +++ b/drivers/gpu/drm/bochs/bochs.h @@ -142,7 +142,7 @@ int bochs_dumb_create(struct drm_file *file, struct drm_device *dev, int bochs_dumb_mmap_offset(struct drm_file *file, struct drm_device *dev, uint32_t handle, uint64_t *offset); -int bochs_bo_pin(struct bochs_bo *bo, u32 pl_flag, u64 *gpu_addr); +int bochs_bo_pin(struct bochs_bo *bo, u32 pl_flag); int bochs_bo_unpin(struct bochs_bo *bo); /* bochs_kms.c */ diff --git a/drivers/gpu/drm/bochs/bochs_fbdev.c b/drivers/gpu/drm/bochs/bochs_fbdev.c index d9f3d42999..92feb817ff 100644 --- a/...
2018 Dec 19
0
[PATCH 11/14] drm/bochs: add basic prime support
..., 1 deletion(-) diff --git a/drivers/gpu/drm/bochs/bochs.h b/drivers/gpu/drm/bochs/bochs.h index d0d474e06f..4236d5d811 100644 --- a/drivers/gpu/drm/bochs/bochs.h +++ b/drivers/gpu/drm/bochs/bochs.h @@ -145,6 +145,17 @@ int bochs_dumb_mmap_offset(struct drm_file *file, struct drm_device *dev, int bochs_bo_pin(struct bochs_bo *bo, u32 pl_flag); int bochs_bo_unpin(struct bochs_bo *bo); +int bochs_gem_prime_pin(struct drm_gem_object *obj); +void bochs_gem_prime_unpin(struct drm_gem_object *obj); +struct sg_table *bochs_gem_prime_get_sg_table(struct drm_gem_object *obj); +struct drm_gem_object *bochs...
2018 Sep 05
0
[PATCH] bochs: convert to drm_fb_helper_fbdev_setup/teardown
...struct { > - struct bochs_framebuffer gfb; > + struct drm_framebuffer *fb; > struct drm_fb_helper helper; > - int size; > - bool initialized; > } fb; > }; > > -#define to_bochs_framebuffer(x) container_of(x, struct bochs_framebuffer, base) > - > struct bochs_bo { > struct ttm_buffer_object bo; > struct ttm_placement placement; > @@ -148,15 +139,9 @@ int bochs_dumb_create(struct drm_file *file, struct drm_device *dev, > int bochs_dumb_mmap_offset(struct drm_file *file, struct drm_device *dev, > uint32_t handle, uint64_t *offset);...
2018 Dec 19
0
[PATCH 05/14] drm/bochs: atomic: switch planes to atomic, wire up helpers.
...bochs_helper_funcs = { @@ -169,6 +174,59 @@ static const uint32_t bochs_formats[] = { DRM_FORMAT_BGRX8888, }; +static void bochs_plane_atomic_update(struct drm_plane *plane, + struct drm_plane_state *old_state) +{ + struct bochs_device *bochs = plane->dev->dev_private; + struct bochs_bo *bo; + + if (!plane->state->fb) + return; + bo = gem_to_bochs_bo(plane->state->fb->obj[0]); + bochs_hw_setbase(bochs, + plane->state->crtc_x, + plane->state->crtc_y, + bo->bo.offset); + bochs_hw_setformat(bochs, plane->state->fb->format); +} + +stati...
2018 Dec 19
0
[PATCH 13/14] drm/bochs: drop old fbdev emulation code
...587e71e 100644 --- a/drivers/gpu/drm/bochs/bochs.h +++ b/drivers/gpu/drm/bochs/bochs.h @@ -80,12 +80,6 @@ struct bochs_device { struct ttm_bo_device bdev; bool initialized; } ttm; - - /* fbdev */ - struct { - struct drm_framebuffer *fb; - struct drm_fb_helper helper; - } fb; }; struct bochs_bo { @@ -161,7 +155,4 @@ int bochs_kms_init(struct bochs_device *bochs); void bochs_kms_fini(struct bochs_device *bochs); /* bochs_fbdev.c */ -int bochs_fbdev_init(struct bochs_device *bochs); -void bochs_fbdev_fini(struct bochs_device *bochs); - extern const struct drm_mode_config_funcs bochs_mo...
2019 Apr 10
2
[PATCH] drm/bochs: use simple display pipe
...RX8888, }; -static void bochs_plane_atomic_update(struct drm_plane *plane, - struct drm_plane_state *old_state) +static void bochs_plane_update(struct bochs_device *bochs, + struct drm_plane_state *state) { - struct bochs_device *bochs = plane->dev->dev_private; struct bochs_bo *bo; - if (!plane->state->fb) + if (!state->fb || !bochs->stride) return; - bo = gem_to_bochs_bo(plane->state->fb->obj[0]); + + bo = gem_to_bochs_bo(state->fb->obj[0]); bochs_hw_setbase(bochs, - plane->state->crtc_x, - plane->state->crtc_y, + s...
2019 Feb 04
1
[PATCH] drm/bochs: fix bochs_gem_prime_mmap
...(+), 1 deletion(-) diff --git a/drivers/gpu/drm/bochs/bochs_mm.c b/drivers/gpu/drm/bochs/bochs_mm.c index 641a33f134..49463348a0 100644 --- a/drivers/gpu/drm/bochs/bochs_mm.c +++ b/drivers/gpu/drm/bochs/bochs_mm.c @@ -442,5 +442,6 @@ int bochs_gem_prime_mmap(struct drm_gem_object *obj, { struct bochs_bo *bo = gem_to_bochs_bo(obj); - return ttm_fbdev_mmap(vma, &bo->bo); + bo->gem.vma_node.vm_node.start = bo->bo.vma_node.vm_node.start; + return drm_gem_prime_mmap(obj, vma); } -- 2.9.3
2019 Apr 24
21
[PATCH v2 00/17] Share TTM code among DRM framebuffer drivers
Several simple framebuffer drivers copy most of the TTM code from each other. The implementation is always the same; except for the name of some data structures. As recently discussed, this patch set provides generic memory-management code for simple framebuffers with dedicated video memory. It further converts the respective drivers to the generic code. The shared code is basically the same
2019 May 06
25
[PATCH v4 00/19] Share TTM code among DRM framebuffer drivers
Several simple framebuffer drivers copy most of the TTM code from each other. The implementation is always the same; except for the name of some data structures. As recently discussed, this patch set provides generic memory-management code for simple framebuffers with dedicated video memory. It further converts the respective drivers to the generic code. The shared code is basically the same
2019 May 06
25
[PATCH v4 00/19] Share TTM code among DRM framebuffer drivers
Several simple framebuffer drivers copy most of the TTM code from each other. The implementation is always the same; except for the name of some data structures. As recently discussed, this patch set provides generic memory-management code for simple framebuffers with dedicated video memory. It further converts the respective drivers to the generic code. The shared code is basically the same
2019 May 08
22
[PATCH v5 00/20] Share TTM code among DRM framebuffer drivers
Several simple framebuffer drivers copy most of the TTM code from each other. The implementation is always the same; except for the name of some data structures. As recently discussed, this patch set provides generic memory-management code for simple framebuffers with dedicated video memory. It further converts the respective drivers to the generic code. The shared code is basically the same
2019 May 08
22
[PATCH v5 00/20] Share TTM code among DRM framebuffer drivers
Several simple framebuffer drivers copy most of the TTM code from each other. The implementation is always the same; except for the name of some data structures. As recently discussed, this patch set provides generic memory-management code for simple framebuffers with dedicated video memory. It further converts the respective drivers to the generic code. The shared code is basically the same
2019 Apr 29
21
[PATCH v3 00/19] Share TTM code among DRM framebuffer drivers
Several simple framebuffer drivers copy most of the TTM code from each other. The implementation is always the same; except for the name of some data structures. As recently discussed, this patch set provides generic memory-management code for simple framebuffers with dedicated video memory. It further converts the respective drivers to the generic code. The shared code is basically the same
2018 Aug 09
0
[PATCH] drm/bochs: Replace ttm_bo_unref with ttm_bo_put
> diff --git a/drivers/gpu/drm/bochs/bochs_mm.c b/drivers/gpu/drm/bochs/bochs_mm.c > index 39cd08416773..c9c7097030ca 100644 > --- a/drivers/gpu/drm/bochs/bochs_mm.c > +++ b/drivers/gpu/drm/bochs/bochs_mm.c > @@ -430,7 +430,7 @@ static void bochs_bo_unref(struct bochs_bo **bo) > return; > > tbo = &((*bo)->bo); > - ttm_bo_unref(&tbo); > + ttm_bo_put(tbo); fails to build: CC [M] drivers/gpu/drm/bochs/bochs_mm.o /home/kraxel/projects/linux/drivers/gpu/drm/bochs/bochs_mm.c: In function ?bochs_bo_unref?: /home/...
2018 Dec 19
0
[PATCH 09/14] drm/bochs: remove old bochs_crtc_* functions
...DBY: - case DRM_MODE_DPMS_SUSPEND: - case DRM_MODE_DPMS_OFF: - default: - return; - } -} - -static int bochs_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y, - struct drm_framebuffer *old_fb) -{ - struct bochs_device *bochs = - container_of(crtc, struct bochs_device, crtc); - struct bochs_bo *bo; - u64 gpu_addr = 0; - int ret; - - if (old_fb) { - bo = gem_to_bochs_bo(old_fb->obj[0]); - ret = ttm_bo_reserve(&bo->bo, true, false, NULL); - if (ret) { - DRM_ERROR("failed to reserve old_fb bo\n"); - } else { - bochs_bo_unpin(bo); - ttm_bo_unreserve(&bo->...