From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thierry Reding Subject: Re: [PATCH 07/18] drm/mga200g: Hold a proper reference for cursor_set Date: Mon, 10 Aug 2015 12:46:42 +0200 Message-ID: <20150810104640.GG1262@ulmo.nvidia.com> References: <1436477570-4936-1-git-send-email-daniel.vetter@ffwll.ch> <1436477570-4936-8-git-send-email-daniel.vetter@ffwll.ch> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0467931887==" Return-path: In-Reply-To: <1436477570-4936-8-git-send-email-daniel.vetter@ffwll.ch> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" To: Daniel Vetter Cc: Daniel Vetter , Intel Graphics Development , DRI Development List-Id: dri-devel@lists.freedesktop.org --===============0467931887== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="NPukt5Otb9an/u20" Content-Disposition: inline --NPukt5Otb9an/u20 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Jul 09, 2015 at 11:32:39PM +0200, Daniel Vetter wrote: > Looking up an obj, immediate dropping the acquired reference and then > continuing to use it isn't how this is supposed to work. Fix this by > holding a reference for the entire function. >=20 > While at it stop grabbing dev->struct_mutex, it doesn't protect > anything here. >=20 > Signed-off-by: Daniel Vetter > --- > drivers/gpu/drm/mgag200/mgag200_cursor.c | 22 ++++++++++------------ > 1 file changed, 10 insertions(+), 12 deletions(-) Reviewed-by: Thierry Reding --NPukt5Otb9an/u20 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAABCAAGBQJVyIEQAAoJEN0jrNd/PrOhsocQAIw0beO1xk6zNbCXk4NTAx+E FiSUHFvZsvOgN3dA6ET4ukVJml6a/DxkGVESnYo5hcPtHd6ZD8d5ZivkGVfaazZG OVz1lhSEU5L+x8xCyXz92MX2aha+NTO/3X6kVnT+jM2UOwEU1MmkGJnScoT3mP6/ eig1cLy//df6i2+gCUVxc6XJ5aHMJLl6rYurmSxPK1dGW165phJEgd2BzOuojDa2 9J52qhQCWh2KbSKHlDdCJ3mSRcQ0Nl5zEy2nL5Juv/bZ0OzKIwN6r+TS/BwbkCFV MHxTwUnAh4Jzya1FVWvs1N/sww61qkmYFlJvNWn++1T0mP/kyAEP+kYNu/+v0qEx zwVTq3xkGaXD19wq1/xCEa1zAZO1T3VDW42fXggdY2oAZuZhEzg2wmL9A2MvdMVV eEm7/VyZXAweXtTgmpWuWpxuPyZks5rPAvwCT9qTTro2oBuhvYRkbzfsw2EIROFZ Aza4BvpD3JCuiG8FFYdubzpFAcMK1enAL88EOPLV52pW8LmCdsg+aGNmKaexsd23 bL53E+JjDBFBshKpm1cKeAIErQihOuMRpzlHCVFncHrvwSTxn5g0EdzgZxUAv/BZ bMByftooknLQESP8/iO48HbpifbkTY/KTJWyIisKz+FVQb6qE9AiWoTt3sbwwn7f 7D2fXXESB4g+65DXMRr/ =No+1 -----END PGP SIGNATURE----- --NPukt5Otb9an/u20-- --===============0467931887== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KSW50ZWwtZ2Z4 IG1haWxpbmcgbGlzdApJbnRlbC1nZnhAbGlzdHMuZnJlZWRlc2t0b3Aub3JnCmh0dHA6Ly9saXN0 cy5mcmVlZGVza3RvcC5vcmcvbWFpbG1hbi9saXN0aW5mby9pbnRlbC1nZngK --===============0467931887==--