linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeongtae Park <jeongtae.park@gmail.com>
To: broonie@kernel.org, ldewangan@nvidia.com
Cc: linux-kernel@vger.kernel.org, jeongtae.park@gmail.com,
	jtp.park@samsung.com
Subject: [PATCH] regmap: fix the offset of register error log
Date: Thu,  1 Jul 2021 23:26:30 +0900	[thread overview]
Message-ID: <20210701142630.44936-1-jeongtae.park@gmail.com> (raw)

This patch fixes the offset of register error log
by using regmap_get_offset().

Signed-off-by: Jeongtae Park <jeongtae.park@gmail.com>
---
 drivers/base/regmap/regmap.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/base/regmap/regmap.c b/drivers/base/regmap/regmap.c
index fe3e38dd5324..2fc826e97591 100644
--- a/drivers/base/regmap/regmap.c
+++ b/drivers/base/regmap/regmap.c
@@ -1667,7 +1667,7 @@ static int _regmap_raw_write_impl(struct regmap *map, unsigned int reg,
 			if (ret) {
 				dev_err(map->dev,
 					"Error in caching of register: %x ret: %d\n",
-					reg + i, ret);
+					reg + regmap_get_offset(map, i), ret);
 				return ret;
 			}
 		}
-- 
2.25.1


             reply	other threads:[~2021-07-01 14:28 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-01 14:26 Jeongtae Park [this message]
2021-07-12 10:45 ` [PATCH] regmap: fix the offset of register error log Mark Brown

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=20210701142630.44936-1-jeongtae.park@gmail.com \
    --to=jeongtae.park@gmail.com \
    --cc=broonie@kernel.org \
    --cc=jtp.park@samsung.com \
    --cc=ldewangan@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    /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).