Code Monkey home page Code Monkey logo

exfat-nofuse's People

Contributors

airend avatar benpicco avatar biergaizi avatar civil avatar dorimanx avatar ethanwu-syno avatar evan-a-a avatar faux123 avatar htruong avatar hyperb1iss avatar ian-abbott avatar ianw avatar icenowy avatar jacknorris avatar johnbeard avatar lianwei avatar libcg avatar lqs avatar lynxchaus avatar maksqwe avatar nwinc avatar philipl avatar piotrsok2 avatar ravageralpha avatar romantymoshyk avatar rxrz avatar ryleyangus avatar thypon avatar tonyho avatar torstehu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

exfat-nofuse's Issues

It makes corruptions to the filesystem

Even I made little modifications to the filesystem (eg: move one file from one directory to another), the windows chkdsk utility will report the filesystem has some errors.

C:\Windows\system32>chkdsk /f e:
The type of the file system is exFAT.
Volume Serial Number is 34BF-9407
Windows is verifying files and folders...
Volume label is DATA.
Corruption was found while examining files in directory \soft\Adobe............

Windows has made corrections to the file system.

I don't touch the files in this directory.

build error on openwrt

make[4]: Entering directory `/tmp/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/linux-3.10.2'
  CC [M]  /home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.o
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c: In function 'exfat_allow_set_time':
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:904:22: error: invalid operands to binary != (have 'kuid_t' and 'kuid_t')
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c: In function 'exfat_setattr':
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:980:18: error: invalid operands to binary != (have 'kuid_t' and 'uid_t')
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:982:18: error: invalid operands to binary != (have 'kgid_t' and 'gid_t')
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c: In function 'exfat_fill_inode':
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:1384:15: error: incompatible types when assigning to type 'kuid_t' from type 'uid_t'
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:1385:15: error: incompatible types when assigning to type 'kgid_t' from type 'gid_t'
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c: In function 'parse_options':
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:1752:15: error: incompatible types when assigning to type 'uid_t' from type 'kuid_t'
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:1753:15: error: incompatible types when assigning to type 'gid_t' from type 'kgid_t'
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c: In function 'exfat_read_root':
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:1883:15: error: incompatible types when assigning to type 'kuid_t' from type 'uid_t'
/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.c:1884:15: error: incompatible types when assigning to type 'kgid_t' from type 'gid_t'
make[5]: *** [/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/exfat_super.o] Error 1
make[4]: *** [_module_/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse] Error 2
make[4]: Leaving directory `/tmp/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/linux-3.10.2'
make[3]: *** [/home/sdysj/build/trunk/build_dir/target-mips_uClibc-0.9.33.2/linux-ar71xx_generic/exfat-nofuse/.built] Error 2
make[3]: Leaving directory `/home/sdysj/build/trunk/package/kernel/exfat-nofuse'
make[2]: *** [package/kernel/exfat-nofuse/compile] Error 2
make[2]: Leaving directory `/home/sdysj/build/trunk'
make[1]: *** [/home/sdysj/build/trunk/staging_dir/target-mips_uClibc-0.9.33.2/stamp/.package_compile] Error 2
make[1]: Leaving directory `/home/sdysj/build/trunk'
make: *** [world] Error 2

Code legalization finished! :)

Hi,

i have legalized the exfat code by merging Samsung source with all your hard work!

https://github.com/dorimanx/exfat-nofuse/commits/dev

feel free to pull the updates if you wish! i have added the driver to my kernel
now as GPL :)

in Samsung source they made some time convert functions differently and some bug fixes.
any way all that was in your git, is safe and added :)

Big thanks for all your and your friends work! lets make it even better!

exfat repair

how to repair the exfat file system in linux?
where can I download fsck_exfat source?

Tag releases in git

It'll be a lot easier for at least me, as user, to find stable releases if they had tags.

Can't export exfat partition as nfs share

On a archlinux system, I type these commands (My exfat partition is /dev/sda3):

mount /dev/sda3 /mnt/sda3 -o noatime,umask=000
mount --bind /mnt/sda3 /srv/nfs4/sda3
exportfs -arv

it will prompt:
exporting 192.168.89.0/24:/srv/nfs4/sda3
exportfs: /srv/nfs4/sda3 does not support NFS export
exporting 192.168.89.0/24:/srv/nfs4

my nfs exports file (/etc/exports) :
/srv/nfs4/ 192.168.89.0/24(rw,fsid=root,no_subtree_check)
/srv/nfs4/sda3 192.168.89.0/24(rw,no_subtree_check,nohide)

So I want to know how can I share my exfat partition though nfs?
ps: exfat-fuse works, but it's slow due to fuse.

error when mount exfat disk

In adb shell:

root@D6503:/ # insmod /system/lib/modules/exfat.ko
root@D6503:/ # mount -t exfat /dev/block/mmcblk1p1 /sdcard1                    
mount: Permission denied

Cannot mount the disk. When I use the Sony stock texfat modules it is OK.
My device is Z2 D6502

root@D6503:/ # uname -a                                                        
Linux localhost 3.4.0-perf-gbd72fa3-dirty #1 SMP PREEMPT Fri Feb 27 23:19:59 CST 2015 armv7l GNU/Linux
root@D6503:/ # modinfo exfat.ko                                                
filename:       exfat.ko
license:        GPL
description:    exFAT Filesystem Driver
depends:        
vermagic:       3.4.0-perf-gbd72fa3-dirty SMP preempt mod_unload modversions ARMv7 

Failed to build on arch linux raspberry pi kernel 3.17.4

Building AUR package exfat-dkms-git failed on kernel 3.17.4.
Worked fine on previous kernel.

Failure log:
Thu Nov 27 17:16:04 GMT 2014
make -C /usr/lib/modules/3.17.4-1-ARCH/build M=/var/lib/dkms/exfat/129.a862d50/build modules
make[1]: Entering directory '/usr/lib/modules/3.17.4-1-ARCH/build'
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_core.o
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_super.o
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_api.o
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_blkdev.o
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_cache.o
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_data.o
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_bitmap.o
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_nls.o
CC [M] /var/lib/dkms/exfat/129.a862d50/build/exfat_oal.o
In file included from /var/lib/dkms/exfat/129.a862d50/build/exfat_oal.c:46:0:
/var/lib/dkms/exfat/129.a862d50/build/exfat_oal.c: In function Б─≤tm_currentБ─≥:
include/linux/time.h:105:35: error: implicit declaration of function Б─≤get_secondsБ─≥ [-Werror=implicit-function-declaration]
#define CURRENT_TIME_SEC ((struct timespec) { get_seconds(), 0 })
^
/var/lib/dkms/exfat/129.a862d50/build/exfat_oal.c:127:23: note: in expansion of macro Б─≤CURRENT_TIME_SECБ─≥
struct timespec ts = CURRENT_TIME_SEC;
^
cc1: some warnings being treated as errors
scripts/Makefile.build:257: recipe for target '/var/lib/dkms/exfat/129.a862d50/build/exfat_oal.o' failed
make[2]: *** [/var/lib/dkms/exfat/129.a862d50/build/exfat_oal.o] Error 1
Makefile:1373: recipe for target 'module/var/lib/dkms/exfat/129.a862d50/build' failed
make[1]: *** [module/var/lib/dkms/exfat/129.a862d50/build] Error 2
make[1]: Leaving directory '/usr/lib/modules/3.17.4-1-ARCH/build'
Makefile:37: recipe for target 'all' failed
make: *** [all] Error 2

Kernel panic on android mtk 3.4.67

Module build and insmod work propertly, but on mount device device reboots
root@U65GT:/system/lib/modules # uname -a
Linux localhost 3.4.67 #1 SMP PREEMPT Tue Nov 11 14:26:57 CST 2014 armv7l GNU/Linux
root@U65GT:/system/lib/modules # cat /proc/filesystems
nodev sysfs
nodev rootfs
nodev bdev
nodev proc
nodev cgroup
nodev tmpfs
nodev debugfs
nodev sockfs
nodev pipefs
nodev anon_inodefs
nodev devpts
ext3
ext4
nodev ramfs
vfat
msdos
iso9660
fuseblk
nodev fuse
nodev fusectl
nodev selinuxfs
nodev mtd_inodefs
nodev functionfs
root@U65GT:/system/lib/modules # insmod exfat.ko ; dmesg | grep -i exfat
<6>[ 357.474296] 1[5567:insmod]exFAT: Version 1.2.9
root@U65GT:/system/lib/modules # cat /proc/filesystems
nodev sysfs
nodev rootfs
nodev bdev
nodev proc
nodev cgroup
nodev tmpfs
nodev debugfs
nodev sockfs
nodev pipefs
nodev anon_inodefs
nodev devpts
ext3
ext4
nodev ramfs
vfat
msdos
iso9660
fuseblk
nodev fuse
nodev fusectl
nodev selinuxfs
nodev mtd_inodefs
nodev functionfs
exfat
mount -t exfat /dev/block/vold/179:97 /mnt/secure/staging/

At this point, the device is restarted. After rebooting, I do

root@U65GT:/storage/sdcard0 # cat /proc/last_kmsg
ram console header, hw_status: 2, fiq step 40.
bin log 0.
ng : 0
[ 650.248919] (2)[13186:mount] .rt_throttled : 0
[ 650.248931] (2)[13186:mount] .rt_time : 0.000000
[ 650.248944] (2)[13186:mount] .rt_runtime : 700.000000
[ 650.248957] (2)[13186:mount]
[ 650.248961] (2)[13186:mount]rt_rq[7]:/apps
[ 650.248973] (2)[13186:mount] .rt_nr_running : 0
[ 650.248985] (2)[13186:mount] .rt_throttled : 0
[ 650.248997] (2)[13186:mount] .rt_time : 0.000000
[ 650.249010] (2)[13186:mount] .rt_runtime : 800.000000
[ 650.249022] (2)[13186:mount]
[ 650.249027] (2)[13186:mount]rt_rq[7]:/
[ 650.249038] (2)[13186:mount] .rt_nr_running : 0
[ 650.249050] (2)[13186:mount] .rt_throttled : 0
[ 650.249062] (2)[13186:mount] .rt_time : 0.000000
[ 650.249075] (2)[13186:mount] .rt_runtime : 950.000000
[ 650.249088] (2)[13186:mount]
[ 650.249092] (2)[13186:mount]runnable tasks:
[ 650.249097] (2)[13186:mount] task PID tree-key switches prio exec-runtime sum-exec sum-sleep
[ 650.249107] (2)[13186:mount]----------------------------------------------------------------------------------------------------------
[ 650.259260] (2)[13186:mount]==========================================================================================================
[ 650.259274] (2)[13186:mount]
[ 650.259435] (2)[13186:mount]-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ 650.616444] (2)[13186:mount][aee/ipanic] pc/lr/sp 0xb6ea90a0/0xb6f2b187/0xbed84b60
[ 650.616730] (2)[13186:mount][aee/ipanic] Dump stack range (0xbed84b60:0xbed85000)
[ 650.616758] (2)[13186:mount][aee/ipanic] copy_from_user ret(0x00000000),len:4a0
[ 650.625062] (2)[13186:mount]-=-=-=
[ 650.635890] (2)[13186:mount]-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ 650.971031] (2)[13186:mount]-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ 651.299878] (2)[13186:mount]-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ 651.635874] (2)[13186:mount]-=
[ 651.636498] (2)[13186:mount][aee/ipanic] aee-ipanic: Panic dump sucessfully written to emmc (detail len: 11537, console len: 262144)
[ 651.636520] (2)[13186:mount][aee/ipanic] android log : 0x46200, 0x40000, 0x0, 0x0, 0x86200, 0x40000, 0xc6200, 0x40000
[ 651.636537] (2)[13186:mount][aee/ipanic] mmprofile: offset:0x106200, len:0x0
[ 651.636552] (2)[13186:mount]Rebooting in 1 seconds..machine_shutdown: start, Proess(mount:13186)
[ 652.634267] (2)[13186:mount]Backtrace:
[ 652.634295] (2)[13186:mount][] (dump_backtrace+0x0/0x10c) from [] (dump_stack+0x18/0x1c)
[ 652.634310] (2)[13186:mount] r6:000003e8 r5:00000000 r4:000003e8 r3:c09e6018
[ 652.634352] (2)[13186:mount][] (dump_stack+0x0/0x1c) from [] (machine_shutdown+0x34/0x50)
[ 652.634381] (2)[13186:mount][] (machine_shutdown+0x0/0x50) from [] (machine_restart+0x14/0x64)
[ 652.634411] (2)[13186:mount][] (machine_restart+0x0/0x64) from [] (emergency_restart+0x1c/0x20)
[ 652.634426] (2)[13186:mount] r5:00000000 r4:000003e8
[ 652.634458] (2)[13186:mount][] (emergency_restart+0x0/0x20) from [] (panic+0x138/0x1a0)
[ 652.634485] (2)[13186:mount][] (panic+0x0/0x1a0) from [] (die+0x118/0x2ac)
[ 652.634499] (2)[13186:mount] r3:00000001 r2:ca6efb60 r1:20070193 r0:c0852b08
[ 652.634528] (2)[13186:mount] r7:00000001
[ 652.634556] (2)[13186:mount][] (die+0x0/0x2ac) from [] (__do_kernel_fault.part.10+0x5c/0x7c)
[ 652.634583] (2)[13186:mount][] (__do_kernel_fault.part.10+0x0/0x7c) from [] (do_page_fault+0x224/0x270)
[ 652.634599] (2)[13186:mount] r7:cb36e1c0 r3:ca6efd70
[ 652.634630] (2)[13186:mount][] (do_page_fault+0x0/0x270) from [] (do_translation_fault+0xa0/0xa8)
[ 652.634657] (2)[13186:mount][] (do_translation_fault+0x0/0xa8) from [] (do_DataAbort+0x78/0x110)
[ 652.634672] (2)[13186:mount] r7:c09da8e4 r6:ca6ee000 r5:00000005 r4:ca6efd70
[ 652.634713] (2)[13186:mount][] (do_DataAbort+0x0/0x110) from [] (__dabt_svc+0x38/0x60)
[ 652.634729] (2)[13186:mount]Exception stack(0xca6efd70 to 0xca6efdb8)
[ 652.634744] (2)[13186:mount]fd60: ffffffff c570c100 00000001 00000000
[ 652.634764] (2)[13186:mount]fd80: c570c0ec bf05fa1c cc7ca800 c5708000 00000001 00000003 00000000 ca6efe2c
[ 652.634782] (2)[13186:mount]fda0: 00000000 ca6efdb8 c00e8434 bf059254 60070013 ffffffff
[ 652.634795] (2)[13186:mount] r8:00000001 r7:ca6efda4 r6:ffffffff r5:60070013 r4:bf059254
[ 652.634867] (2)[13186:mount][] (exfat_fill_super+0x0/0x4b4 [exfat]) from [] (mount_bdev+0x174/0x1dc)
[ 652.634911] (2)[13186:mount][] (mount_bdev+0x0/0x1dc) from [] (exfat_fs_mount+0x20/0x28 [exfat])
[ 652.634955] (2)[13186:mount][] (exfat_fs_mount+0x0/0x28 [exfat]) from [] (mount_fs+0x4c/0x194)
[ 652.634984] (2)[13186:mount][] (mount_fs+0x0/0x194) from [] (vfs_kern_mount+0x50/0xe8)
[ 652.635010] (2)[13186:mount][] (vfs_kern_mount+0x0/0xe8) from [] (do_kern_mount+0x38/0xfc)
[ 652.635025] (2)[13186:mount] r8:d8566380 r7:00008000 r6:d8566900 r5:bf05fa24 r4:00000000
[ 652.635056] (2)[13186:mount]r3:00000000
[ 652.635084] (2)[13186:mount][] (do_kern_mount+0x0/0xfc) from [] (do_mount+0x334/0x854)
[ 652.635098] (2)[13186:mount] r8:d8566900 r7:00000020 r6:00000000 r5:00000000 r4:00008000
[ 652.635130] (2)[13186:mount]r3:00000000
[ 652.635157] (2)[13186:mount][] (do_mount+0x0/0x854) from [] (sys_mount+0x8c/0xc0)
[ 652.635183] (2)[13186:mount][] (sys_mount+0x0/0xc0) from [] (ret_fast_syscall+0x0/0x30)
[ 652.635198] (2)[13186:mount] r7:00000015 r6:00000000 r5:00000000 r4:00000000
[ 652.635226] (2)[13186:mount]machine_shutdown: done
[ 652.635236] (2)[13186:mount]Reboot:machine restart...
[ 652.637215] (2)[13186:mount]arch_reset: cmd = NULL
[ 652.637436] (2)[13186:mount]wdt_arch_reset called@Kernel mode =
[ 652.637902] (2)[13186:mount]wdt_arch_reset called MTK_WDT_MODE =5c
[ 652.638369] (2)[13186:mount]wdt_arch_reset called end MTK_WDT_MODE =22000014
-root@U65GT:/storage/sdcard0 #
root@U65GT:/storage/sdcard0 #
root@U65GT:/storage/sdcard0 #
root@U65GT:/storage/sdcard0 #
root@U65GT:/storage/sdcard0 # cat /proc/last_kmsg | grep -i exfat
[ 652.634867] (2)[13186:mount][] (exfat_fill_super+0x0/0x4b4 [exfat]) from [] (mount_bdev+0x174/0x1dc)
[ 652.634911] (2)[13186:mount][] (mount_bdev+0x0/0x1dc) from [] (exfat_fs_mount+0x20/0x28 [exfat])
[ 652.634955] (2)[13186:mount][] (exfat_fs_mount+0x0/0x28 [exfat]) from [] (mount_fs+0x4c/0x194)
root@U65GT:/storage/sdcard0 # cat /proc/kmsg | grep -i exfat
<6>[ 523.636458] (0)[7154:insmod]exFAT: Version 1.2.9
login as: root
SSHD Server
[email protected]'s password:
root@U65GT:/storage/sdcard0 # cat /proc/kmsg | grep -i exfat
<6>[ 311.875760] (1)[5656:insmod]exFAT: Version 1.2.9
<5>[ 390.990332] (0)[6042:adbd]type=1400 audit(1421307895.740:1211): avc: denied { setattr } for pid=6042 comm="adbd" name="exfat.ko" dev="mmcblk0p5" ino=106511 scontext=u:r:adbd:s0 tcontext=u:object_r:system_file:s0 tclass=file
<5>[ 391.188509] (0)[6117:busybox]type=1400 audit(1421307895.940:1212): avc: denied { setattr } for pid=6117 comm="busybox" name="exfat.ko" dev="mmcblk0p5" ino=106511 scontext=u:r:shell:s0 tcontext=u:object_r:system_file:s0 tclass=file
<6>[ 394.327102] (1)[6173:insmod]exFAT: Version 1.2.9
login as: root
SSHD Server
[email protected]'s password:
root@U65GT:/storage/sdcard0 # cat /proc/last_kmsg
ram console header, hw_status: 2, fiq step 40.
bin log 0.
throttled : 0
[ 402.396605] (1)[6286:mount] .rt_time : 0.000000
[ 402.396618] (1)[6286:mount] .rt_runtime : 800.000000
[ 402.396630] (1)[6286:mount]
[ 402.396634] (1)[6286:mount]rt_rq[7]:/
[ 402.396646] (1)[6286:mount] .rt_nr_running : 0
[ 402.396657] (1)[6286:mount] .rt_throttled : 0
[ 402.396670] (1)[6286:mount] .rt_time : 0.000000
[ 402.396683] (1)[6286:mount] .rt_runtime : 950.000000
[ 402.396695] (1)[6286:mount]
[ 402.396700] (1)[6286:mount]runnable tasks:
[ 402.396705] (1)[6286:mount] task PID tree-key switches prio exec-runtime sum-exec sum-sleep
[ 402.396714] (1)[6286:mount]----------------------------------------------------------------------------------------------------------
[ 402.406876] (1)[6286:mount]==========================================================================================================
[ 402.406890] (1)[6286:mount]
[ 402.407052] (1)[6286:mount]-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ 402.761289] (1)[6286:mount][aee/ipanic] pc/lr/sp 0xb6e940a0/0xb6f16187/0xbeb75b60
[ 402.761575] (1)[6286:mount][aee/ipanic] Dump stack range (0xbeb75b60:0xbeb76000)
[ 402.761603] (1)[6286:mount][aee/ipanic] copy_from_user ret(0x00000000),len:4a0
[ 402.769801] (1)[6286:mount][aee/ipanic] end dump native stack:
[ 402.769909] (1)[6286:mount]-=-=-=
[ 402.780649] (1)[6286:mount][aee/ipanic] ipanic_write_userspace: count 8463, strlen(NativeInfo):8463, off:286991
[ 402.780675] (1)[6286:mount]-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ 403.113318] (1)[6286:mount][aee/ipanic] ipanic_write_android_buf: dump droid log type 1, count 262144
[ 403.113344] (1)[6286:mount]-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ 403.444570] (1)[6286:mount][aee/ipanic] ipanic_write_android_buf: dump droid log type 3, count 262144
[ 403.444595] (1)[6286:mount]-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ 403.780763] (1)[6286:mount][aee/ipanic] ipanic_write_android_buf: dump droid log type 4, count 262144
[ 403.780782] (1)[6286:mount]-=
[ 403.781406] (1)[6286:mount][aee/ipanic] aee-ipanic: Panic dump sucessfully written to emmc (detail len: 11404, console len: 262144)
[ 403.781431] (1)[6286:mount][aee/ipanic] android log : 0x46200, 0x40000, 0x0, 0x0, 0x86200, 0x40000, 0xc6200, 0x40000
[ 403.781448] (1)[6286:mount][aee/ipanic] mmprofile: offset:0x106200, len:0x0
[ 403.781464] (1)[6286:mount]Rebooting in 1 seconds..machine_shutdown: start, Proess(mount:6286)
[ 404.779179] (1)[6286:mount]Backtrace:
[ 404.779209] (1)[6286:mount][] (dump_backtrace+0x0/0x10c) from [] (dump_stack+0x18/0x1c)
[ 404.779224] (1)[6286:mount] r6:000003e8 r5:00000000 r4:000003e8 r3:c09e6018
[ 404.779266] (1)[6286:mount][] (dump_stack+0x0/0x1c) from [] (machine_shutdown+0x34/0x50)
[ 404.779295] (1)[6286:mount][] (machine_shutdown+0x0/0x50) from [] (machine_restart+0x14/0x64)
[ 404.779326] (1)[6286:mount][] (machine_restart+0x0/0x64) from [] (emergency_restart+0x1c/0x20)
[ 404.779340] (1)[6286:mount] r5:00000000 r4:000003e8
[ 404.779372] (1)[6286:mount][] (emergency_restart+0x0/0x20) from [] (panic+0x138/0x1a0)
[ 404.779399] (1)[6286:mount][] (panic+0x0/0x1a0) from [] (die+0x118/0x2ac)
[ 404.779413] (1)[6286:mount] r3:00000001 r2:cbdfdb60 r1:20070193 r0:c0852b08
[ 404.779442] (1)[6286:mount] r7:00000001
[ 404.779470] (1)[6286:mount][] (die+0x0/0x2ac) from [] (__do_kernel_fault.part.10+0x5c/0x7c)
[ 404.779497] (1)[6286:mount][] (__do_kernel_fault.part.10+0x0/0x7c) from [] (do_page_fault+0x224/0x270)
[ 404.779512] (1)[6286:mount] r7:df39c540 r3:cbdfdd70
[ 404.779544] (1)[6286:mount][] (do_page_fault+0x0/0x270) from [] (do_translation_fault+0xa0/0xa8)
[ 404.779571] (1)[6286:mount][] (do_translation_fault+0x0/0xa8) from [] (do_DataAbort+0x78/0x110)
[ 404.779586] (1)[6286:mount] r7:c09da8e4 r6:cbdfc000 r5:00000005 r4:cbdfdd70
[ 404.779626] (1)[6286:mount][] (do_DataAbort+0x0/0x110) from [] (__dabt_svc+0x38/0x60)
[ 404.779642] (1)[6286:mount]Exception stack(0xcbdfdd70 to 0xcbdfddb8)
[ 404.779658] (1)[6286:mount]dd60: ffffffff ca434100 00000001 00000000
[ 404.779678] (1)[6286:mount]dd80: ca4340ec bf00fa3c c5babc00 ca430000 00000001 00000003 00000000 cbdfde2c
[ 404.779696] (1)[6286:mount]dda0: 00000000 cbdfddb8 c00e8434 bf00925c 60070013 ffffffff
[ 404.779709] (1)[6286:mount] r8:00000001 r7:cbdfdda4 r6:ffffffff r5:60070013 r4:bf00925c
[ 404.779782] (1)[6286:mount][] (exfat_fill_super+0x0/0x4c0 [exfat]) from [] (mount_bdev+0x174/0x1dc)
[ 404.779827] (1)[6286:mount][] (mount_bdev+0x0/0x1dc) from [] (exfat_fs_mount+0x20/0x28 [exfat])
[ 404.779871] (1)[6286:mount][] (exfat_fs_mount+0x0/0x28 [exfat]) from [] (mount_fs+0x4c/0x194)
[ 404.779899] (1)[6286:mount][] (mount_fs+0x0/0x194) from [] (vfs_kern_mount+0x50/0xe8)
[ 404.779925] (1)[6286:mount][] (vfs_kern_mount+0x0/0xe8) from [] (do_kern_mount+0x38/0xfc)
[ 404.779940] (1)[6286:mount] r8:d7d8f440 r7:00008000 r6:d7d8f7c0 r5:bf00fa44 r4:00000000
[ 404.779972] (1)[6286:mount]r3:00000000
[ 404.779999] (1)[6286:mount][] (do_kern_mount+0x0/0xfc) from [] (do_mount+0x334/0x854)
[ 404.780014] (1)[6286:mount] r8:d7d8f7c0 r7:00000020 r6:00000000 r5:00000000 r4:00008000
[ 404.780045] (1)[6286:mount]r3:00000000
[ 404.780072] (1)[6286:mount][] (do_mount+0x0/0x854) from [] (sys_mount+0x8c/0xc0)
[ 404.780099] (1)[6286:mount][] (sys_mount+0x0/0xc0) from [] (ret_fast_syscall+0x0/0x30)
[ 404.780113] (1)[6286:mount] r7:00000015 r6:00000000 r5:00000000 r4:00000000
[ 404.780141] (1)[6286:mount]machine_shutdown: done
[ 404.780151] (1)[6286:mount]Reboot:machine restart...
[ 404.782136] (1)[6286:mount]arch_reset: cmd = NULL
[ 404.782373] (1)[6286:mount]wdt_arch_reset called@Kernel mode =
[ 404.782857] (1)[6286:mount]wdt_arch_reset called MTK_WDT_MODE =5c
[ 404.783323] (1)[6286:mount]wdt_arch_reset called end MTK_WDT_MODE =22000014

Won't build with 4.1 + vfs-next

Fails to build with vfs-next tree due to https://git.kernel.org/cgit/linux/kernel/git/viro/vfs.git/commit/?h=for-next&id=680baacbca69d18a6d7315374ad83d05ac9c0977 commit

make -C /lib/modules/4.1.0-999-generic/build M=/var/lib/dkms/exfat/1.2.9-20150703/build modules
make[1]: Entering directory '/usr/src/linux-headers-4.1.0-999-generic'
CC [M] /var/lib/dkms/exfat/1.2.9-20150703/build/exfat_core.o
CC [M] /var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.o
/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.c: In function ‘exfat_follow_link’:
/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.c:1314:2: error: implicit declaration of function ‘nd_set_link’ [-Werror=implicit-function-declaration]
nd_set_link(nd, (char )(ei->target));
^
/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.c: At top level:
/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.c:1320:2: warning: initialization from incompatible pointer type
.follow_link = exfat_follow_link,
^
/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.c:1320:2: warning: (near initialization for ‘exfat_symlink_inode_operations.follow_link’)
/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.c:1679:2: warning: initialization from incompatible pointer type
.direct_IO = exfat_direct_IO,
^
/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.c:1679:2: warning: (near initialization for ‘exfat_aops.direct_IO’)
cc1: some warnings being treated as errors
scripts/Makefile.build:258: recipe for target '/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.o' failed
make[2]: *
* [/var/lib/dkms/exfat/1.2.9-20150703/build/exfat_super.o] Error 1
Makefile:1380: recipe for target 'module/var/lib/dkms/exfat/1.2.9-20150703/build' failed
make[1]: *** [module/var/lib/dkms/exfat/1.2.9-20150703/build] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-4.1.0-999-generic'
Makefile:36: recipe for target 'all' failed
make: *** [all] Error 2

kernel panic because of NULL pointer in linux 3.4, attached the dmesg.

1276.705430: <1> (01-28 07:22:33.304698634) Unable to handle kernel NULL pointer dereference at virtual address 00000010
1276.715086: <1> (01-28 07:22:33.314355613) pgd = d836c000
1276.720002: <1> (01-28 07:22:33.319271133) [00000010] *pgd=00000000
1276.725940: <0> (01-28 07:22:33.325209103) Internal error: Oops: 5 [#1] PREEMPT SMP ARM
1276.733609: <6> (01-28 07:22:33.332878269) Modules linked in:
1276.738900: <6> (01-28 07:22:33.338169310) CPU: 0 Tainted: G W (3.4.0-g9a3c983-dirty #3)
1276.747940: <6> (01-28 07:22:33.347208893) PC is at exfat_d_hashi+0x6c/0xc0
1276.754439: <6> (01-28 07:22:33.353708372) LR is at exfat_d_hashi+0x58/0xc0
1276.761131: <6> (01-28 07:22:33.360400142) pc : [] lr : [] psr: 80000013
1276.761145: <6> (01-28 07:22:33.360413944) sp : eb463de8 ip : 00000000 fp : b747111b
1276.777272: <6> (01-28 07:22:33.376541391) r10: 0000000b r9 : eb455017 r8 : eb455017
1276.784732: <6> (01-28 07:22:33.384001443) r7 : 00000000 r6 : eb463e1c r5 : 00000000 r4 : eb455003
1276.793679: <6> (01-28 07:22:33.392947692) r3 : 00000050 r2 : eb463ddc r1 : c0b3935e r0 : 0000003e
1276.802534: <6> (01-28 07:22:33.401803212) Flags: Nzcv IRQs on FIQs on Mode SVC_32 ISA ARM Segment user
1276.811992: <6> (01-28 07:22:33.411261545) Control: 10c5387d Table: 1836c06a DAC: 00000015
1276.819974: <6> (01-28 07:22:33.419243524)
1276.819985: <6> (01-28 07:22:33.419253940) PC: 0xc032f618:
1276.828912: <6> (01-28 07:22:33.428180763) f618 1affffef e3a00000 e8bd80f8 e3a00001 e8bd80f8 e92d45f8 e1a06002 e5903060
1276.839417: <6> (01-28 07:22:33.438685918) f638 e59f0098 e593222c e3043110 e7927003 eb169de6 e9960011 e1a01004 ebfffa53
1276.849917: <6> (01-28 07:22:33.449186282) f658 e1a05000 e59f0078 eb169de0 e59f0074 e1a01004 e1a02005 eb169ddc e3570000
1276.860422: <6> (01-28 07:22:33.459691438) f678 1a000001 e59f0060 eb169dd8 e0848005 e3a0a00b e3a05000 ea00000b e4d43001
1276.870926: <6> (01-28 07:22:33.470194979) f698 e5972010 e59f0044 e7d22003 e3520000 11a03002 e1a02223 e0823203 e0835005
1276.881429: <6> (01-28 07:22:33.480697999) f6b8 e005059a e1a01005 eb169dc8 e1540008 1afffff1 e5865000 e3a00000 e8bd85f8
1276.891934: <6> (01-28 07:22:33.491202998) f6d8 c0b39312 c0b39324 c0b39336 c0b3935e c0b39370 e92d4070 e1d230b0 e2830003
1276.902435: <6> (01-28 07:22:33.501704352) f6f8 e3530078 e1a00140 c2400001 e3130003 1a000004 e3530078 0a000002 e1d2c0b2
1276.912941: <6> (01-28 07:22:33.512209976)
1276.912952: <6> (01-28 07:22:33.512220497) LR: 0xc032f604:
1276.921881: <6> (01-28 07:22:33.521150236) f604 e15c0002 0a000001 ea000004 e3a03000 e1530005 1affffef e3a00000 e8bd80f8
1276.932384: <6> (01-28 07:22:33.531653569) f624 e3a00001 e8bd80f8 e92d45f8 e1a06002 e5903060 e59f0098 e593222c e3043110
1276.942888: <6> (01-28 07:22:33.542156745) f644 e7927003 eb169de6 e9960011 e1a01004 ebfffa53 e1a05000 e59f0078 eb169de0
1276.953390: <6> (01-28 07:22:33.552659297) f664 e59f0074 e1a01004 e1a02005 eb169ddc e3570000 1a000001 e59f0060 eb169dd8
1276.963896: <6> (01-28 07:22:33.563164713) f684 e0848005 e3a0a00b e3a05000 ea00000b e4d43001 e5972010 e59f0044 e7d22003
1276.974400: <6> (01-28 07:22:33.573669035) f6a4 e3520000 11a03002 e1a02223 e0823203 e0835005 e005059a e1a01005 eb169dc8
1276.984901: <6> (01-28 07:22:33.584170336) f6c4 e1540008 1afffff1 e5865000 e3a00000 e8bd85f8 c0b39312 c0b39324 c0b39336
1276.995406: <6> (01-28 07:22:33.594675075) f6e4 c0b3935e c0b39370 e92d4070 e1d230b0 e2830003 e3530078 e1a00140 c2400001
1277.005910: <6> (01-28 07:22:33.605178564)
1277.005920: <6> (01-28 07:22:33.605188929) SP: 0xeb463d68:
1277.014941: <6> (01-28 07:22:33.614210074) 3d68 00800000 c034daac c0f11740 c0220eb0 00000002 000000c1 c0f10f40 01fffeff
1277.025354: <6> (01-28 07:22:33.624623146) 3d88 00000000 c032f698 80000013 ffffffff eb463dd4 c08e4fd8 0000003e c0b3935e
1277.035888: <6> (01-28 07:22:33.635156739) 3da8 eb463ddc 00000050 eb455003 00000000 eb463e1c 00000000 eb455017 eb455017
1277.046358: <6> (01-28 07:22:33.645626739) 3dc8 0000000b b747111b 00000000 eb463de8 c032f684 c032f698 80000013 ffffffff
1277.056862: <6> (01-28 07:22:33.656131269) 3de8 c032f62c eb463eb0 00000000 00000740 eb455002 00000015 eb462000 c025f260
1277.067369: <6> (01-28 07:22:33.666637623) 3e08 d7310000 c08e4c58 16cd2c7f c023b9f4 eb463eb0 3e5f222a 00000015 eb455002
1277.077870: <6> (01-28 07:22:33.677139081) 3e28 eb463eb0 eb463eb0 00000000 00000040 eb455000 ffffff9c eb462000 00000000
1277.088375: <6> (01-28 07:22:33.687644028) 3e48 b747111b c0260390 eb463e58 eb462000 00000000 c024ea90 00000001 eb462000
1277.098879: <6> (01-28 07:22:33.698148038)
1277.098890: <6> (01-28 07:22:33.698158454) R1: 0xc0b392de:
1277.107819: <6> (01-28 07:22:33.707087985) 92dc 74697865 000a6465 653e363c 54414678 6556203a 6f697372 7325206e 2e31000a
1277.118320: <6> (01-28 07:22:33.717589130) 92fc 00392e32 61667865 6e695f74 5f65646f 68636163 70770065 2a2a3a63 2a2a2a2a
1277.128826: <6> (01-28 07:22:33.728094650) 931c 2a2a2a2a 000a2031 3a637077 2a2a2a2a 2a2a2a2a 20322a2a 7077000a 2a2a3a63
1277.139329: <6> (01-28 07:22:33.738598243) 933c 2a2a2a2a 2a2a2a2a 78652033 20746166 656d616e 2c73253a 6e656c20 2064253a
1277.149833: <6> (01-28 07:22:33.749102409) 935c 7077000a 74203a63 20736920 4c4c554e 000a2021 3a637077 2a2a2a2a 2a2a2a2a
1277.160336: <6> (01-28 07:22:33.759605638) 937c 20342a2a 61667865 61682074 253a6873 0a20756c 58455b00 5d544146 66786520
1277.170839: <6> (01-28 07:22:33.770107877) 939c 6c5f7461 756b6f6f 6e652070 65726574 5b000a64 41465845 65205d54 74616678
1277.181372: <6> (01-28 07:22:33.780640845) 93bc 6f6f6c5f 2070756b 74697865 31206465 455b000a 54414658 7865205d 5f746166
1277.191847: <6> (01-28 07:22:33.791116001) 93dc 6b6f6f6c 65207075 65746978 0a322064 58455b00 5d544146 66786520 6c5f7461
1277.202351: <6> (01-28 07:22:33.801619802)
1277.202361: <6> (01-28 07:22:33.801630271) R2: 0xeb463d5c:
1277.211291: <6> (01-28 07:22:33.810560114) 3d5c c0f10f40 be9d2000 00800000 00800000 c034daac c0f11740 c0220eb0 00000002
1277.221795: <6> (01-28 07:22:33.821063759) 3d7c 000000c1 c0f10f40 01fffeff 00000000 c032f698 80000013 ffffffff eb463dd4
1277.232298: <6> (01-28 07:22:33.831566988) 3d9c c08e4fd8 0000003e c0b3935e eb463ddc 00000050 eb455003 00000000 eb463e1c
1277.242801: <6> (01-28 07:22:33.842070581) 3dbc 00000000 eb455017 eb455017 0000000b b747111b 00000000 eb463de8 c032f684
1277.253304: <6> (01-28 07:22:33.852572663) 3ddc c032f698 80000013 ffffffff c032f62c eb463eb0 00000000 00000740 eb455002
1277.263807: <6> (01-28 07:22:33.863076569) 3dfc 00000015 eb462000 c025f260 d7310000 c08e4c58 16cd2c7f c023b9f4 eb463eb0
1277.274312: <6> (01-28 07:22:33.873581204) 3e1c 3e5f222a 00000015 eb455002 eb463eb0 eb463eb0 00000000 00000040 eb455000
1277.284816: <6> (01-28 07:22:33.884085474) 3e3c ffffff9c eb462000 00000000 b747111b c0260390 eb463e58 eb462000 00000000
1277.295319: <6> (01-28 07:22:33.894588286)
1277.295330: <6> (01-28 07:22:33.894598807) R4: 0xeb454f83:
1277.304261: <6> (01-28 07:22:33.903530160) 4f80 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.314763: <6> (01-28 07:22:33.914031774) 4fa0 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.325266: <6> (01-28 07:22:33.924534846) 4fc0 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.335770: <6> (01-28 07:22:33.935038752) 4fe0 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.346273: <6> (01-28 07:22:33.945541876) 5000 6f502f2e 435f7472 30324d4f 3836585f 78655f54 00746166 3000006f 2d71722f
1277.356776: <6> (01-28 07:22:33.956044845) 5020 74617473 65642f73 69745f66 5f72656d 3600736d 20302030 30203231 36393620
1277.367280: <6> (01-28 07:22:33.966548750) 5040 38313120 20302031 30322030 31203020 20302038 32343534 37323520 37393731
1277.377783: <6> (01-28 07:22:33.977052187) 5060 36203637 20353033 34393234 32373639 31203539 33343730 38303339 30312038
1277.388287: <6> (01-28 07:22:33.987556457) 5080 39333437 38383238 30323320 34323332 20343037 32303233 38323233 31203237
1277.398793: <6> (01-28 07:22:33.998062446)
1277.398804: <6> (01-28 07:22:33.998072967) R6: 0xeb463d9c:
1277.407827: <6> (01-28 07:22:34.7095935) 3d9c c08e4fd8 0000003e c0b3935e eb463ddc 00000050 eb455003 00000000 eb463e1c
1277.418061: <6> (01-28 07:22:34.17329893) 3dbc 00000000 eb455017 eb455017 0000000b b747111b 00000000 eb463de8 c032f684
1277.428506: <6> (01-28 07:22:34.27774996) 3ddc c032f698 80000013 ffffffff c032f62c eb463eb0 00000000 00000740 eb455002
1277.438894: <6> (01-28 07:22:34.38163017) 3dfc 00000015 eb462000 c025f260 d7310000 c08e4c58 16cd2c7f c023b9f4 eb463eb0
1277.449313: <6> (01-28 07:22:34.48582026) 3e1c 3e5f222a 00000015 eb455002 eb463eb0 eb463eb0 00000000 00000040 eb455000
1277.459729: <6> (01-28 07:22:34.58997859) 3e3c ffffff9c eb462000 00000000 b747111b c0260390 eb463e58 eb462000 00000000
1277.470146: <6> (01-28 07:22:34.69414577) 3e5c c024ea90 00000001 eb462000 eb463e7c eb456000 60000113 eb455000 eb463eb0
1277.480561: <6> (01-28 07:22:34.79830306) 3e7c eb455000 00000000 ffffff9c eb462000 00000000 b747111b c0260a2c eb455000
1277.490980: <6> (01-28 07:22:34.90249315)
1277.490991: <6> (01-28 07:22:34.90259784) R8: 0xeb454f97:
1277.499840: <6> (01-28 07:22:34.99109054) 4f94 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.510164: <6> (01-28 07:22:34.109432647) 4fb4 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.520666: <6> (01-28 07:22:34.119935564) 4fd4 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.531170: <6> (01-28 07:22:34.130438792) 4ff4 00000000 00000000 00000000 6f502f2e 435f7472 30324d4f 3836585f 78655f54
1277.541673: <6> (01-28 07:22:34.140941968) 5014 00746166 3000006f 2d71722f 74617473 65642f73 69745f66 5f72656d 3600736d
1277.552175: <6> (01-28 07:22:34.151443739) 5034 20302030 30203231 36393620 38313120 20302031 30322030 31203020 20302038
1277.562709: <6> (01-28 07:22:34.161978634) 5054 32343534 37323520 37393731 36203637 20353033 34393234 32373639 31203539
1277.573184: <6> (01-28 07:22:34.172452904) 5074 33343730 38303339 30312038 39333437 38383238 30323320 34323332 20343037
1277.583686: <6> (01-28 07:22:34.182955143) 5094 32303233 38323233 31203237 36343730 32343735 20302034 32313634 33203020
1277.594190: <6> (01-28 07:22:34.193458684)
1277.594200: <6> (01-28 07:22:34.193469205) R9: 0xeb454f97:
1277.603133: <6> (01-28 07:22:34.202401860) 4f94 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.613634: <6> (01-28 07:22:34.212903579) 4fb4 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.624138: <6> (01-28 07:22:34.223407276) 4fd4 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1277.634641: <6> (01-28 07:22:34.233910556) 4ff4 00000000 00000000 00000000 6f502f2e 435f7472 30324d4f 3836585f 78655f54
1277.645144: <6> (01-28 07:22:34.244413472) 5014 00746166 3000006f 2d71722f 74617473 65642f73 69745f66 5f72656d 3600736d
1277.655649: <6> (01-28 07:22:34.254918472) 5034 20302030 30203231 36393620 38313120 20302031 30322030 31203020 20302038
1277.666152: <6> (01-28 07:22:34.265420763) 5054 32343534 37323520 37393731 36203637 20353033 34393234 32373639 31203539
1277.676654: <6> (01-28 07:22:34.275923627) 5074 33343730 38303339 30312038 39333437 38383238 30323320 34323332 20343037
1277.687160: <6> (01-28 07:22:34.286429095) 5094 32303233 38323233 31203237 36343730 32343735 20302034 32313634 33203020
1277.697667: <0> (01-28 07:22:34.296936230) Process ls (pid: 2805, stack limit = 0xeb4622f0)
1277.705652: <0> (01-28 07:22:34.304920812) Stack: (0xeb463de8 to 0xeb464000)
1277.712432: <0> (01-28 07:22:34.311701020) 3de0: c032f62c eb463eb0 00000000 00000740 eb455002 00000015
1277.722939: <0> (01-28 07:22:34.322208207) 3e00: eb462000 c025f260 d7310000 c08e4c58 16cd2c7f c023b9f4 eb463eb0 3e5f222a
1277.733443: <0> (01-28 07:22:34.332712269) 3e20: 00000015 eb455002 eb463eb0 eb463eb0 00000000 00000040 eb455000 ffffff9c
1277.743947: <0> (01-28 07:22:34.343215498) 3e40: eb462000 00000000 b747111b c0260390 eb463e58 eb462000 00000000 c024ea90
1277.754448: <0> (01-28 07:22:34.353716799) 3e60: 00000001 eb462000 eb463e7c eb456000 60000113 eb455000 eb463eb0 eb455000
1277.764952: <0> (01-28 07:22:34.364220548) 3e80: 00000000 ffffff9c eb462000 00000000 b747111b c0260a2c eb455000 eb463f50
1277.775457: <0> (01-28 07:22:34.374726016) 3ea0: 00000000 eb463f38 ffffff9c c026241c d81e8cd0 e461f090 00000000 00000000
1277.785867: <0> (01-28 07:22:34.385135547) 3ec0: b7471000 00000000 00000000 e468c080 00000050 00000002 00000001 00000000
1277.796465: <0> (01-28 07:22:34.395733567) 3ee0: e52b5420 e52b5420 b7473000 00000817 c0e71a98 be9d2dbc eb463fb0 00000001
1277.806966: <0> (01-28 07:22:34.406234556) 3f00: b6f621e1 be9d344c b747111b c0100268 be9d34c8 eb463f50 be9d36ec 000000c4
1277.817467: <0> (01-28 07:22:34.416736378) 3f20: c0106184 c0262454 00000000 be9d36ec 00000000 c0259470 ffffff9c be9d36ec
1277.827972: <0> (01-28 07:22:34.427241221) 3f40: eb463f50 be9d34c8 b7472128 c02596b4 dabe60c0 00000000 00000000 00000000
1277.838478: <0> (01-28 07:22:34.437746950) 3f60: b7471048 00001068 dabe60c0 c0106184 eb462000 00000000 b747111b c0264ca4
1277.848981: <0> (01-28 07:22:34.448249449) 3f80: b7471048 00000000 00001068 00000000 b6f233b4 b7471038 b7471048 b6efbeb6
1277.859485: <0> (01-28 07:22:34.458754084) 3fa0: 00000001 c0106000 00000001 b7472128 be9d36ec be9d34c8 00000000 be9d3703
1277.869988: <0> (01-28 07:22:34.469257104) 3fc0: 00000001 b7472128 be9d36ec 000000c4 00000001 b6f621e1 b6f6bc78 b747111b
1277.880492: <0> (01-28 07:22:34.479761010) 3fe0: b6f23394 be9d34b0 b6f50671 b6ef5c5c 600f0010 be9d36ec 00000000 00000000
1277.891009: <6> (01-28 07:22:34.490278301) from
1277.902198: <6> (01-28 07:22:34.501466842) from
1277.913478: <6> (01-28 07:22:34.512746841) from
1277.924590: <6> (01-28 07:22:34.523858872) from
1277.936049: <6> (01-28 07:22:34.535318454) from
1277.947336: <6> (01-28 07:22:34.546604808) from
1277.958014: <6> (01-28 07:22:34.557283088) from
1277.968605: <6> (01-28 07:22:34.567874442) from
1277.979537: <0> (01-28 07:22:34.578806368) Code: e3a0a00b e3a05000 ea00000b e4d43001 (e5972010)
1277.988048: <4> (01-28 07:22:34.587317203) ---[ end trace d4a979d27c7e3503 ]---
1277.994935: <0> (01-28 07:22:34.594204944) Kernel panic - not syncing: Fatal exception
1279.002540: <3> (01-28 07:22:35.601815316) wcnss crash shutdown 0
1279.007368: <0> (01-28 07:22:35.606643000) Rebooting in 5 seconds..
1284.192254: <5> (01-28 07:22:40.791560142) Going down for restart now

vfat & fat12/16 support

I successfully use this driver for all the FAT filesystems I get: fat16, fat32, exfat... haven't tested it on fat12 but in theory it should also work.

Could you please associate this driver with the vfat/fat12/fat16 filesystem types also? I also believe it could be a good idea to rename the files, e.g.:

exfat_super.c -> fat_super.c ...

or

exfat_super.c -> super.c ...

It's not just an exFat driver :) It's a little bothering to mount with the -t exfat flag all the time.

And @dorimanx could you please change the heading of the repo from "Linux non-fuse read/write kernel driver for exFat file system." to "Linux non-fuse read/write kernel driver for exFat and VFat file systems."?

I'm going to ask the phoronix guy to benchmark this thing sometime soon.

Thank you!

Teaming up for NTFS

Hello, Developers!

We're teaming up to rewrite and complete the native NTFS Linux driver.

Please, drop a line to rzrx [a] hush.ai if you would like to be a part of the https://github.com/rxrz/NTFS-defused project.

@lqs and @benpicco: I sent you the invitation emails before, but not sure if you got them. Could you please let me know?

Thank you.

pulling drive, then umount will freak out driver

here is the pull from USB:
[ 52.987205] usb 2-1: USB disconnect, device number 2

here is mdev trying to umount the mountpoint because the drive disappeared:

[ 53.001854] [EXFAT] trying to unmount...
[ 53.003880] ------------[ cut here ]------------
[ 53.005149] WARNING: CPU: 3 PID: 344 at fs/exfat/exfat_blkdev.c:124 bdev_read+0xc9/0xd0()
[ 53.006425] [EXFAT] No bh, device seems wrong or to be ejected.
[ 53.007680] Modules linked in:
[ 53.008961] CPU: 3 PID: 344 Comm: umount Not tainted 4.3.3 #13
[ 53.010213] Hardware name: /D54250WYK, BIOS WYLPT10H.86A.0041.2015.0720.1108 07/20/2015
[ 53.011505] ffffffff81cf9a94 ffff880214defc60 ffffffff8131d7cf ffff880214defca8
[ 53.012782] ffff880214defc98 ffffffff81051b5d ffff8800d4f34000 ffff880214d90000
[ 53.014088] ffff880214d90050 0000000000000000 0000000000000001 ffff880214defcf8
[ 53.015359] Call Trace:
[ 53.016636] [] dump_stack+0x44/0x55
[ 53.017922] [] warn_slowpath_common+0x7d/0xb0
[ 53.019213] [] warn_slowpath_fmt+0x47/0x50
[ 53.020475] [] bdev_read+0xc9/0xd0
[ 53.021765] [] sector_read+0x45/0x80
[ 53.023043] [] fs_set_vol_flags+0x8d/0xa0
[ 53.024325] [] ffsUmountVol+0x27/0x90
[ 53.025571] [] FsUmountVol+0x36/0x60
[ 53.026861] [] exfat_put_super+0x25/0x90
[ 53.028105] [] generic_shutdown_super+0x65/0xe0
[ 53.029372] [] kill_block_super+0x22/0x70
[ 53.030616] [] exfat_debug_kill_sb+0x3b/0x40
[ 53.031906] [] deactivate_locked_super+0x39/0x70
[ 53.033156] [] deactivate_super+0x57/0x60
[ 53.034432] [] cleanup_mnt+0x3a/0x80
[ 53.035679] [] __cleanup_mnt+0xd/0x10
[ 53.036953] [] task_work_run+0x6e/0x90
[ 53.038180] [] prepare_exit_to_usermode+0x9e/0xc0
[ 53.039427] [] syscall_return_slowpath+0x3c/0x100
[ 53.040643] [] int_ret_from_sys_call+0x25/0x8f
[ 53.041892] ---[ end trace 30b0ae48bb81ab5d ]---

fat32 mounting

This is not only the exFat driver; it has been written to work with all filesystems of the FAT family.

As the next step to improve the driver I will need your help to debug and complete the fat12/16/32 support in this module.
Feel free to fork and modify the code, I may be able to patch this repo later on.

I would advise the merging of the exfat_core and exfat_fs into one fat.ko module, to replace the slow vfat driver from the linux tree and allow the full FAT support on linux.

Thank you.

Does not compile with 3.11-rc2

CC [M] exfat_super.o
exfat_super.c:365:2: error: unknown field ‘readdir’ specified in initializer
.readdir = exfat_readdir,
^
exfat_super.c:365:2: warning: initialization from incompatible pointer type [enabled by default]
exfat_super.c:365:2: warning: (near initialization for ‘exfat_dir_operations.write’) [enabled by default]
make[2]: *** [exfat_super.o] Error 1
make[1]: *** [module] Error 2
make[1]: Leaving directory `/usr/src/linux-3.11.0-1-ARCH'
make: *** [all] Error 2

