linux_dsm_epyc7002/drivers/gpu/drm/nouveau/dispnv04
Ville Syrjälä 438b74a549 drm: Nuke fb->pixel_format
Replace uses of fb->pixel_format with fb->format->format.
Less duplicated information is a good thing.

Note that coccinelle failed to eliminate the
"/* fourcc format */" comment from drm_framebuffer.h, so I had
to do that part manually.

@@
struct drm_framebuffer *FB;
expression E;
@@
 drm_helper_mode_fill_fb_struct(...) {
	...
-	FB->pixel_format = E;
	...
 }

@@
struct drm_framebuffer *FB;
expression E;
@@
 i9xx_get_initial_plane_config(...) {
	...
-	FB->pixel_format = E;
	...
 }

@@
struct drm_framebuffer *FB;
expression E;
@@
 ironlake_get_initial_plane_config(...) {
	...
-	FB->pixel_format = E;
	...
 }

@@
struct drm_framebuffer *FB;
expression E;
@@
 skylake_get_initial_plane_config(...) {
	...
-	FB->pixel_format = E;
	...
 }

@@
struct drm_framebuffer *a;
struct drm_framebuffer b;
@@
(
- a->pixel_format
+ a->format->format
|
- b.pixel_format
+ b.format->format
)

@@
struct drm_plane_state *a;
struct drm_plane_state b;
@@
(
- a->fb->pixel_format
+ a->fb->format->format
|
- b.fb->pixel_format
+ b.fb->format->format
)

@@
struct drm_crtc *CRTC;
@@
(
- CRTC->primary->fb->pixel_format
+ CRTC->primary->fb->format->format
|
- CRTC->primary->state->fb->pixel_format
+ CRTC->primary->state->fb->format->format
)

@@
struct drm_mode_set *set;
@@
(
- set->fb->pixel_format
+ set->fb->format->format
|
- set->crtc->primary->fb->pixel_format
+ set->crtc->primary->fb->format->format
)

@@
@@
 struct drm_framebuffer {
	 ...
-	 uint32_t pixel_format;
	 ...
 };

v2: Fix commit message (Laurent)
    Rebase due to earlier removal of many fb->pixel_format uses,
    including the 'fb->format = drm_format_info(fb->format->format);'
    snafu
v3: Adjusted the semantic patch a bit and regenerated due to code
    changes

Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (v1)
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1481751175-18463-1-git-send-email-ville.syrjala@linux.intel.com
2016-12-15 14:55:34 +02:00
..
arb.c drm/nouveau: rename nouveau_drm.h to nouveau_drv.h 2016-05-20 14:43:04 +10:00
crtc.c drm: Nuke fb->bits_per_pixel 2016-12-15 14:55:34 +02:00
cursor.c drm/nouveau: rename nouveau_drm.h to nouveau_drv.h 2016-05-20 14:43:04 +10:00
dac.c drm/nouveau: rename nouveau_drm.h to nouveau_drv.h 2016-05-20 14:43:04 +10:00
dfp.c drm: Nuke fb->depth 2016-12-15 14:55:33 +02:00
disp.c drm/nouveau: Turn off CRTCs on driver unload 2016-06-24 08:49:34 +02:00
disp.h drm/nouveau: rename nouveau_drm.h to nouveau_drv.h 2016-05-20 14:43:04 +10:00
hw.c drm/nouveau: rename nouveau_drm.h to nouveau_drv.h 2016-05-20 14:43:04 +10:00
hw.h drm/nouveau/nvif: simplify and tidy library interfaces 2015-08-28 12:40:32 +10:00
Kbuild drm/nouveau: remove symlinks, move core/ to nvkm/ (no code changes) 2015-01-22 12:15:10 +10:00
nvreg.h drm/nv04/disp: hide all the cruft away in its own little hole 2013-04-26 15:37:51 +10:00
overlay.c drm: Nuke fb->pixel_format 2016-12-15 14:55:34 +02:00
tvmodesnv17.c drm/nouveau: rename nouveau_drm.h to nouveau_drv.h 2016-05-20 14:43:04 +10:00
tvnv04.c drm/nouveau: rename nouveau_drm.h to nouveau_drv.h 2016-05-20 14:43:04 +10:00
tvnv17.c drm/nouveau/dispnv04: Use helper to turn off CRTC 2016-06-24 08:49:38 +02:00
tvnv17.h drm: Constify TV mode names 2015-09-08 13:45:52 +02:00