Received: by 2002:ab2:1689:0:b0:1f7:5705:b850 with SMTP id d9csp803275lqa; Sun, 28 Apr 2024 05:15:41 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUkgQLi/7/8Zq3tRpByyl0QFnEVyzBFA1B8O7M+3+kfYz52NOfLxn2WCVRJD+F4Sl2Yq1apKleT4vCOmpi3eD8i8DdniL29R1p2u659nQ== X-Google-Smtp-Source: AGHT+IHO0nAZsBSc8vQHgqhHmvQy5tovDX/Y565LVLJpBGsM4X8ZrNyWAp6qmtINGxnv23DDnxHy X-Received: by 2002:a67:fc1a:0:b0:47a:71fc:bf78 with SMTP id o26-20020a67fc1a000000b0047a71fcbf78mr8320279vsq.16.1714306540671; Sun, 28 Apr 2024 05:15:40 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714306540; cv=pass; d=google.com; s=arc-20160816; b=QhIF+Hwia1DW+w8YWrju6vFamqIUA0WFJhs3FG8i6Rn85jKzF9PXKaJH3wQfiAom3H TbQHKeg+pzBMfxxllUg5bZdZY/FDTsQM7KWU/1p61QAaJqEW1yavcAxkLMlUTNQcQKqN zbKo/94fWpjt3v8aNC0LqBA2S8kYZxopmmHERPr0qTGVSpbv/mRy6ZdiSK06SRTMqF7O Yd2gx2fnXxWKgqOSlt+5GOLLXDApzou+teLsxx/32/m38GhvoAUhWMHk5wvVi2GJcinb jbowUTx+2HKBffO6/u5ExPK6Y+Icc94lLgN14GQ1AHd30sIzTsUzKrxb28yjmmtSCnFj 1OyA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date; bh=xSFn5TzsfhdKQqehHlr4xweG1c5gkaGdFhJiiKNoWis=; fh=ZBksoIi18njCRASYgr35KiruC+V87ztMdVFWWjAw4hU=; b=CJ6Q/xwlZRU12cg7qJFcE6iGp4u0MzrkT/onvEYxbwTWEzJqOwldu7Gry1A0v0ivYq xJw8J9tydCIoCP/aYUbJqVriJIjPCAo/sysQm86rXnSRI51UDap9ccGkXsetf7Irsg2k mFjuopAyKUhkPV/sV3GUVFJlC8xPCC02z7lwHWtPpQFqAJMt6cNjPkVP9KM47stuQoWE 0i4UuHvJmQnMQnyGY7YmHZFGYNAz0oL9xp7IUzBnvDn8oy8+4xUG0Pm3yGmylEEVp1ns gHElLnsG321h+7beLVfvw66aBBxHJv9lPBrJGWDPMD2UTlul46OMQ5/b6IAGmr/MZqsg CYNQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=pengutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-161417-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-161417-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id b11-20020ab06e8b000000b007efcf64ce08si786384uav.120.2024.04.28.05.15.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 28 Apr 2024 05:15:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-161417-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=pengutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-161417-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-161417-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 705961C20EC9 for ; Sun, 28 Apr 2024 12:15:39 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2F8CC6A8BE; Sun, 28 Apr 2024 12:15:36 +0000 (UTC) Received: from metis.whiteo.stw.pengutronix.de (metis.whiteo.stw.pengutronix.de [185.203.201.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E6A5A6A33F for ; Sun, 28 Apr 2024 12:15:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.203.201.7 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714306535; cv=none; b=F5aJYMfcO8SDUJLzS7axanZZr8KfkutrbJ2qY0I76xBnH5ADZ2DQlYGnyxEKaOEETizZq+VDtp53r886yhNGtXVWfPO/99qXAa1B/RxCMkoprElYMQZ2fRKPqcX8Df/xLiu9zhsCIjCzMNeiuL63fcIDdaUvnO+F4OphuZCKato= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714306535; c=relaxed/simple; bh=uwu9wbnRByZrueRW+DJVozCDP+NHMntKMf6BCMOKSDw=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=bPjLt5B9IGwo1bFno/9oMgLXK2KoIM5L1PIHoZMkoJqFmPDK3Ig1bBIARzHjx7pcw+1Yp5GIMdmRvDjlfroGBVnV7kYZViETMD9Ag/oKIwZejn9JH4j7etFVSsI6KQjYgw0EqgVD1asRf0AKFDWwxp2iqX2L2SYeA8Snv5rY+Mw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de; spf=pass smtp.mailfrom=pengutronix.de; arc=none smtp.client-ip=185.203.201.7 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=pengutronix.de Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1s13R3-0000Fv-3E; Sun, 28 Apr 2024 14:15:13 +0200 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s13R1-00EnNe-Ln; Sun, 28 Apr 2024 14:15:11 +0200 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.96) (envelope-from ) id 1s13R1-00Ao56-1u; Sun, 28 Apr 2024 14:15:11 +0200 Date: Sun, 28 Apr 2024 14:15:11 +0200 From: Uwe =?utf-8?Q?Kleine-K=C3=B6nig?= To: Wolfram Sang Cc: linux-i2c@vger.kernel.org, Patrice Chotard , Andi Shyti , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 07/15] i2c: st: use 'time_left' variable with wait_for_completion_timeout() Message-ID: References: <20240427203611.3750-1-wsa+renesas@sang-engineering.com> <20240427203611.3750-8-wsa+renesas@sang-engineering.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="v2id2b4lhcrh7vec" Content-Disposition: inline In-Reply-To: <20240427203611.3750-8-wsa+renesas@sang-engineering.com> X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org --v2id2b4lhcrh7vec Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hello Wolfram, On Sat, Apr 27, 2024 at 10:35:59PM +0200, Wolfram Sang wrote: > There is a confusing pattern in the kernel to use a variable named 'timeo= ut' to > store the result of wait_for_completion_timeout() causing patterns like: >=20 > timeout =3D wait_for_completion_timeout(...) > if (!timeout) return -ETIMEDOUT; >=20 > with all kinds of permutations. Use 'time_left' as a variable to make the= code > self explaining. >=20 > Signed-off-by: Wolfram Sang I like the improvement in general and looking at this driver in more detail this looks right. Reviewed-by: Uwe Kleine-K=F6nig Best regards Uwe =20 --=20 Pengutronix e.K. | Uwe Kleine-K=F6nig | Industrial Linux Solutions | https://www.pengutronix.de/ | --v2id2b4lhcrh7vec Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEP4GsaTp6HlmJrf7Tj4D7WH0S/k4FAmYuPc4ACgkQj4D7WH0S /k44DwgAtZhKVJj9zttG75ZuGtMUekDBwzS3shaaEzhuPTFiGDqNIvW1h9F8gYd5 eTYcl3CB1CQlLmyPjn2oQZWOMuXA7pxcT4dC4pjzEBxy265w5MTecW/27+gGnM9W Efll3bOYAG3XWy52dz1XaysUsX4vco3pofeMPbI2XO17FGhFCAHwcs0mkgtISCHE Gv6iIiUxgf3cY9UAfiGCPg5hugDhUbmy4Q+5pyDKWIySNqP7BgCXEGtF9zF4XLAw LIJIAxqsRelpPGwXpOWI53grJlEo7BRziMp8I7wpPBIC1J07rx3u03VJFwh1vh13 J2j2bOT1JHM5aGd86m8TPqOdYa/RJg== =iiGY -----END PGP SIGNATURE----- --v2id2b4lhcrh7vec--