From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mess.org header.i=@mess.org header.b="epC/ZO2u" Received: from gofer.mess.org (gofer.mess.org [IPv6:2a02:8011:d000:212::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AF767D54; Fri, 8 Dec 2023 09:01:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=mess.org; s=2020; t=1702054886; bh=0qFeptaVkBsmj5kyQRxzgnQQfozxB3P91OikGk9d6cE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=epC/ZO2uTJ4Zn/UcJOhtNv/kkrvpLb8GaMOQxaP/LYWGBRGqVpVS3v014yYA98UV8 MYvvYpaX6sQ1KgXK9ujvYCYF/cKElPsf3SMv3UNz6YEfpPhsDJbCLDN8sXtUAburNn piT2eVnZFFdm0+7GmL2FYH8JyfGSm5LmTowobSA/svH10Zd6jvaLK2zr//Clf9i88C Hf7pKQK+kH6T/Gxmh9hPcY3NnfUPbbGX0iNrEpMcUgIFa6cEQsUhDbHZEaGRKhE/yY ibu2Sbqosc+ncAf4kpC6j8xW+1W+q80DsMwDVZEYXZqQ7nXCAbFWYGYLxN83D1urBN 23VVLFxFlmwUw== Received: by gofer.mess.org (Postfix, from userid 1000) id 83520100091; Fri, 8 Dec 2023 17:01:26 +0000 (GMT) Date: Fri, 8 Dec 2023 17:01:26 +0000 From: Sean Young To: Thierry Reding Cc: linux-media@vger.kernel.org, linux-pwm@vger.kernel.org, Ivaylo Dimitrov , Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= , Florian Fainelli , Broadcom internal kernel review list , Ray Jui , Scott Branden , linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v6 3/4] pwm: bcm2835: allow pwm driver to be used in atomic context Message-ID: References: <179dc1ce85702a8b64b43c0e0df656b0c5e3ce30.1701248996.git.sean@mess.org> Precedence: bulk X-Mailing-List: linux-pwm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Fri, Dec 08, 2023 at 05:22:52PM +0100, Thierry Reding wrote: > On Wed, Nov 29, 2023 at 09:13:36AM +0000, Sean Young wrote: > > clk_get_rate() may do a mutex lock. Fetch the clock rate once, and prevent > > rate changes using clk_rate_exclusive_get(). > > > > Signed-off-by: Sean Young > > --- > > drivers/pwm/pwm-bcm2835.c | 31 +++++++++++++++++++++---------- > > 1 file changed, 21 insertions(+), 10 deletions(-) > > s/pwm/PWM/ in the subject. Although, I guess you could just drop the > "PWM" altogether because the subject prefix implies that this is for > PWM. $ git log --no-merges --oneline drivers/pwm/ | sed -r 's/^\w* ([^:]+): .*/\1/' | sort | uniq -c 1197 pwm 1 PWM ... The vast majority of the commits use pwm: as a prefix, only one uses PWM:. In fact if you look across the tree almost everywhere lower case is used for the prefix. I'm just trying to follow convention. Having said that, I think the prefix is totally redundant, it is clear from the commit files what they are affecting. I am not sure what it really adds. > Also, please capitalize after the subject prefix. $ git log --no-merges --oneline drivers/pwm/ | grep -E '^\w* ([^:]+): [A-Z]' | wc -l 217 $ git log --no-merges --oneline drivers/pwm/ | grep -E '^\w* ([^:]+): [a-z]' | wc -l 1069 Although not as clear, convention seems to be lower case for commits. The first line of a commit is not really a sentence, there is no trailing period. I am happy to oblige, just wanted to point this out. Sorry if this starts a bikeshed discussion. Thanks, Sean From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6EF4FC4167B for ; Fri, 8 Dec 2023 17:02:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=fuFgM5NBLOZRsOGh+OS5HYyE4xWz/aIp89FRyfAFedk=; b=FJ+UQJ09p91rp6 reYma1lGA5w2kkaeUU8fKTfZ9giGsQ7FxToRvIepC+9E7HpbewmXSNDLtwqXHyEQp95XExg+9OVsn nW4eupb/NhqmDYy6KCrPcg7fwHaoxD6Mn/iic0QQWyKwNsUZ0RLdwqnWCrPZr3igPUQSYMYmJHM5g C9G2uuhoJPHDlFmzAXKfAJnq0i0ZEqaluB8nvGH0+AZO4pS0MHozBdhN7MRSPhCb7N87qaQ/x57Uq wvpl0mS0eNDnf92FbBsx2q89q/U+7IAhG8eXwqPNke9rHH1jTyTBHUX+78KKr/HTI14NcV4MgVeJA xtx72kkvont9OPb0OlgQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rBeEM-00G6rP-0c; Fri, 08 Dec 2023 17:01:38 +0000 Received: from gofer.mess.org ([88.97.38.141]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rBeEJ-00G6qu-2s; Fri, 08 Dec 2023 17:01:37 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=mess.org; s=2020; t=1702054886; bh=0qFeptaVkBsmj5kyQRxzgnQQfozxB3P91OikGk9d6cE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=epC/ZO2uTJ4Zn/UcJOhtNv/kkrvpLb8GaMOQxaP/LYWGBRGqVpVS3v014yYA98UV8 MYvvYpaX6sQ1KgXK9ujvYCYF/cKElPsf3SMv3UNz6YEfpPhsDJbCLDN8sXtUAburNn piT2eVnZFFdm0+7GmL2FYH8JyfGSm5LmTowobSA/svH10Zd6jvaLK2zr//Clf9i88C Hf7pKQK+kH6T/Gxmh9hPcY3NnfUPbbGX0iNrEpMcUgIFa6cEQsUhDbHZEaGRKhE/yY ibu2Sbqosc+ncAf4kpC6j8xW+1W+q80DsMwDVZEYXZqQ7nXCAbFWYGYLxN83D1urBN 23VVLFxFlmwUw== Received: by gofer.mess.org (Postfix, from userid 1000) id 83520100091; Fri, 8 Dec 2023 17:01:26 +0000 (GMT) Date: Fri, 8 Dec 2023 17:01:26 +0000 From: Sean Young To: Thierry Reding Cc: linux-media@vger.kernel.org, linux-pwm@vger.kernel.org, Ivaylo Dimitrov , Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= , Florian Fainelli , Broadcom internal kernel review list , Ray Jui , Scott Branden , linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v6 3/4] pwm: bcm2835: allow pwm driver to be used in atomic context Message-ID: References: <179dc1ce85702a8b64b43c0e0df656b0c5e3ce30.1701248996.git.sean@mess.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231208_090136_085449_2D4FE30D X-CRM114-Status: GOOD ( 18.55 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Dec 08, 2023 at 05:22:52PM +0100, Thierry Reding wrote: > On Wed, Nov 29, 2023 at 09:13:36AM +0000, Sean Young wrote: > > clk_get_rate() may do a mutex lock. Fetch the clock rate once, and prevent > > rate changes using clk_rate_exclusive_get(). > > > > Signed-off-by: Sean Young > > --- > > drivers/pwm/pwm-bcm2835.c | 31 +++++++++++++++++++++---------- > > 1 file changed, 21 insertions(+), 10 deletions(-) > > s/pwm/PWM/ in the subject. Although, I guess you could just drop the > "PWM" altogether because the subject prefix implies that this is for > PWM. $ git log --no-merges --oneline drivers/pwm/ | sed -r 's/^\w* ([^:]+): .*/\1/' | sort | uniq -c 1197 pwm 1 PWM ... The vast majority of the commits use pwm: as a prefix, only one uses PWM:. In fact if you look across the tree almost everywhere lower case is used for the prefix. I'm just trying to follow convention. Having said that, I think the prefix is totally redundant, it is clear from the commit files what they are affecting. I am not sure what it really adds. > Also, please capitalize after the subject prefix. $ git log --no-merges --oneline drivers/pwm/ | grep -E '^\w* ([^:]+): [A-Z]' | wc -l 217 $ git log --no-merges --oneline drivers/pwm/ | grep -E '^\w* ([^:]+): [a-z]' | wc -l 1069 Although not as clear, convention seems to be lower case for commits. The first line of a commit is not really a sentence, there is no trailing period. I am happy to oblige, just wanted to point this out. Sorry if this starts a bikeshed discussion. Thanks, Sean _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel