From: Baruch Siach Date: Mon, 22 Sep 2014 07:12:51 +0000 (+0300) Subject: mmc: block: add newline to sysfs display of force_ro X-Git-Tag: v3.12.36~40 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=50bd4857c6a000f0da4bc4b144baf111910f6a46;p=platform%2Fkernel%2Flinux-stable.git mmc: block: add newline to sysfs display of force_ro commit 0031a98a85e9fca282624bfc887f9531b2768396 upstream. Make force_ro consistent with other sysfs entries. Fixes: 371a689f64b0d ('mmc: MMC boot partitions support') Cc: Andrei Warkentin Signed-off-by: Baruch Siach Signed-off-by: Ulf Hansson Signed-off-by: Jiri Slaby --- diff --git a/drivers/mmc/card/block.c b/drivers/mmc/card/block.c index 4e8212c714b1..2aea365e096e 100644 --- a/drivers/mmc/card/block.c +++ b/drivers/mmc/card/block.c @@ -260,7 +260,7 @@ static ssize_t force_ro_show(struct device *dev, struct device_attribute *attr, int ret; struct mmc_blk_data *md = mmc_blk_get(dev_to_disk(dev)); - ret = snprintf(buf, PAGE_SIZE, "%d", + ret = snprintf(buf, PAGE_SIZE, "%d\n", get_disk_ro(dev_to_disk(dev)) ^ md->read_only); mmc_blk_put(md);