Contact or sue Samsung to make them re-license this under the only valid license: GPLv2

here is a pretty good summary of the situation.

the gist:

  1. the samsung-proprietary license is invalid, as parts of this code were GPLv2-licensed before they edited it, and GPL’d code only allows re-licensing if all authors agree. (source) since it’s practically impossible to find the authors of the parts that were GPL-licensed, this couldn’t legally be re-licensed under a non-GPL license
  2. since the compiled product of this code has been released in phones (afaik), they have to give out its source if it’s GPL
  3. BUT: we are not allowed to relicense it: while it can’t exist under another license than GPLv2, samsung has to agree or be legally compelled to relicense it to that. in other words: the fact that no other license would be valid, does not magically license this under the one valid license.

so someone has to contact samsung and tell them this is a GPL violation, and someone (else) has to sue them if they don’t do that.

Does not compile with Kernel 4.5 (rc1)

Tried to compile (git Nov 10, 2015) with Kernel 4.5-rc1.

DKMS make.log for exfat-1.2.9+20151110 for kernel 4.5.0-040500rc1-generic (x86_64)
Fri Jan 29 19:12:27 CET 2016
make: Entering directory '/usr/src/linux-headers-4.5.0-040500rc1-generic'
LD /var/lib/dkms/exfat/1.2.9+20151110/build/built-in.o
CC [M] /var/lib/dkms/exfat/1.2.9+20151110/build/exfat_core.o
CC [M] /var/lib/dkms/exfat/1.2.9+20151110/build/exfat_super.o
/var/lib/dkms/exfat/1.2.9+20151110/build/exfat_super.c:1379:2: error: unknown field ‘follow_link’ specified in initializer
.follow_link = exfat_follow_link,
^
/var/lib/dkms/exfat/1.2.9+20151110/build/exfat_super.c:1379:17: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
.follow_link = exfat_follow_link,
^
/var/lib/dkms/exfat/1.2.9+20151110/build/exfat_super.c:1379:17: note: (near initialization for ‘exfat_symlink_inode_operations.create’)
scripts/Makefile.build:258: recipe for target '/var/lib/dkms/exfat/1.2.9+20151110/build/exfat_super.o' failed
make[1]: *** [/var/lib/dkms/exfat/1.2.9+20151110/build/exfat_super.o] Error 1
Makefile:1391: recipe for target 'module/var/lib/dkms/exfat/1.2.9+20151110/build' failed
make: *** [module/var/lib/dkms/exfat/1.2.9+20151110/build] Error 2
make: Leaving directory '/usr/src/linux-headers-4.5.0-040500rc1-generic'

