Commit 8f27dbf0 authored by Ville Syrjälä's avatar Ville Syrjälä

drm/i915: Use u8 consistently for active_planes bitmask

Be consistent in that active_planes bitmask fits in a u8.
Signed-off-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210514125751.17075-4-ville.syrjala@linux.intel.comReviewed-by: default avatarStanislav Lisovskiy <stanislav.lisovskiy@intel.com>
parent 5a623ff8
...@@ -1708,7 +1708,7 @@ static int vlv_compute_fifo(struct intel_crtc_state *crtc_state) ...@@ -1708,7 +1708,7 @@ static int vlv_compute_fifo(struct intel_crtc_state *crtc_state)
const struct g4x_pipe_wm *raw = const struct g4x_pipe_wm *raw =
&crtc_state->wm.vlv.raw[VLV_WM_LEVEL_PM2]; &crtc_state->wm.vlv.raw[VLV_WM_LEVEL_PM2];
struct vlv_fifo_state *fifo_state = &crtc_state->wm.vlv.fifo_state; struct vlv_fifo_state *fifo_state = &crtc_state->wm.vlv.fifo_state;
unsigned int active_planes = crtc_state->active_planes & ~BIT(PLANE_CURSOR); u8 active_planes = crtc_state->active_planes & ~BIT(PLANE_CURSOR);
int num_active_planes = hweight8(active_planes); int num_active_planes = hweight8(active_planes);
const int fifo_size = 511; const int fifo_size = 511;
int fifo_extra, fifo_left = fifo_size; int fifo_extra, fifo_left = fifo_size;
...@@ -1900,8 +1900,8 @@ static int vlv_compute_pipe_wm(struct intel_atomic_state *state, ...@@ -1900,8 +1900,8 @@ static int vlv_compute_pipe_wm(struct intel_atomic_state *state,
struct vlv_wm_state *wm_state = &crtc_state->wm.vlv.optimal; struct vlv_wm_state *wm_state = &crtc_state->wm.vlv.optimal;
const struct vlv_fifo_state *fifo_state = const struct vlv_fifo_state *fifo_state =
&crtc_state->wm.vlv.fifo_state; &crtc_state->wm.vlv.fifo_state;
int num_active_planes = hweight8(crtc_state->active_planes & u8 active_planes = crtc_state->active_planes & ~BIT(PLANE_CURSOR);
~BIT(PLANE_CURSOR)); int num_active_planes = hweight8(active_planes);
bool needs_modeset = drm_atomic_crtc_needs_modeset(&crtc_state->uapi); bool needs_modeset = drm_atomic_crtc_needs_modeset(&crtc_state->uapi);
const struct intel_plane_state *old_plane_state; const struct intel_plane_state *old_plane_state;
const struct intel_plane_state *new_plane_state; const struct intel_plane_state *new_plane_state;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment