[i.MX]NFTS and exFAT support on Linux BSP

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

[i.MX]NFTS and exFAT support on Linux BSP

[i.MX]NFTS and exFAT support on Linux BSP

Customer is asking high-capacity external storage(for example >64GB) support on i.MX BSP, ext4 is ok for HC storage, but it can’t be supported by Windows.

Pls find NFTS and exFAT support status on Linux BSP below:

Updated test result on L5.4.70.2.3.0 and L6.1.22:

L5.4.70.2.3.0

1.You can enable ntfs support in kernel config as below,  ntfs can be mounted normally, but you can only modify existing file content in disk, you cant create/delete/rename file on disk.

> File systems > DOS/FAT/NT Filesystems

Lambert_0-1694955886098.jpeg

 

Log:

root@imx8mpevk:~# mount -t ntfs /dev/sda1 /mnt/fat/

[  662.732869] ntfs: volume version 3.1.

root@imx8mpevk:~# cp ntfs-3g /mnt/fat/

cp: cannot create regular file '/mnt/fat/ntfs-3g': Permission denied

root@imx8mpevk:~# ls /mnt/fat/

111.png  Image_org  System Volume Information  gpuinfo.sh

root@imx8mpevk:~# vi /mnt/fat/gpuinfo.sh

root@imx8mpevk:~# umount /mnt/fat/

root@imx8mpevk:~#

  1. ntfs file system can be accessed via ntfs-3g in user space as below

//build:

wget https://tuxera.com/opensource/ntfs-3g_ntfsprogs-2017.3.23.tgz

tar zxvf ntfs-3g_ntfsprogs-2017.3.23.tgz

cd ntfs-3g_ntfsprogs-2017.3.23/

source ../../sdk/environment-setup-aarch64-poky-linux

 

./configure --host=aarch64-linux --build=aarch64-poky-linux --disable-shared --enable-static

 

make

 

ls /src/ntfs-3g

 

//put it into rootfs

cp ntfs-3g /bin

 

//test log:

root@imx8mpevk:/#

[ 1058.724471] usb 1-1: USB disconnect, device number 4

[ 1062.058613] usb 1-1: new high-speed USB device number 5 using xhci-hcd

[ 1062.214029] usb-storage 1-1:1.0: USB Mass Storage device detected

[ 1062.220986] scsi host0: usb-storage 1-1:1.0

[ 1063.235871] scsi 0:0:0:0: Direct-Access     VendorCo ProductCode      2.00 PQ: 0 ANSI: 4

[ 1063.246185] sd 0:0:0:0: [sda] 15728640 512-byte logical blocks: (8.05 GB/7.50 GiB)

[ 1063.254023] sd 0:0:0:0: [sda] Write Protect is off

[ 1063.259164] sd 0:0:0:0: [sda] No Caching mode page found

[ 1063.264540] sd 0:0:0:0: [sda] Assuming drive cache: write through

[ 1063.296946]  sda: sda1

[ 1063.300860] sd 0:0:0:0: [sda] Attached SCSI removable disk

 

root@imx8mpevk:/# ntfs-3g /dev/sda1 /mnt/fat/

root@imx8mpevk:/# ls /mnt/fat/

README  System Volume Information  gpu.sh  gpuinfo.sh

root@imx8mpevk:/# cp /unit_tests/memtool /mnt/fat/

root@imx8mpevk:/# umount /mnt/fat/

root@imx8mpevk:/# ntfs-3g /dev/sda1 /mnt/fat/

root@imx8mpevk:/# ls /mnt/fat/

README  System Volume Information  gpu.sh  gpuinfo.sh  memtool

root@imx8mpevk:/#

 

3.exFAT is not supported on this BSP..

 

L6.1.22(you can check it on L5.15 and above, should be the same)

  1. You can enable ntfs support in kernel config as below, full features can be supported.

> File systems > DOS/FAT/EXFAT/NT Filesystems

Lambert_1-1694955886116.jpeg

 

  1. Pls use -t ntfs3 during mounting, otherwise it will be mounted as read-only
  2. Log:

root@imx8ulpevk:~# mount -t ntfs3 /dev/sda1 /mnt/fat/

root@imx8ulpevk:~# ls /mnt/fat/

111.png   Image_org  'System Volume Information'

root@imx8ulpevk:~#

root@imx8ulpevk:~# cp gpuinfo.sh /mnt/fat/

root@imx8ulpevk:~# umount /mnt/fat/

root@imx8ulpevk:~#

root@imx8ulpevk:~# mount -t ntfs3 /dev/sda1 /mnt/fat/

root@imx8ulpevk:~# ls /mnt/fat/

111.png   Image_org  'System Volume Information'   gpuinfo.sh

root@imx8ulpevk:~#

 

  1. exFAT has been supported in L6.1.22.

> File systems > DOS/FAT/EXFAT/NT Filesystems

Lambert_2-1694955886139.jpeg

 

/dev/sda1 on /run/media/sda1 type exfat (rw,relatime,fmask=0022,dmask=0022,iocharset=utf8,errors=remount-ro)

root@imx8ulpevk:~# ls /run/media/sda1

'Certificate of Completion.pdf'             carlife.MP4

Image_org                                  example.tflite

L5.4.70_2.3.0                              mx8mp_vpu.txt

NXP-5G.mp4                                 sd.mp4

'System Volume Information'                 vela.ini

android_p9.0.0_2.1.0-auto-ga_image_8qmek

root@imx8ulpevk:~# ls

Image_org  gpuinfo.sh

root@imx8ulpevk:~# cp gpuinfo.sh /run/media/sda1/

root@imx8ulpevk:~# umount /run/media/sda1

root@imx8ulpevk:~#

No ratings
Version history
Last update:
‎09-17-2023 06:05 AM
Updated by: