Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b75e1695 authored by Dave Airlie's avatar Dave Airlie
Browse files

Merge branch 'drm-vmwgfx-next' of git://people.freedesktop.org/~syeh/repos_linux into drm-next

This is to address what we've discussed, moving some of the minor changes
into a drm-next request.

* 'drm-vmwgfx-next' of git://people.freedesktop.org/~syeh/repos_linux:
  drm/vmwgfx: Use kmemdup instead of kmalloc and memcpy
  drm/vmwgfx: Fix depth input into drm_mode_legacy_fb_format
  drm/vmwgfx: Fix a potential integer overflow
  drm/vmwgfx: Clear an uninitialized struct member
  drm/vmwgfx: Annotate ignored return values
  drm/vmwgfx: Clear uninitialized fields of a parameter
parents 29a73d90 5d25fde2
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -980,6 +980,8 @@ svga3dsurface_get_mip_size(surf_size_struct base_level, u32 mip_level)
	size.width = max_t(u32, base_level.width >> mip_level, 1);
	size.height = max_t(u32, base_level.height >> mip_level, 1);
	size.depth = max_t(u32, base_level.depth >> mip_level, 1);
	size.pad64 = 0;

	return size;
}

+1 −1
Original line number Diff line number Diff line
@@ -840,7 +840,7 @@ static void vmw_move_notify(struct ttm_buffer_object *bo,
 */
static void vmw_swap_notify(struct ttm_buffer_object *bo)
{
	ttm_bo_wait(bo, false, false);
	(void) ttm_bo_wait(bo, false, false);
}


+1 −1
Original line number Diff line number Diff line
@@ -1293,7 +1293,7 @@ static void __vmw_svga_enable(struct vmw_private *dev_priv)
 */
void vmw_svga_enable(struct vmw_private *dev_priv)
{
	ttm_read_lock(&dev_priv->reservation_sem, false);
	(void) ttm_read_lock(&dev_priv->reservation_sem, false);
	__vmw_svga_enable(dev_priv);
	ttm_read_unlock(&dev_priv->reservation_sem);
}
+1 −2
Original line number Diff line number Diff line
@@ -482,8 +482,7 @@ static int vmw_fb_kms_framebuffer(struct fb_info *info)
	mode_cmd.height = var->yres;
	mode_cmd.pitches[0] = ((var->bits_per_pixel + 7) / 8) * mode_cmd.width;
	mode_cmd.pixel_format =
		drm_mode_legacy_fb_format(var->bits_per_pixel,
			((var->bits_per_pixel + 7) / 8) * mode_cmd.width);
		drm_mode_legacy_fb_format(var->bits_per_pixel, depth);

	cur_fb = par->set_fb;
	if (cur_fb && cur_fb->width == mode_cmd.width &&
+2 −2
Original line number Diff line number Diff line
@@ -757,7 +757,7 @@ static int vmw_create_dmabuf_proxy(struct drm_device *dev,
				   struct vmw_surface **srf_out)
{
	uint32_t format;
	struct drm_vmw_size content_base_size;
	struct drm_vmw_size content_base_size = {0};
	struct vmw_resource *res;
	unsigned int bytes_pp;
	struct drm_format_name_buf format_name;
@@ -1671,7 +1671,7 @@ int vmw_kms_update_layout_ioctl(struct drm_device *dev, void *data,
		 *	1. Bounding box (assuming 32bpp) must be < prim_bb_mem
		 *      2. Total pixels (assuming 32bpp) must be < prim_bb_mem
		 */
		u64 bb_mem    = bounding_box.w * bounding_box.h * 4;
		u64 bb_mem    = (u64) bounding_box.w * bounding_box.h * 4;
		u64 pixel_mem = total_pixels * 4;

		if (bb_mem > dev_priv->prim_bb_mem) {
Loading