Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1436431 > unrolled thread
| Started by | Bojan Prtvar <prtvar.b@gmail.com> |
|---|---|
| First post | 2016-07-04 14:00 +0200 |
| Last post | 2016-07-06 18:30 +0200 |
| Articles | 5 — 4 participants |
Back to article view | Back to linux.kernel
[PATCH] mmc: core: Extend sysfs with OCR register Bojan Prtvar <prtvar.b@gmail.com> - 2016-07-04 14:00 +0200
Re: [PATCH] mmc: core: Extend sysfs with OCR register Wolfram Sang <wsa@the-dreams.de> - 2016-07-04 16:20 +0200
Re: [PATCH] mmc: core: Extend sysfs with OCR register bojan prtvar <prtvar.b@gmail.com> - 2016-07-04 16:40 +0200
Re: [PATCH] mmc: core: Extend sysfs with OCR register Wolfram Sang <wsa@the-dreams.de> - 2016-07-04 16:50 +0200
Re: [PATCH] mmc: core: Extend sysfs with OCR register Ulf Hansson <ulf.hansson@linaro.org> - 2016-07-06 18:30 +0200
| From | Bojan Prtvar <prtvar.b@gmail.com> |
|---|---|
| Date | 2016-07-04 14:00 +0200 |
| Subject | [PATCH] mmc: core: Extend sysfs with OCR register |
| Message-ID | <rRaHE-596-13@gated-at.bofh.it> |
Make operation conditions register (OCR) easily accessible from user space.
Signed-off-by: Bojan Prtvar <prtvar.b@gmail.com>
---
Documentation/mmc/mmc-dev-attrs.txt | 1 +
drivers/mmc/core/mmc.c | 2 ++
2 files changed, 3 insertions(+)
diff --git a/Documentation/mmc/mmc-dev-attrs.txt b/Documentation/mmc/mmc-dev-attrs.txt
index caa5557..8163eca 100644
--- a/Documentation/mmc/mmc-dev-attrs.txt
+++ b/Documentation/mmc/mmc-dev-attrs.txt
@@ -28,6 +28,7 @@ All attributes are read-only.
preferred_erase_size Preferred erase size
raw_rpmb_size_mult RPMB partition size
rel_sectors Reliable write sector count
+ ocr Operation Conditions Register
Note on Erase Size and Preferred Erase Size:
diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c
index 5d438ad..1848334 100644
--- a/drivers/mmc/core/mmc.c
+++ b/drivers/mmc/core/mmc.c
@@ -727,6 +727,7 @@ MMC_DEV_ATTR(enhanced_area_offset, "%llu\n",
MMC_DEV_ATTR(enhanced_area_size, "%u\n", card->ext_csd.enhanced_area_size);
MMC_DEV_ATTR(raw_rpmb_size_mult, "%#x\n", card->ext_csd.raw_rpmb_size_mult);
MMC_DEV_ATTR(rel_sectors, "%#x\n", card->ext_csd.rel_sectors);
+MMC_DEV_ATTR(ocr, "%08x\n", card->ocr);
static ssize_t mmc_fwrev_show(struct device *dev,
struct device_attribute *attr,
@@ -762,6 +763,7 @@ static struct attribute *mmc_std_attrs[] = {
&dev_attr_enhanced_area_size.attr,
&dev_attr_raw_rpmb_size_mult.attr,
&dev_attr_rel_sectors.attr,
+ &dev_attr_ocr.attr,
NULL,
};
ATTRIBUTE_GROUPS(mmc_std);
--
2.8.0.GIT
[toc] | [next] | [standalone]
| From | Wolfram Sang <wsa@the-dreams.de> |
|---|---|
| Date | 2016-07-04 16:20 +0200 |
| Message-ID | <rRcT8-6F8-31@gated-at.bofh.it> |
| In reply to | #1436431 |
[Multipart message — attachments visible in raw view] — view raw
Bojan, On Mon, Jul 04, 2016 at 01:56:55PM +0200, Bojan Prtvar wrote: > Make operation conditions register (OCR) easily accessible from user space. > > Signed-off-by: Bojan Prtvar <prtvar.b@gmail.com> You described "what" above. Can you add the "why", too? Regards, Wolfram
[toc] | [prev] | [next] | [standalone]
| From | bojan prtvar <prtvar.b@gmail.com> |
|---|---|
| Date | 2016-07-04 16:40 +0200 |
| Message-ID | <rRdct-6NK-11@gated-at.bofh.it> |
| In reply to | #1436539 |
Hi, On Mon, Jul 4, 2016 at 4:13 PM, Wolfram Sang <wsa@the-dreams.de> wrote: >> Make operation conditions register (OCR) easily accessible from user space. >> > You described "what" above. Can you add the "why", too? > According to JEDEC v5.0 chapter 7 the OCR, CID and CSD registers carry the Device/content specific information. Registers CID and CSD are already exported through sysfs so let's make this interface complete by adding missing OCR register. Do I need to send v2 with updated change log? Regards, Bojan
[toc] | [prev] | [next] | [standalone]
| From | Wolfram Sang <wsa@the-dreams.de> |
|---|---|
| Date | 2016-07-04 16:50 +0200 |
| Message-ID | <rRdm9-6R8-11@gated-at.bofh.it> |
| In reply to | #1436559 |
[Multipart message — attachments visible in raw view] — view raw
> Registers CID and CSD are already exported through sysfs so let's make > this interface complete by adding missing OCR register. This sentence was missing for me, thanks. > Do I need to send v2 with updated change log? Ulf will tell us.
[toc] | [prev] | [next] | [standalone]
| From | Ulf Hansson <ulf.hansson@linaro.org> |
|---|---|
| Date | 2016-07-06 18:30 +0200 |
| Message-ID | <rRXS1-32X-9@gated-at.bofh.it> |
| In reply to | #1436431 |
On 4 July 2016 at 13:56, Bojan Prtvar <prtvar.b@gmail.com> wrote:
> Make operation conditions register (OCR) easily accessible from user space.
>
> Signed-off-by: Bojan Prtvar <prtvar.b@gmail.com>
Thanks, applied for next! Amended the changelog with the explanation
why this change is wanted.
Kind regards
Uffe
> ---
> Documentation/mmc/mmc-dev-attrs.txt | 1 +
> drivers/mmc/core/mmc.c | 2 ++
> 2 files changed, 3 insertions(+)
>
> diff --git a/Documentation/mmc/mmc-dev-attrs.txt b/Documentation/mmc/mmc-dev-attrs.txt
> index caa5557..8163eca 100644
> --- a/Documentation/mmc/mmc-dev-attrs.txt
> +++ b/Documentation/mmc/mmc-dev-attrs.txt
> @@ -28,6 +28,7 @@ All attributes are read-only.
> preferred_erase_size Preferred erase size
> raw_rpmb_size_mult RPMB partition size
> rel_sectors Reliable write sector count
> + ocr Operation Conditions Register
>
> Note on Erase Size and Preferred Erase Size:
>
> diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c
> index 5d438ad..1848334 100644
> --- a/drivers/mmc/core/mmc.c
> +++ b/drivers/mmc/core/mmc.c
> @@ -727,6 +727,7 @@ MMC_DEV_ATTR(enhanced_area_offset, "%llu\n",
> MMC_DEV_ATTR(enhanced_area_size, "%u\n", card->ext_csd.enhanced_area_size);
> MMC_DEV_ATTR(raw_rpmb_size_mult, "%#x\n", card->ext_csd.raw_rpmb_size_mult);
> MMC_DEV_ATTR(rel_sectors, "%#x\n", card->ext_csd.rel_sectors);
> +MMC_DEV_ATTR(ocr, "%08x\n", card->ocr);
>
> static ssize_t mmc_fwrev_show(struct device *dev,
> struct device_attribute *attr,
> @@ -762,6 +763,7 @@ static struct attribute *mmc_std_attrs[] = {
> &dev_attr_enhanced_area_size.attr,
> &dev_attr_raw_rpmb_size_mult.attr,
> &dev_attr_rel_sectors.attr,
> + &dev_attr_ocr.attr,
> NULL,
> };
> ATTRIBUTE_GROUPS(mmc_std);
> --
> 2.8.0.GIT
>
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web