d_type

Add support for d_type info so it can be used as a upper filesystem for OverlayFS

No licensing?

Please, add a proper license to your code, everybody seems to assume it's GPL but you better clarify it to avoid confusion and possible future problems.

Thanks!

No dokumentation for CONFIG_EXFAT_DELAYED_SYNC

I want to use this code on a mobile phone but fear risk of data loss or corruption when not unmounting correctly (lazy pulling out sd card). I can't do "mount -o flush", so I looked at the codes a bit and found CONFIG_EXFAT_DELAYED_SYNC instead but this variable is not commented at any place.

Now from the name and with common sense I would say it delays a sync, so it's the opposite of what I want but when I look at the codes I see this

ifdef CONFIG_EXFAT_DELAYED_SYNC

fs_sync(sb, 0);
fs_set_vol_flags(sb, VOL_CLEAN);

endif

which looks as it is exactly what I want.

Now I'm not that experienced and don't want others to risk their data, so could you please tell me what the variable does exactly, at best comment the variable (at exfat-config.h) ?

Bonus question: To activate the code (the ifdef condition gets true) I have to set the variable from 0 to 1, right?

Compilation on raspberrypi

Hi dorimanx,

After commit cda06f6, the compilation on my raspberrypi fails with the error

jclaassen@raspberrypi:~/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91$ make
make -C /lib/modules/3.12.22+/build M=/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91 modules
make[1]: Entering directory `/home/jclaassen/linux-1981ddebd4d3108cc942680a75ea151a479d65a8'
  CC [M]  /home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_core.o
  CC [M]  /home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.o
/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c: In function ‘exfat_direct_IO’:
/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c:1604:6: warning: passing argument 4 of ‘blockdev_direct_IO’ from incompatible pointer type [enabled by default]
In file included from include/linux/pagemap.h:8:0,
                 from /home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c:57:
include/linux/fs.h:2480:23: note: expected ‘const struct iovec *’ but argument is of type ‘struct iov_iter *’
/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c:1604:6: warning: passing argument 6 of ‘blockdev_direct_IO’ makes integer from pointer without a cast [enabled by default]
In file included from include/linux/pagemap.h:8:0,
                 from /home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c:57:
include/linux/fs.h:2480:23: note: expected ‘long unsigned int’ but argument is of type ‘int (*)(struct inode *, sector_t,  struct buffer_head *, int)’
/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c:1604:6: error: too few arguments to function ‘blockdev_direct_IO’
In file included from include/linux/pagemap.h:8:0,
                 from /home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c:57:
include/linux/fs.h:2480:23: note: declared here
/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c: At top level:
/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c:1662:2: warning: initialization from incompatible pointer type [enabled by default]
/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.c:1662:2: warning: (near initialization for ‘exfat_aops.direct_IO’) [enabled by default]
make[2]: *** [/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91/exfat_super.o] Error 1
make[1]: *** [_module_/home/jclaassen/exfat-nofuse-74331fe5d06253e0904f7fa5bf72bebc58d6df91] Error 2
make[1]: Leaving directory `/home/jclaassen/linux-1981ddebd4d3108cc942680a75ea151a479d65a8'
make: *** [all] Error 2

