From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pavel Machek Subject: Re: [PATCHv2 05/11] serdev: add serdev_device_wait_until_sent Date: Wed, 22 Mar 2017 10:39:39 +0100 Message-ID: <20170322093939.GD26771@amd> References: <20170321223216.11733-1-sre@kernel.org> <20170321223216.11733-6-sre@kernel.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Q0rSlbzrZN6k9QnT" Return-path: Content-Disposition: inline In-Reply-To: <20170321223216.11733-6-sre-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org> Sender: devicetree-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Sebastian Reichel Cc: Marcel Holtmann , Gustavo Padovan , Johan Hedberg , Rob Herring , Samuel Thibault , Tony Lindgren , Greg Kroah-Hartman , Jiri Slaby , Mark Rutland , linux-bluetooth-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-serial-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: devicetree@vger.kernel.org --Q0rSlbzrZN6k9QnT Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi! > @@ -47,10 +48,13 @@ static void ttyport_write_wakeup(struct tty_port *por= t) > struct serport *serport =3D serdev_controller_get_drvdata(ctrl); > =20 > if (!test_and_clear_bit(TTY_DO_WRITE_WAKEUP, &port->tty->flags)) > - return; > + goto out; > =20 > if (test_bit(SERPORT_ACTIVE, &serport->flags)) > serdev_controller_write_wakeup(ctrl); > + > +out: I'd do "if (test_and_clear_bit() && test_bit()) serdev_()" here. Otherwise it looks fine. Acked-by: Pavel Machek Pavel =09 --=20 (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blo= g.html --Q0rSlbzrZN6k9QnT Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAljSRlsACgkQMOfwapXb+vLJBQCfRozd4ckjK/dqrfKBryXwMeAx aAcAnijtnM9S8FxpfTfaiHL6LWex2sZP =n4jE -----END PGP SIGNATURE----- --Q0rSlbzrZN6k9QnT-- -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html