3552e8b6828415fc66adcd71e8dcbe3ed7f2cc79
[openwrt/staging/neocturne.git] /
1 From 35f14d8d7ca31484d79e6ad8ec2f6ad1d15531f2 Mon Sep 17 00:00:00 2001
2 From: Dave Stevenson <dave.stevenson@raspberrypi.org>
3 Date: Mon, 28 Jan 2019 14:40:16 +0000
4 Subject: [PATCH 321/773] gpu: vc4_firmware_kms: Fix up 64 bit compile
5 warnings.
6
7 Resolve two build warnings with regard using incorrectly
8 sized parameters in logging messages on 64 bit builds.
9
10 Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
11 ---
12 drivers/gpu/drm/vc4/vc4_firmware_kms.c | 11 ++++++-----
13 1 file changed, 6 insertions(+), 5 deletions(-)
14
15 --- a/drivers/gpu/drm/vc4/vc4_firmware_kms.c
16 +++ b/drivers/gpu/drm/vc4/vc4_firmware_kms.c
17 @@ -160,14 +160,14 @@ static void vc4_primary_plane_atomic_upd
18 WARN_ON_ONCE(vc4_plane->pitch != fb->pitches[0]);
19 }
20
21 - DRM_DEBUG_ATOMIC("[PLANE:%d:%s] primary update %dx%d@%d +%d,%d 0x%08x/%d\n",
22 + DRM_DEBUG_ATOMIC("[PLANE:%d:%s] primary update %dx%d@%d +%d,%d 0x%pad/%d\n",
23 plane->base.id, plane->name,
24 state->crtc_w,
25 state->crtc_h,
26 bpp,
27 state->crtc_x,
28 state->crtc_y,
29 - bo->paddr + fb->offsets[0],
30 + &fbinfo->base,
31 fb->pitches[0]);
32
33 ret = rpi_firmware_transaction(vc4->firmware,
34 @@ -197,6 +197,7 @@ static void vc4_cursor_plane_atomic_upda
35 struct drm_plane_state *state = plane->state;
36 struct drm_framebuffer *fb = state->fb;
37 struct drm_gem_cma_object *bo = drm_fb_cma_get_gem_obj(fb, 0);
38 + dma_addr_t addr = bo->paddr + fb->offsets[0];
39 int ret;
40 u32 packet_state[] = {
41 state->crtc->state->active,
42 @@ -206,13 +207,13 @@ static void vc4_cursor_plane_atomic_upda
43 };
44 WARN_ON_ONCE(fb->pitches[0] != state->crtc_w * 4);
45
46 - DRM_DEBUG_ATOMIC("[PLANE:%d:%s] update %dx%d cursor at %d,%d (0x%08x/%d)",
47 + DRM_DEBUG_ATOMIC("[PLANE:%d:%s] update %dx%d cursor at %d,%d (0x%pad/%d)",
48 plane->base.id, plane->name,
49 state->crtc_w,
50 state->crtc_h,
51 state->crtc_x,
52 state->crtc_y,
53 - bo->paddr + fb->offsets[0],
54 + &addr,
55 fb->pitches[0]);
56
57 /* add on the top/left offsets when overscan is active */
58 @@ -238,7 +239,7 @@ static void vc4_cursor_plane_atomic_upda
59 fb != old_state->fb) {
60 u32 packet_info[] = { state->crtc_w, state->crtc_h,
61 0, /* unused */
62 - bo->paddr + fb->offsets[0],
63 + addr,
64 0, 0, /* hotx, hoty */};
65
66 ret = rpi_firmware_property(vc4->firmware,