Any ideas on this pointer type? a >= that is too complicated? Strange.
Kind regards,

Error when compiling on Debian Wheezy amd64: incompatible type for argument 3 of ‘utf8s_to_utf16s’

I am seeing the following errors when compiling on Debian Wheezy amd64:

$ make
/usr/src/linux-headers-3.2.0-4-common/scripts/Makefile.build:44: /usr/src/linux-headers-3.2.0-4-common/scripts/basic/Makefile: No such file or directory
make[4]: *** No rule to make target `/usr/src/linux-headers-3.2.0-4-common/scripts/basic/Makefile'.  Stop.
make[3]: *** [scripts_basic] Error 2
make -C /lib/modules/3.2.0-4-amd64/build M=/home/benjamin/Repos/exfat-nofuse modules
make[1]: Entering directory `/usr/src/linux-headers-3.2.0-4-amd64'
  CC [M]  /home/benjamin/Repos/exfat-nofuse/exfat_nls.o
/home/benjamin/Repos/exfat-nofuse/exfat_nls.c: In function ‘nls_cstring_to_uniname’:
/home/benjamin/Repos/exfat-nofuse/exfat_nls.c:357:3: error: incompatible type for argument 3 of ‘utf8s_to_utf16s’
/usr/src/linux-headers-3.2.0-4-common/include/linux/nls.h:55:12: note: expected ‘enum utf16_endian’ but argument is of type ‘u16 *’
/home/benjamin/Repos/exfat-nofuse/exfat_nls.c:357:3: error: too few arguments to function ‘utf8s_to_utf16s’
/usr/src/linux-headers-3.2.0-4-common/include/linux/nls.h:55:12: note: declared here
make[4]: *** [/home/benjamin/Repos/exfat-nofuse/exfat_nls.o] Error 1
make[3]: *** [_module_/home/benjamin/Repos/exfat-nofuse] Error 2
make[2]: *** [sub-make] Error 2
make[1]: *** [all] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.2.0-4-amd64'
make: *** [all] Error 2

