Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp6038042rdb; Thu, 14 Dec 2023 06:54:20 -0800 (PST) X-Google-Smtp-Source: AGHT+IGlQWo1RUEoyL5nAOJdBEmRu1pSdpI04qxULyJazlA3h737Oou4p7r96ULJRxHiDhDtOyVK X-Received: by 2002:a17:90a:b288:b0:28a:69fc:b585 with SMTP id c8-20020a17090ab28800b0028a69fcb585mr6434318pjr.20.1702565660552; Thu, 14 Dec 2023 06:54:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702565660; cv=none; d=google.com; s=arc-20160816; b=Y+YWsnh37sErkJe0ClTCIfc4lJsbajpVjF+xjaQjwf8oPDOW8pplMQrSPibJXOJt+a 7/fUFZAKaGUGpCEuLrIriXDfmEmjM3YdiG4STTU53yqO+FQuRmbqSWeRtaCqO31RvFN6 YFy43m4vfNMWaP893dl/YBPhdxexzGxoG+UfUSjKmG+9phS/NPFjfdz7++g+F6DsNM6a SV2wTZSvLXEjjI8nlGpyIQxf6oZaJs9c/VdKfewXM+my9oYj/e0Bd3w6tt97Vj0lOOBM xEkVcSaL00w8y2Je9oF6b6U6sHRgiE5KLkK/MFgqru2LeGf624bf7ZS/cbo0DsUvwpUR r9Tw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:organization:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=wT+2b58HLdWV0QsfxvWCoPvaf6Msg34rd+ORldNeYY4=; fh=BiTih3HBn05OJvpBeKJCJhFgvirybBPBq65CdTV6sMo=; b=QRy/Ze19MKIcMrvxZJQrB0Ozzkr2pchX1ptalbijtd0dqUYAY/F3eSr+eAAhl+fKvV 8XzWFVuhLRudn9O1DREWawWsk7HkfKYCB9ku4iwCx2En0W+PZk7Y134gnA2vFiHSgnZg CZ8H+Td7gPjFUQypy+JYKFrKA7mDFkJEITuBeAj4anBPpZrVndCL5RQ6zz1g16C7kC87 E11XrwZ/2Nv6pwAzI11ZRZT4u7weSZpJw6FxE7mFjBoVpeO52x1vM3VubPUuE0XFDB2F HN7OzbtgYA0k3JMtvqciRZCzmHIXnicQHPgA+1V4xU9a+PBPwdtL0GdimzAU9y2PXvnj ASug== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id o12-20020a17090ac70c00b0028b18c29998si400440pjt.187.2023.12.14.06.54.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 Dec 2023 06:54:20 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id AEE9381C098A; Thu, 14 Dec 2023 06:54:15 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1573581AbjLNOxy (ORCPT + 99 others); Thu, 14 Dec 2023 09:53:54 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50388 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1573569AbjLNOxx (ORCPT ); Thu, 14 Dec 2023 09:53:53 -0500 Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.12]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1E8A2115; Thu, 14 Dec 2023 06:54:00 -0800 (PST) X-IronPort-AV: E=McAfee;i="6600,9927,10924"; a="2288527" X-IronPort-AV: E=Sophos;i="6.04,275,1695711600"; d="scan'208";a="2288527" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orvoesa104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Dec 2023 06:54:00 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10924"; a="897768677" X-IronPort-AV: E=Sophos;i="6.04,275,1695711600"; d="scan'208";a="897768677" Received: from smile.fi.intel.com ([10.237.72.54]) by orsmga004.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Dec 2023 06:53:58 -0800 Received: from andy by smile.fi.intel.com with local (Exim 4.97) (envelope-from ) id 1rDn63-00000005s6R-0Z65; Thu, 14 Dec 2023 16:53:55 +0200 Date: Thu, 14 Dec 2023 16:53:54 +0200 From: Andy Shevchenko To: Kent Gibson Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, brgl@bgdev.pl, linus.walleij@linaro.org Subject: Re: [PATCH v2 1/5] gpiolib: cdev: adopt scoped_guard() Message-ID: References: <20231214095814.132400-1-warthog618@gmail.com> <20231214095814.132400-2-warthog618@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Thu, 14 Dec 2023 06:54:15 -0800 (PST) On Thu, Dec 14, 2023 at 07:50:44PM +0800, Kent Gibson wrote: > On Thu, Dec 14, 2023 at 05:58:10PM +0800, Kent Gibson wrote: > > Use scoped_guard for critical sections rather than distinct > > lock/unlock pairs. > > It seems using guard() can further simplify cases where the scope extends > to the end of the function, so I'll replace those cases when I do v3. Ah, we are on the same page here! -- With Best Regards, Andy Shevchenko