All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wolfram Sang <wsa@kernel.org>
To: Tao Lan <taolan@huawei.com>
Cc: linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] i2c: hix5hd2: Add some debug enhancement for register access
Date: Sat, 17 Sep 2022 22:29:31 +0200	[thread overview]
Message-ID: <YyYuK1UD7CpZQoFr@shikoro> (raw)
In-Reply-To: <20220913124820.48715-1-taolan@huawei.com>

[-- Attachment #1: Type: text/plain, Size: 694 bytes --]

On Tue, Sep 13, 2022 at 12:48:20PM +0000, Tao Lan wrote:
> From: taolan <taolan@huawei.com>
> 
> Sometimes, to locate a fault, we need to know how the register is
> configured and whether the configuration is incorrect. Currently, no
> better method is available for analysis.
> 
> This patch tries to solve the problem by naming the registers and
> printing the accessed values.
> 
> Signed-off-by: taolan <taolan@huawei.com>

Such debug helpers are not suitable for upstream because they need quite
some resources for rare cases...

> +		pr_notice("write 0x%04x to %s\n", val, g_i2c_reg_name[idx >> 0x2].name);

... and using this loglevel you will flood logs of users.



[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2022-09-17 20:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-13 12:48 [PATCH] i2c: hix5hd2: Add some debug enhancement for register access Tao Lan
2022-09-17 20:29 ` Wolfram Sang [this message]
2022-09-20  7:35   ` taolan

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=YyYuK1UD7CpZQoFr@shikoro \
    --to=wsa@kernel.org \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=taolan@huawei.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.