linux-pwm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Nuno Sá" <noname.nuno@gmail.com>
To: "Uwe Kleine-König" <ukleinek@baylibre.com>,
	"Trevor Gamblin" <tgamblin@baylibre.com>
Cc: "Michael Hennerich" <michael.hennerich@analog.com>,
	"Nuno Sá" <nuno.sa@analog.com>,
	linux-pwm@vger.kernel.org
Subject: Re: [PATCH 2/2] pwm: axi-pwmgen: Make use of regmap_clear_bits()
Date: Fri, 07 Jun 2024 08:40:32 +0200	[thread overview]
Message-ID: <3755faec8dc7048da880ef6b924ed2e5a224bfef.camel@gmail.com> (raw)
In-Reply-To: <20240606164047.534741-6-u.kleine-koenig@baylibre.com>

On Thu, 2024-06-06 at 18:40 +0200, Uwe Kleine-König wrote:
> Instead of using regmap_update_bits() and passing val=0, better use
> regmap_clear_bits().
> 
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
> ---

Reviewed-by: Nuno Sa <nuno.sa@analog.com>

>  drivers/pwm/pwm-axi-pwmgen.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/pwm/pwm-axi-pwmgen.c b/drivers/pwm/pwm-axi-pwmgen.c
> index 1bd4150e0158..aac4f395497b 100644
> --- a/drivers/pwm/pwm-axi-pwmgen.c
> +++ b/drivers/pwm/pwm-axi-pwmgen.c
> @@ -156,7 +156,7 @@ static int axi_pwmgen_setup(struct regmap *regmap, struct
> device *dev)
>  	}
>  
>  	/* Enable the core */
> -	ret = regmap_update_bits(regmap, AXI_PWMGEN_REG_CONFIG,
> AXI_PWMGEN_REG_CONFIG_RESET, 0);
> +	ret = regmap_clear_bits(regmap, AXI_PWMGEN_REG_CONFIG,
> AXI_PWMGEN_REG_CONFIG_RESET);
>  	if (ret)
>  		return ret;
>  


  parent reply	other threads:[~2024-06-07  6:36 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-06 16:40 [PATCH 0/2] pwm: Make use of regmap_{set,clear}_bits() Uwe Kleine-König
2024-06-06 16:40 ` [PATCH 1/2] pwm: jz4740: Another few conversions to regmap_{set,clear}_bits() Uwe Kleine-König
2024-06-07 16:21   ` Paul Cercueil
2024-06-06 16:40 ` [PATCH 2/2] pwm: axi-pwmgen: Make use of regmap_clear_bits() Uwe Kleine-König
2024-06-06 17:09   ` Trevor Gamblin
2024-06-07  6:40   ` Nuno Sá [this message]
2024-06-10  5:53     ` Uwe Kleine-König
2024-06-10  8:00       ` Conor Dooley
2024-06-10  8:32         ` Uwe Kleine-König
2024-06-10  9:25           ` Conor Dooley
2024-06-10  8:10       ` Nuno Sá

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3755faec8dc7048da880ef6b924ed2e5a224bfef.camel@gmail.com \
    --to=noname.nuno@gmail.com \
    --cc=linux-pwm@vger.kernel.org \
    --cc=michael.hennerich@analog.com \
    --cc=nuno.sa@analog.com \
    --cc=tgamblin@baylibre.com \
    --cc=ukleinek@baylibre.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).