From: maitysanchayan@gmail.com (maitysanchayan at gmail.com)
To: linux-arm-kernel@lists.infradead.org
Subject: Query on using nvmem consumer API
Date: Thu, 18 Feb 2016 17:31:01 +0530 [thread overview]
Message-ID: <20160218120100.GA11366@Sanchayan-Arch.toradex.int> (raw)
Hello Srinivas,
I have a device tree node as follows
ocotp: ocotp at 400a5000 {
compatible = "fsl,vf610-ocotp";
#address-cells = <1>;
#size-cells = <1>;
reg = <0x400a5000 0xCF0>;
clocks = <&clks VF610_CLK_OCOTP>;
ocotp_cfg: cfg at 410 {
reg = <0x410 0x20>;
};
};
and a nvmem data consumer node as follows
soc-bus {
compatible = "fsl,vf610-soc-bus";
nvmem = <&ocotp>;
nvmem-names = "ocotp";
nvmem-cell = <&ocotp_cfg>;
nvmem-cell-names = "soc_id";
status = "okay";
};
I believe my device tree node entries are incorrect. I did like to
use the devm_nvmem_device/cell_get functions and then read using
cell or device consumer API's. I am looking at the NVMEM bindings
but it is not clear to me as to what the correct DT entries and
the corresponding arguments to devm_nvmem_device/cell_get should
be?
Can you help me out with as to what the correct entries and calls
should be?
I currently have
devm_nvmem_device_get(dev, "ocotp");
devm_nvmem_cell_get(dev, "soc_id");
where dev would be the soc-bus device.
Thanks & Regards,
Sanchayan.
next reply other threads:[~2016-02-18 12:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-18 12:01 maitysanchayan at gmail.com [this message]
2016-02-18 15:13 ` Query on using nvmem consumer API Srinivas Kandagatla
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=20160218120100.GA11366@Sanchayan-Arch.toradex.int \
--to=maitysanchayan@gmail.com \
--cc=linux-arm-kernel@lists.infradead.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).