]> www.infradead.org Git - nvme.git/commitdiff
drm/i915/fbc: Adjust g4x+ platform checks
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Fri, 5 Jul 2024 14:52:41 +0000 (17:52 +0300)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Fri, 12 Jul 2024 12:05:40 +0000 (15:05 +0300)
Do the "is this ilk+ or g4x" checks in the customary order instead
of the reverse order. Easier for the poor brain to parse this
when it's always done the same way.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240705145254.3355-8-ville.syrjala@linux.intel.com
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/i915/display/intel_fbc.c

index 779e96dd3f6ff13612ef093908c3ecbdf6f919b4..6853573f848643e2b578b06b8c41c5742d974553 100644 (file)
@@ -1086,7 +1086,7 @@ static void intel_fbc_max_surface_size(struct intel_display *display,
        } else if (DISPLAY_VER(display) >= 7) {
                *w = 4096;
                *h = 4096;
-       } else if (IS_G4X(i915) || DISPLAY_VER(display) >= 5) {
+       } else if (DISPLAY_VER(display) >= 5 || IS_G4X(i915)) {
                *w = 4096;
                *h = 2048;
        } else {
@@ -1127,7 +1127,7 @@ static void intel_fbc_max_plane_size(struct intel_display *display,
        } else if (DISPLAY_VER(display) >= 8 || IS_HASWELL(i915)) {
                *w = 4096;
                *h = 4096;
-       } else if (IS_G4X(i915) || DISPLAY_VER(display) >= 5) {
+       } else if (DISPLAY_VER(display) >= 5 || IS_G4X(i915)) {
                *w = 4096;
                *h = 2048;
        } else {