From: David Lechner <david@lechnology.com>
To: linux-i2c@vger.kernel.org
Cc: David Lechner <david@lechnology.com>,
Bartosz Golaszewski <brgl@bgdev.pl>,
linux-kernel@vger.kernel.org
Subject: [PATCH] eeprom: at24: Change nvmem stride to 1
Date: Sun, 3 Dec 2017 19:54:41 -0600 [thread overview]
Message-ID: <1512352481-13613-1-git-send-email-david@lechnology.com> (raw)
This changes the nvmem stride to 1.
I am trying to use the nvram consumer apis to read a MAC address from an
eeprom that has an offset that is not a multiple of 4, which causes an
error currently.
Signed-off-by: David Lechner <david@lechnology.com>
---
drivers/misc/eeprom/at24.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/misc/eeprom/at24.c b/drivers/misc/eeprom/at24.c
index 305a7a4..f70d14c 100644
--- a/drivers/misc/eeprom/at24.c
+++ b/drivers/misc/eeprom/at24.c
@@ -880,7 +880,7 @@ static int at24_probe(struct i2c_client *client, const struct i2c_device_id *id)
at24->nvmem_config.reg_read = at24_read;
at24->nvmem_config.reg_write = at24_write;
at24->nvmem_config.priv = at24;
- at24->nvmem_config.stride = 4;
+ at24->nvmem_config.stride = 1;
at24->nvmem_config.word_size = 1;
at24->nvmem_config.size = chip.byte_len;
--
2.7.4
next reply other threads:[~2017-12-04 1:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-04 1:54 David Lechner [this message]
2017-12-04 17:44 ` [PATCH] eeprom: at24: Change nvmem stride to 1 Bartosz Golaszewski
2017-12-04 21:22 ` David Lechner
2017-12-06 9:44 ` Srinivas Kandagatla
2017-12-06 10:25 ` Bartosz Golaszewski
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=1512352481-13613-1-git-send-email-david@lechnology.com \
--to=david@lechnology.com \
--cc=brgl@bgdev.pl \
--cc=linux-i2c@vger.kernel.org \
--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).