submit exfat to staging

Are you planning to submit the exfat to the mainline kernel, preferable the staging area?

I've prepared a patch to do so, but maybe you are more familiar with the code, so would you rather do that?

CLEANED.

CLEANED BY OWNER.
I have asked no CHAT.

wrong behaviour of directory link

I think exfat doesn't have support for file & directory link, but with this driver, you may create the links.

for example, I have a "foo" directory and foo\bar.dat file.
you may type

ln -s test foo

you will see a wrong symbolic link "temp" inside the foo directory.

and

ln -s bar.dat tt

also works.

Maybe these two should be disabled?

Kernel crashes when navigate to some folder

dmesg

[ 3022.241287] exFAT: Version 1.2.8
[ 3022.241633] [EXFAT] trying to mount...
[ 3024.336761] [EXFAT] mounted successfully
[ 3159.785976] BUG: unable to handle kernel NULL pointer dereference at 0000000000000018
[ 3159.787645] IP: [] nls_dosname_to_uniname+0x12b/0x1c0 [exfat]
[ 3159.788401] PGD 0
[ 3159.788401] Oops: 0000 [#1] PREEMPT SMP
[ 3159.788401] Modules linked in: nls_utf8 exfat(O) ctr ccm i915 arc4 iwldvm mac80211 snd_hda_codec_conexant snd_hda_codec_generic drm_kms_helr mei_me mei e1000e mousedev joydev wmi drm i2c_algo_bit coretemp kvm_intel iwlwifi iTCO_wdt iTCO_vendor_support kvm snd_hda_intel i2c_i801 pckr snd_hda_codec thinkpad_acpi microcode nvram evdev mac_hid led_class psmouse ptp lpc_ich cfg80211 hid_generic hwmon snd_hwdep rfkill serio_r snd_pcm snd_timer snd soundcore i2c_core shpchp pps_core intel_agp thermal intel_gtt battery hdaps(O) ac tpm_tis tpm video button acpi_cpufreprocessor tp_smapi(O) thinkpad_ec(O) ext4 crc16 mbcache jbd2 usbhid hid sd_mod crc_t10dif crct10dif_common atkbd libps2 ahci libahci libata sc_mod ehci_pci uhci_hcd ehci_hcd usbcore usb_common i8042 serio
[ 3159.788401] CPU: 0 PID: 1717 Comm: pool Tainted: G O 3.14.1-1-ARCH #1
[ 3159.788401] Hardware name: LENOVO 74574AC/74574AC, BIOS 6DET72WW (3.22 ) 10/25/2012
[ 3159.788401] task: ffff8800b50513a0 ti: ffff8800b48da000 task.ti: ffff8800b48da000
[ 3159.788401] RIP: 0010:[] [] nls_dosname_to_uniname+0x12b/0x1c0 [exfat]
[ 3159.788401] RSP: 0018:ffff8800b48db808 EFLAGS: 00010282
[ 3159.788401] RAX: 0000000000000085 RBX: ffff8800b48db8c4 RCX: 0000000000000000
[ 3159.788401] RDX: ffff8800b48db8c4 RSI: 0000000000000006 RDI: ffff8800b48db80b
[ 3159.788401] RBP: ffff8800b48db848 R08: ffff8800b48db867 R09: 00000000ffffffda
[ 3159.788401] R10: 000000000000000c R11: ffffffffa0830199 R12: 0000000000000000
[ 3159.788401] R13: 0000000000000000 R14: 0000000000000005 R15: ffff8800b48dbac2
[ 3159.788401] FS: 00007fadf0e8d700(0000) GS:ffff8801bbc00000(0000) knlGS:0000000000000000
[ 3159.788401] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 3159.788401] CR2: 0000000000000018 CR3: 00000000b4909000 CR4: 00000000000407f0
[ 3159.788401] Stack:
[ 3159.788401] 2d10d13a8583a75c 001b06122e866134 0000000084c4c3d1 ffff8800b4d2d800
[ 3159.788401] ffff8800b48dbb58 ffff8801ae8d0000 ffff880198ca10e0 ffff8801a5c06ba8
[ 3159.788401] ffff8800b48db870 ffffffffa0830acc 10d13a85b48dbb58 301b06128661342d
[ 3159.788401] Call Trace:
[ 3159.788401] [] get_uni_name_from_dos_entry+0x4c/0x70 [exfat]
[ 3159.788401] [] ffsReadDir+0x517/0x5d0 [exfat]
[ 3159.788401] [] ? load_balance+0x174/0x890
[ 3159.788401] [] ? update_curr+0x80/0x190
[ 3159.788401] [] ? update_cfs_shares+0xb1/0x100
[ 3159.788401] [] FsReadDir+0x47/0x60 [exfat]
[ 3159.788401] [] exfat_readdir+0x135/0x420 [exfat]
[ 3159.788401] [] ? __schedule+0x3c9/0x900
[ 3159.788401] [] ? slow_dentry_cmp+0x29/0x33
[ 3159.788401] [] ? timerqueue_add+0x60/0xb0
[ 3159.788401] [] ? enqueue_hrtimer+0x25/0xb0
[ 3159.788401] [] ? __hrtimer_start_range_ns+0x1e4/0x3d0
[ 3159.788401] [] ? timerqueue_del+0x24/0x70
[ 3159.788401] [] ? __remove_hrtimer+0x46/0xa0
[ 3159.788401] [] ? hrtimer_try_to_cancel+0x85/0x100
[ 3159.788401] [] ? hrtimer_cancel+0x1a/0x30
[ 3159.788401] [] ? futex_wait+0x1b2/0x290
[ 3159.788401] [] ? get_futex_key+0x1cf/0x2b0
[ 3159.788401] [] ? futex_wake+0x71/0x140
[ 3159.788401] [] ? do_futex+0x109/0xac0
[ 3159.788401] [] iterate_dir+0xa5/0xe0
[ 3159.788401] [] SyS_getdents+0x8a/0x110
[ 3159.788401] [] ? fillonedir+0xd0/0xd0
[ 3159.788401] [] ? device_not_available+0x1e/0x30
[ 3159.788401] [] system_call_fastpath+0x16/0x1b
[ 3159.788401] Code: 39 fb 0f 84 80 00 00 00 48 8d 45 c3 49 63 fc 48 01 c7 0f b6 07 84 c0 74 6f b9 00 00 00 00 66 89 0b 79 cd 48 89 da be 06 000 00 <41> ff 55 18 85 c0 79 c5 48 c7 c6 d0 d1 83 a0 48 c7 c7 86 da 83
[ 3159.788401] RIP [] nls_dosname_to_uniname+0x12b/0x1c0 [exfat]
[ 3159.788401] RSP
[ 3159.788401] CR2: 0000000000000018
[ 3159.860748] ---[ end trace 05ced4a6822fbf55 ]---

