From mboxrd@z Thu Jan 1 00:00:00 1970 From: Maxime Ripard Subject: Re: [PATCH v2] drm/sun4i: Clear encoder->bridge if a bridge is not found Date: Thu, 1 Sep 2016 18:46:19 +0200 Message-ID: <20160901164619.GF20462@lukather> References: <20160901061332.1803-1-wens@csie.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1888647554==" Return-path: Received: from mail.free-electrons.com (down.free-electrons.com [37.187.137.238]) by gabe.freedesktop.org (Postfix) with ESMTP id 7C2D46E996 for ; Thu, 1 Sep 2016 16:46:21 +0000 (UTC) In-Reply-To: <20160901061332.1803-1-wens@csie.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: Chen-Yu Tsai Cc: linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org List-Id: dri-devel@lists.freedesktop.org --===============1888647554== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Pql/uPZNXIm1JCle" Content-Disposition: inline --Pql/uPZNXIm1JCle Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Sep 01, 2016 at 02:13:32PM +0800, Chen-Yu Tsai wrote: > The KMS helpers (drm_atomic_helper_check_modeset/mode_fixup) pass > encoder->bridge directly to drm_bridge_mode_fixup, which expects a > valid pointer, or NULL (in which case it just returns). >=20 > Clear encoder->bridge if a bridge is not found, instead of keeping > the ERR_PTR value. >=20 > Since other drm_bridge functions also follow this pattern of checking > for a non-NULL pointer, we can drop the ifs around the calls and just > pass the pointer directly. >=20 > Fixes: 894f5a9f4b4a ("drm/sun4i: Add bridge support") > Signed-off-by: Chen-Yu Tsai Applied, thanks! Maxime --=20 Maxime Ripard, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com --Pql/uPZNXIm1JCle Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJXyFtbAAoJEBx+YmzsjxAgfQgQAJZQlFoMna8sl/b4EEKP6p67 gjxA8/6TyIEQQFhrjEUmEO2NhnY3pKtuowaoKMFp2qMyVTc6AiYNFSHtSDvz7uHM KksmoAUwTQeY1d8clRKrtuti+/jFVsLqOCCSH1pORHwvMcE2i8j3a75T9j8M7+UC UizG2GU8CqLhIRCyTo30rVLC60+CUwVHbgj6YH8p7KT/FaL5W0/7nxAOBBM+eAbW prB32QxAktW8WRDQYO5xNPFDDGbssUTsUMuy51KmigZTbocBBQnCVCh9Z9Pxo3P9 qqDf8bnmKsARPkcgiJXesJ3rpFH3AbTo0Hv+r33szXceZPqQNAgCDb0N6cPJ8daQ uQqhe6C8nQYQfrIJ0NlghM+FmndgirTd8olsQNpXCdEP0hrQcJ7nzQ6jAh6hgNSz IIv3cbhrQJAtfO0TWsPMIpfqYdR1k/f6aa7phI5/NRHXW+rfDXWNOcVrCDxHQCF4 faYnmPlWFrjgQ0YMO5lgNBxajDsJGBS9cxDwuZiC7wMsbJM0S6tjsB+bm8v3GIC5 6KAnkhmFjjd5lIoXsOixNiqnYwRBalHbPuN/K8X0qzK837qIkTTGG8/KLgw6d6nJ rakj1chfnejxqiEg4NJDgwRVWFrNwm9gHTPvx9atvEruQYsG3iviSiqrd0nKCLrT 4jvZ3zLz8Xfm0fuM2uIA =UEeG -----END PGP SIGNATURE----- --Pql/uPZNXIm1JCle-- --===============1888647554== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KZHJpLWRldmVs IG1haWxpbmcgbGlzdApkcmktZGV2ZWxAbGlzdHMuZnJlZWRlc2t0b3Aub3JnCmh0dHBzOi8vbGlz dHMuZnJlZWRlc2t0b3Aub3JnL21haWxtYW4vbGlzdGluZm8vZHJpLWRldmVsCg== --===============1888647554==--