Hi All,
I am using i.MX6q custom board with Linux 3.0.35.
When I try to copy/create files to SDHC card, I am getting, "Read-only file system" message.
I tried disabling the write protection pin, but still facing the same issue. In the boot loader it works fine.
Below is the board file information:
static const struct esdhc_platform_data mx6_sd3_data __initconst = {
.cd_gpio = MX6_SD3_CD;
//.wp_gpio = MX6_SD3_WP;
.always_present = 0;
//.support_18v = 1;
.keep_power_at_suspend = 1;
.support_8bit = 1;
.delay_line = 0;
.cd_type = ESDHC_CD_CONTROLLER;
};
Please help me to solve this issue.
With Regards,
Vishakh
Hi Vishakh,
Are you currently booting and loading file system from this SDHC card? If that is the case, then you can check your u-boot bootargs.
If it has following agrs:
"root=/dev/mmcblk2p2 rootwait ro"
Then you can change the "ro" to "rw" to make it writable.
Best regards,
Danwei Luo
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Vishakh M,
check once in your rootfs.
/etc/default# vi rcS in this file.
# Indicate whether the rootfs is intended to be read-only or not. |
# Setting ROOTFS_READ_ONLY to yes and rebooting will give you a read-only rootfs
# Normally you should not change this value. |
ROOTFS_READ_ONLY=no
thanks ,
lavanya
Hi bandarulavanya,
Thanks for the suggestion. ROOTFS_READ_ONLY is not set to 'yes'.
I found out that, in function mmc_blk_alloc_req of driver drivers/mmc/card/block.c, md->read_only is getting set.
But, I am not able to find out why this is being set. Any idea about this?
Also, we are using 4bit SDHC card in 8bit mode.
Thanks and Regards,
Vishakh
Hi Vishakh M,
have you checked your u boot boot args in that u r passing like
"mmcroot = /dev/mmcblkXpY rootwait ro " like this or "mmcroot = /dev/mmcblkXpY rootwait rw "
Thanks & Regards,
Lavanya
Hi bandarulavanya,
In boot args "rw" is set. And we are not using SDHC card to mount file system.
Further, micro SD card and eMMC are working fine and we are even able to mount file system.
Thanks and Regards,
Vishakh
Hi Vishakh
one can look at emmc configuration, it is used on sabresd board as sd4,
it also has not cd,wp signals. One can check with oscilloscope wp protection signal.
Could you try with official nxp sources
i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite, i.MX 6Solo and i.MX 6Sololite Linux BSP Source Code Files
linux-2.6-imx.git - Freescale i.MX Linux Tree
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------