mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
To: Liu Shixin <liushixin2@huawei.com>,
	Thierry Reding <thierry.reding@gmail.com>,
	Jonathan Hunter <jonathanh@nvidia.com>
Cc: linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org
Subject: Re: [PATCH 3/4] memory: tegra210-emc: use DEFINE_SHOW_ATTRIBUTE to simplify code
Date: Mon, 26 Sep 2022 11:26:33 +0200	[thread overview]
Message-ID: <b5252d24-0c7a-5e71-ec4b-d0460181acb8@linaro.org> (raw)
In-Reply-To: <20220922143344.3252585-4-liushixin2@huawei.com>

On 22/09/2022 16:33, Liu Shixin wrote:
> Use DEFINE_SHOW_ATTRIBUTE helper macro to simplify the code.
> No functional change.
> 
> Signed-off-by: Liu Shixin <liushixin2@huawei.com>
> ---
>  drivers/memory/tegra/tegra210-emc-core.c | 14 +-------------
>  1 file changed, 1 insertion(+), 13 deletions(-)
> 
> diff --git a/drivers/memory/tegra/tegra210-emc-core.c b/drivers/memory/tegra/tegra210-emc-core.c
> index cbe1a7723514..603b306daca1 100644
> --- a/drivers/memory/tegra/tegra210-emc-core.c
> +++ b/drivers/memory/tegra/tegra210-emc-core.c
> @@ -1621,20 +1621,8 @@ static int tegra210_emc_debug_available_rates_show(struct seq_file *s,
>  
>  	return 0;
>  }
> +DEFINE_SHOW_ATTRIBUTE(tegra210_emc_debug_available_rates);
>  
> -static int tegra210_emc_debug_available_rates_open(struct inode *inode,
> -						   struct file *file)
> -{
> -	return single_open(file, tegra210_emc_debug_available_rates_show,
> -			   inode->i_private);
> -}
> -
> -static const struct file_operations tegra210_emc_debug_available_rates_fops = {
> -	.open = tegra210_emc_debug_available_rates_open,
> -	.read = seq_read,
> -	.llseek = seq_lseek,
> -	.release = single_release,
> -};
>  

It looks you leave here two blank lines. If so, please fix it - only one
blank line.

>  static int tegra210_emc_debug_min_rate_get(void *data, u64 *rate)
>  {

Best regards,
Krzysztof


  reply	other threads:[~2022-09-26  9:28 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-22 14:33 [PATCH 0/4] memory: tegra: Use " Liu Shixin
2022-09-22 14:33 ` [PATCH 1/4] memory: tegra20-emc: use " Liu Shixin
2022-09-22 14:33 ` [PATCH 2/4] memory: tegra30-emc: " Liu Shixin
2022-09-22 14:33 ` [PATCH 3/4] memory: tegra210-emc: " Liu Shixin
2022-09-26  9:26   ` Krzysztof Kozlowski [this message]
2022-09-26 12:37     ` Liu Shixin
2022-09-22 14:33 ` [PATCH 4/4] memory: tegra186-emc: " Liu Shixin
2022-09-26  9:26 ` [PATCH 0/4] memory: tegra: Use " Krzysztof Kozlowski

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=b5252d24-0c7a-5e71-ec4b-d0460181acb8@linaro.org \
    --to=krzysztof.kozlowski@linaro.org \
    --cc=jonathanh@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=liushixin2@huawei.com \
    --cc=thierry.reding@gmail.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

all inboxes | Powered by JetHome®