Commit f3af5c7d authored by Daniel Stone's avatar Daniel Stone Committed by Daniel Vetter
Browse files

drm: fb_helper: Simplify exit condition



mode is always NULL at this point in the function, so make our intention
clear.

Signed-off-by: default avatarDaniel Stone <daniels@collabora.com>
[danvet: Stop clearing mode too to enlist gcc in tracking
uninitialized usage. And remove a space while at it.]
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
parent 44800247
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -1283,12 +1283,12 @@ struct drm_display_mode *drm_pick_cmdline_mode(struct drm_fb_helper_connector *f
						      int width, int height)
{
	struct drm_cmdline_mode *cmdline_mode;
	struct drm_display_mode *mode = NULL;
	struct drm_display_mode *mode;
	bool prefer_non_interlace;

	cmdline_mode = &fb_helper_conn->connector->cmdline_mode;
	if (cmdline_mode->specified == false)
		return mode;
		return NULL;

	/* attempt to find a matching mode in the list of modes
	 *  we have gotten so far, if not add a CVT mode that conforms