exfat-nofuse has problem with mips plantfrom

dear all,

Today I cross compile the exfat to my mipsl plantfrom, openwrt base system..
I try to get mounted device info, it told me has a unhandled kernel unaligned access.,

Sory for my bed English.

mount /dev/sda1 /mnt

[ 73.400000] [EXFAT] trying to mount...
[ 73.440000] [EXFAT] mounted successfully

mount

[ 75.790000] Unhandled kernel unaligned access[#1]:
[ 75.790000] Cpu 0
[ 75.790000] $ 0 : 00000000 fffffff8 00000002 00000285
[ 75.790000] $ 4 : 83b16980 834a2b00 00000000 00000001
[ 75.790000] $ 8 : 00000065 00000001 00000003 6c65722c
[ 75.790000] $12 : 00000007 80080007 00000001 00432cb0
[ 75.790000] $16 : 00000000 83b16980 82a6b400 833e8800
[ 75.790000] $20 : 00000000 00001000 00572078 83b16800
[ 75.790000] $24 : 00000002 800ca378
[ 75.790000] $28 : 83b26000 83b27e28 83b27e90 800ca488
[ 75.790000] Hi : 0000037b
[ 75.790000] Lo : 0000000a
[ 75.790000] epc : 830086dc 0x830086dc
[ 75.790000] Tainted: P O
[ 75.790000] ra : 800ca488 0x800ca488
[ 75.790000] Status: 1100ff03 KERNEL EXL IE
[ 75.790000] Cause : 40800010
[ 75.790000] BadVA : 00000196
[ 75.790000] PrId : 00019650 (MIPS 24KEc)

mounted as read only on archlinux with cinnamon

module compiles and loads ok, external exfat drive is automatically mounted but with root only write access.
arch linux - with 3.12.6-1 kernel, installed by cloning github and compiling, NOT from the AUR.

CONFIG_USER_NS

Setting all licensing issues aside for the moment, this module needs work to be very useful. Most notably it does not support namespace changes in the last few kernel versions.

The following options will cause module build to fail:
CONFIG_USER_NS=y
CONFIG_UIDGID_CONVERTED=y
CONFIG_UIDGID_STRICT_TYPE_CHECKS=y

The zfs module is in the midst of fixing the same deficiencies for anybody looking for reference. https://github.com/zfsonlinux/zfs

readdir Memory issues, missing files/directories, kernel trace (4.2.0-42 ubuntu 14.04.1)

Greetings,

I have a 64 GB SDXC card here (SanDisk) here that was written to with a Sony camera, Linux, and Windows. exfatfsck complains about 0-clusters in a certain directory, but Windows 7 SP1's "chkdsk I: /F" does not find anything worthy of repair or complaint.

Diffing the output of Cygwin find under Windows 7, and a find with exfat-nofuse kernel module yields several differences, one of them

I am getting this kernel log show below from "find". Unmounting the file system is not possible, umount hangs, and cannot be killed with SIGKILL. Trying to "rmmod -f exfat" also gets refused.

exfat-fuse (a different) project behaves in a similar way, but it does not show a broken file.

diff between cygwin find under Windows 7 and Linux find, only relevant parts shown.

 ./DCIM/12760612/DSC02480.ARW
 ./DCIM/12760612/DSC02480.JPG
-./DCIM/12760612/DSC02481.ARW
+./DCIM/12760612/DSC02481.A
 ./DCIM/12760612/DSC02481.JPG
-./DCIM/12760612/DSC02482.ARW
-./DCIM/12760612/DSC02482.JPG
-./DCIM/12760612/DSC02483.ARW
-./DCIM/12760612/DSC02483.JPG
-./DCIM/12760612/DSC02484.ARW
...
-./DCIM/12760612/DSC02566.ARW
-./DCIM/12760612/DSC02566.JPG
-./DCIM/12960617
-./DCIM/12960617/DSC02578.ARW
-./DCIM/12960617/DSC02578.JPG
...
 ./DCIM/13360622/DSC02721.JPG
-./DCIM/13460623
 ./DCIM/13560709
...
-./DCIM/13960716/DSC03078.ARW
-./DCIM/13960716/DSC03078.JPG
-./MP_ROOT
-./MP_ROOT/100ANV01
-./MP_ROOT/101ANV01
...
 ./PRIVATE
 ./PRIVATE/AVCHD
 ./PRIVATE/AVCHD/BDMV

kern.log:

divide error: 0000 [#1] SMP 
Modules linked in: [...elided...]
CPU: 1 PID: 8638 Comm: find Tainted: G           OE   4.2.0-42-generic #49~14.04.1-Ubuntu
Hardware name: [...elided...]
task: ffff8800a463cb00 ti: ffff8802c7f94000 task.ti: ffff8802c7f94000
RIP: 0010:[<ffffffffc0a8ad37>]  [<ffffffffc0a8ad37>] ffsReadDir+0x117/0x5c0 [exfat]
RSP: 0018:ffff8802c7f97808  EFLAGS: 00010246
RAX: 0000000000000001 RBX: ffff8802f1738000 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffff8802c7f97b00 RDI: ffff880275240380
RBP: ffff8802c7f97a88 R08: 0000000000000000 R09: 0000000000000000
R10: 00007efe2ad167b8 R11: 0000000000000000 R12: ffff8802c7f97b00
R13: ffff8802c9050000 R14: 0000000000000000 R15: ffff88029d385400
FS:  00007efe2b1e2740(0000) GS:ffff88031fc40000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f69c6ba100f CR3: 000000029d5e0000 CR4: 00000000000006e0
Stack:
 ffffffffc9054200 ffff880275240380 ffff880200000000 0000000100000000
 ffffffffc0a89e6b 0000000000000000 00000000c7f97801 0000000100000000
 00000000000001ff ffff8802c7f97914 ffff8802b97508a0 ffff8802c9050000
Call Trace:
 [<ffffffffc0a89e6b>] ? get_entry_set_in_dir+0xfb/0x2f0 [exfat]
 [<ffffffffc0a89eb8>] ? get_entry_set_in_dir+0x148/0x2f0 [exfat]
 [<ffffffffc0a8c054>] ? ffsLookupFile+0x1c4/0x290 [exfat]
 [<ffffffff81200000>] ? SyS_fcntl+0x1a0/0x5e0
 [<ffffffff81207834>] ? inode_init_once+0xc4/0x120
 [<ffffffffc0a90f35>] ? init_once+0x25/0x30 [exfat]
 [<ffffffff811d0512>] ? new_slab+0x382/0x450
 [<ffffffffc0a90a4f>] ? exfat_alloc_inode+0x1f/0x50 [exfat]
 [<ffffffff810c08ce>] ? down+0x2e/0x50
 [<ffffffffc0a93a37>] FsReadDir+0x47/0x60 [exfat]
 [<ffffffffc0a915aa>] exfat_readdir+0x13a/0x3e0 [exfat]
 [<ffffffff812015d0>] ? fillonedir+0xd0/0xd0
 [<ffffffff81204ca5>] ? __d_instantiate+0x95/0xf0
 [<ffffffff8120408c>] ? d_rehash+0x4c/0x60
 [<ffffffff812059ac>] ? d_splice_alias+0xcc/0x2a0
 [<ffffffffc0a91cf2>] ? exfat_lookup+0x72/0x1e0 [exfat]
 [<ffffffff81311ed3>] ? security_file_open+0x93/0xa0
 [<ffffffff811ec0bb>] ? do_dentry_open+0x28b/0x320
 [<ffffffff8120da44>] ? mntput+0x24/0x40
 [<ffffffff811f833e>] ? terminate_walk+0x6e/0xe0
 [<ffffffff811fc2c5>] ? path_openat+0x645/0x1330
 [<ffffffff811fd12f>] ? putname+0x5f/0x70
 [<ffffffff811fe08e>] ? do_filp_open+0x8e/0xd0
 [<ffffffff8120147a>] iterate_dir+0x9a/0x120
 [<ffffffff812018e1>] SyS_getdents+0x81/0xe0
 [<ffffffff812015d0>] ? fillonedir+0xd0/0xd0
 [<ffffffff817c36f2>] entry_SYSCALL_64_fastpath+0x16/0x75
Code: b5 8c 00 00 00 45 85 f6 0f 85 ae 04 00 00 44 8b 9d a8 fd ff ff 45 85 db 0f 85 d2 03 00 00 8b 85 9c fd ff ff 8b 8d 90 fd ff ff 99 <f7> f9 39 ca 41 89 d7 0f 8d 84 04 00 00 48 8d 8d a4 fd ff ff 48 
RIP  [<ffffffffc0a8ad37>] ffsReadDir+0x117/0x5c0 [exfat]
 RSP <ffff8802c7f97808>
---[ end trace 02838811ee369c88 ]---

Samsung proprietary code violation

This code was originally under a Samsung proprietary license, all you've done is strip all traces of that license and threw a GPL tag on it.

I suggest removing everything.

Ubuntu 12.04 `make` error!

make -C /lib/modules/3.2.0-48-generic/build M=/home/shatle/github/exfat-nofuse modules
make[1]: 正在进入目录 `/usr/src/linux-headers-3.2.0-48-generic'
  CC [M]  /home/shatle/github/exfat-nofuse/exfat_super.o
/home/shatle/github/exfat-nofuse/exfat_super.c:1031:2: 警告: 从不兼容的指针类型初始化 [默认启用]
/home/shatle/github/exfat-nofuse/exfat_super.c:1031:2: 警告: (在‘exfat_dir_inode_operations.create’的初始化附近) [默认启用]
/home/shatle/github/exfat-nofuse/exfat_super.c:1032:2: 警告: 从不兼容的指针类型初始化 [默认启用]
/home/shatle/github/exfat-nofuse/exfat_super.c:1032:2: 警告: (在‘exfat_dir_inode_operations.lookup’的初始化附近) [默认启用]
/home/shatle/github/exfat-nofuse/exfat_super.c:1035:2: 警告: 从不兼容的指针类型初始化 [默认启用]
/home/shatle/github/exfat-nofuse/exfat_super.c:1035:2: 警告: (在‘exfat_dir_inode_operations.mkdir’的初始化附近) [默认启用]
/home/shatle/github/exfat-nofuse/exfat_super.c: 在函数‘exfat_evict_inode’中:
/home/shatle/github/exfat-nofuse/exfat_super.c:1548:2: 错误: 隐式声明函数‘clear_inode’ [-Werror=implicit-function-declaration]
/home/shatle/github/exfat-nofuse/exfat_super.c: 在文件作用域:
/home/shatle/github/exfat-nofuse/exfat_super.c:1697:2: 警告: 从不兼容的指针类型初始化 [默认启用]
/home/shatle/github/exfat-nofuse/exfat_super.c:1697:2: 警告: (在‘exfat_sops.show_options’的初始化附近) [默认启用]
/home/shatle/github/exfat-nofuse/exfat_super.c: 在函数‘exfat_fill_super’中:
/home/shatle/github/exfat-nofuse/exfat_super.c:1994:2: 错误: 隐式声明函数‘d_make_root’ [-Werror=implicit-function-declaration]
/home/shatle/github/exfat-nofuse/exfat_super.c:1994:13: 警告: 赋值时将整数赋给指针,未作类型转换 [默认启用]
cc1: some warnings being treated as errors
make[2]: *** [/home/shatle/github/exfat-nofuse/exfat_super.o] 错误 1
make[1]: *** [_module_/home/shatle/github/exfat-nofuse] 错误 2
make[1]:正在离开目录 `/usr/src/linux-headers-3.2.0-48-generic'
make: *** [all] 错误 2

[1]+  已停止               sudo make

Build fails on Linux 3.11

make: Entering directory /usr/src/linux-headers-3.11.0-2-generic' CC [M] ./exfat-nofuse/exfat_core.o CC [M] ./exfat-nofuse/exfat_api.o CC [M] ./exfat_blkdev.o CC [M] ./exfat-nofuse/exfat_cache.o CC [M] ./exfat-nofuse/exfat_super.o ./exfat-nofuse/exfat_super.c:365:2: error: unknown field ‘readdir’ specified in initializer ./exfat-nofuse/exfat_super.c:365:2: warning: initialization from incompatible pointer type [enabled by default] ./exfat-nofuse/exfat_super.c:365:2: warning: (near initialization for ‘exfat_dir_operations.write’) [enabled by default] make[1]: *** [./exfat-nofuse/exfat_super.o] Error 1 make: *** [_module_./exfat-nofuse] Error 2 make: Leaving directory/usr/src/linux-headers-3.11.0-2-generic'

Rebuild repository based on Samsung public releases of exfat module.

I realized today there was a bit of houskeeping that needed doing to fully resolve Issue #5. Specifically, the right thing to do here is to cherry-pick the changes from the community and apply them on top of the officially released Samsung exfat code. This will give the project a clean bill of health.

I'm willing to do this work if @dorimanx and @rxrz are willing to replace this repository with the new one created via that method. Would you be willing?

build fail for kernel 3.4

/usr/src/android/a1/exfat-nofuse/exfat_super.c: In function 'exfat_free_super':
/usr/src/android/a1/exfat-nofuse/exfat_super.c:1716:20: error: 'struct exfat_sb_info' has no member named 's_lock'

in exfat_super.h, the s_lock only defined for kernel 3.7 or later, so I think we also need this here.

change it to:

if LINUX_VERSION_CODE >= KERNEL_VERSION(3,7,00)

    mutex_destroy(&sbi->s_lock);

endif

then I can build it without error.

Support for Linux 2.6.30

Is Linux 2.6.30 supported. I'm trying to compile it for my Dlink router which has an archaic linux 2.6.30 kernel. Apparently during compilation I found many functions which were implicitly declared, on further research I found all those functions to be present in Linux 2.6.31 but not in 2.6.30. Any help will be appreciated.

out of range error?

[ 5898.848395] [EXFAT] free_cluster : skip free-req clu:64326, because of zero-size truncation
[ 7730.164116] [EXFAT] free_cluster : skip free-req clu:64833, because of zero-size truncation
[42882.817660] EXT4-fs (sdc1): mounted filesystem with ordered data mode. Opts: (null)
[47876.627666] [EXFAT] sector_read: out of range error! (sec = 1589460992)
[47876.627670] [EXFAT] Filesystem has been set read-only

that's all the EXFAT messages into dmesg, i was transferring ~700gb from an ext partition to an EXFAT, it interrupted at 35% with this issue and mounting itself as RO (without notifying the operating system that still thinks it's mounted rw!)

Anyone had similar issue?

No license specified

As the title says. Please specify the license that governs the use of this module. Without a license, we can't package, distribute or do anything with the code without getting in legal trouble.

P.S. GPL would be great.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.