TI中文支持网
TI专业的中文技术问题搜集分享网站

AM335x RT-Linux SDK4.02 ext4问题

请问TI的SDK 04.02版本(内核4.9.59),是否有测试过ext4文件系统?

问题:

U盘挂载正常:

[ 13.598050] scsi 0:0:0:0: Direct-Access SMI USB DISK 1100 PQ: 0 ANSI: 4
[ 13.969479] sd 0:0:0:0: [sda] 4028416 512-byte logical blocks: (2.06 GB/1.92 GiB)
[ 13.970069] sd 0:0:0:0: [sda] Write Protect is off
[ 13.970637] sd 0:0:0:0: [sda] No Caching mode page found
[ 13.970644] sd 0:0:0:0: [sda] Assuming drive cache: write through
[ 13.977376] sd 0:0:0:0: [sda] Attached SCSI removable disk

mount文件系统:

mount -t ext4 /dev/sda /mnt/usb0

也提示正常

但是,无法对文件夹进行访问:ls等都直接死掉,Ctrl-C无法退出

有一定几率还会报异常:

traceback看到都挂在rt_mutex_xxx函数,和rt补丁似乎有关系?

[root ~]# mount -t ext4 /dev/sda /mnt/usb0/
[61.377083] EXT4-fs (sda): recovery complete
[61.390085] EXT4-fs (sda): mounted filesystem with ordered data mode. Opts: (null)
[root ~]# cd /mnt/usb0/
[root /mnt/usb0]# ls
[66.781774] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.789716] b_state=0x00000029, b_size=3391364552
[66.794447] device sda blocksize: 4096
[66.798902] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.806776] b_state=0x00000029, b_size=3391364552
[66.811751] device sda blocksize: 4096
[66.816397] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.824593] b_state=0x00000029, b_size=3391364552
[66.829458] device sda blocksize: 4096
[66.833902] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.842099] b_state=0x00000029, b_size=3391364552
[66.846826] device sda blocksize: 4096
[66.851305] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.859452] b_state=0x00000029, b_size=3391364552
[66.864180] device sda blocksize: 4096
[66.868897] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.876766] b_state=0x00000029, b_size=3391364552
[66.881732] device sda blocksize: 4096
[66.886029] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.894111] b_state=0x00000029, b_size=3391364552
[66.898886] device sda blocksize: 4096
[66.903312] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.911405] b_state=0x00000029, b_size=3391364552
[66.916133] device sda blocksize: 4096
[66.920523] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.928512] b_state=0x00000029, b_size=3391364552
[66.933240] device sda blocksize: 4096
[66.937292] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.945424] b_state=0x00000029, b_size=3391364552
[66.950327] device sda blocksize: 4096
[66.954515] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.962673] b_state=0x00000029, b_size=3391364552
[66.967401] device sda blocksize: 4096
[66.971731] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.979735] b_state=0x00000029, b_size=3391364552
[66.984464] device sda blocksize: 4096
[66.988797] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[66.996664] b_state=0x00000029, b_size=3391364552
[67.001543] device sda blocksize: 4096
[67.005888] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[67.014918] b_state=0x00000029, b_size=3391364552
[67.019926] device sda blocksize: 4096
[67.024449] __find_get_block_slow() failed. block=126, b_blocknr=14565799839653691518
[67.032656] b_state=0x00000029, b_size=3391364552
[67.037388] device sda blocksize: 4096
[67.041539] Unable to handle kernel paging request at virtual address 1ec07dc6
[67.041545] pgd = cf7fc000
[67.041553] [1ec07dc6] *pgd=00000000
[67.041563] Internal error: Oops: 5 [#1] PREEMPT ARM
[67.041607] Modules linked in: ext4 jbd2 mbcache sd_mod usbnet usbserial usb_storage scsi_mod musb_dsps musb_hdrc udc_core phy_am335x usbcore phy_generic usb_common phy_am335x_control wkup_m3_ipc wkup_m3_rproc remoteproc omap_wdt musb_am335x omap_sham ti_emif_sram omap_aes_driver crypto_engine
[67.041621] CPU: 0 PID: 356 Comm: ls Not tainted 4.9.59-rt23-g273202a0d3 #9
[67.041624] Hardware name: Generic AM33XX (Flattened Device Tree)
[67.041629] task: ca215480 task.stack: ca04a000
[67.041647] PC is at rt_mutex_setprio+0x1e8/0x3a8
[67.041651] LR is at rt_mutex_setprio+0x48/0x3a8
[67.041658] pc : [<c014fa98>]lr : [<c014f8f8>]psr: 000c0093
[67.041658] sp : ca04b8e8  ip : ca04b8e8  fp : ca04b924
[67.041662] r10: 00000000  r9 : 1ec07d96  r8 : 00000000
[67.041666] r7 : ca215480  r6 : c0a10f70  r5 : 00000078  r4 : ca0db000
[67.041670] r3 : c0703660  r2 : 00000000  r1 : ca04b8f4  r0 : c0a10f70
[67.041677] Flags: nzcv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment none
[67.041682] Control: 10c5387d  Table: 8f7fc019  DAC: 00000051
[67.041686] Process ls (pid: 356, stack limit = 0xca04a208)
[67.041691] Stack: (0xca04b8e8 to 0xca04c000)
[67.041701] b8e0:00000006 ca215480 ca04b924 ca04b900 c015f3fc ca215480
[67.041711] b900: cb02c1a4 ca0db000 ca04b960 00000000 ca04b960 a00c0013 ca04b95c ca04b928
[67.041721] b920: c015fed4 c014f8bc ca2154b0 ca2154b0 c0a10fa0 ca04a000 cb02c1a4 a00c0013
[67.041730] b940: ca215480 ca04b960 00000001 a00c0013 ca04b9bc ca04b960 c066e394 c015fbf4

[67.042234] bfe0: 000000d9 bef45c4c b6f3e3b3 b6ee6996 600c0030 00000003 e50b10a4 e1a0a003
[67.042238] Backtrace:
[67.042256] [<c014f8b0>] (rt_mutex_setprio) from [<c015fed4>] (task_blocks_on_rt_mutex+0x2ec/0x308)
[67.042267]  r10:a00c0013 r9:ca04b960 r8:00000000 r7:ca04b960 r6:ca0db000 r5:cb02c1a4
[67.042270]  r4:ca215480
[67.042287] [<c015fbe8>] (task_blocks_on_rt_mutex) from [<c066e394>] (rt_spin_lock_slowlock+0x11c/0x314)
[67.042296]  r10:a00c0013 r9:00000001 r8:ca04b960 r7:ca215480 r6:a00c0013 r5:cb02c1a4
[67.042299]  r4:ca04a000
[67.042311] [<c066e278>] (rt_spin_lock_slowlock) from [<c0670084>] (rt_spin_lock+0x4c/0x50)
[67.042320]  r10:ca04baa8 r9:ca05ce54 r8:cff0b9e8 r7:cb02c140 r6:cb02c1a4 r5:cb02c140
[67.042323]  r4:cb02c140
[67.042450] [<c0670038>] (rt_spin_lock) from [<bf152da8>] (jbd2_journal_grab_journal_head+0x1c/0x48 [jbd2])
[67.042529] [<bf152d8c>] (jbd2_journal_grab_journal_head [jbd2]) from [<bf14a688>] (jbd2_journal_try_to_free_buffers+0x78/0x100 [jbd2])
[67.042536]  r7:cb02c140 r6:ca04bcf8 r5:ca05cc00 r4:cb02c140
[67.042884] [<bf14a610>] (jbd2_journal_try_to_free_buffers [jbd2]) from [<bf17e404>] (bdev_try_to_free_page+0x50/0x84 [ext4])
[67.042894]  r10:ca04baa8 r9:cb0385ec r8:ca04bb68 r7:00000000 r6:ca04bcf8 r5:ca05cc00
[67.042898]  r4:cff0b9e8 r3:00000a01
[67.043030] [<bf17e3b4>] (bdev_try_to_free_page [ext4]) from [<c02516e8>] (blkdev_releasepage+0x40/0x4c)
[67.043035]  r5:cff0b9e8 r4:bf17e3b4
[67.043050] [<c02516a8>] (blkdev_releasepage) from [<c01c408c>] (try_to_release_page+0x54/0x6c)
[67.043054]  r5:cff0b9e8 r4:cff0b9fc
[67.043069] [<c01c4038>] (try_to_release_page) from [<c01d827c>] (shrink_page_list+0xa14/0xd50)
[67.043079] [<c01d7868>] (shrink_page_list) from [<c01d8e2c>] (shrink_inactive_list+0x200/0x58c)
[67.043088]  r10:c0a428fc r9:c0ab5c58 r8:ca04bb68 r7:ca04bcf8 r6:00000003 r5:c0a42974
[67.043091]  r4:c0ab5c70
[67.043101] [<c01d8c2c>] (shrink_inactive_list) from [<c01d9a64>] (shrink_node_memcg+0x49c/0x72c)
[67.043110]  r10:00000003 r9:cf01a500 r8:ca04bbc0 r7:ca04bcf8 r6:00000000 r5:00000000
[67.043112]  r4:00000002
[67.043121] [<c01d95c8>] (shrink_node_memcg) from [<c01d9dd8>] (shrink_node+0xe4/0x328)
[67.043130]  r10:c0a41ee8 r9:00000000 r8:00000001 r7:00000000 r6:00000000 r5:cf03a800
[67.043133]  r4:ca04bcf8
[67.043142] [<c01d9cf4>] (shrink_node) from [<c01da120>] (do_try_to_free_pages+0x104/0x3b0)
[67.043151]  r10:00000001 r9:ca04bcf8 r8:c0a42854 r7:02400040 r6:c0a41ee8 r5:c0a42854
[67.043154]  r4:c0a41ee8
[67.043163] [<c01da01c>] (do_try_to_free_pages) from [<c01da500>] (try_to_free_pages+0x134/0x2f8)
[67.043172]  r10:cb0384f8 r9:c0a41ee8 r8:c0a41ee8 r7:00000000 r6:c0a42854 r5:02400040
[67.043175]  r4:00000001
[67.043191] [<c01da3cc>] (try_to_free_pages) from [<c024b958>] (free_more_memory+0x68/0x70)
[67.043201]  r10:cb0384f8 r9:00000000 r8:0000007e r7:00000000 r6:cfdbb49c r5:00001000
[67.043203]  r4:00000000
[67.043215] [<c024b8f0>] (free_more_memory) from [<c024d440>] (__getblk_gfp+0x1bc/0x368)
[67.043344] [<c024d284>] (__getblk_gfp) from [<bf16bac0>] (__ext4_get_inode_loc+0x120/0x4d8 [ext4])
[67.043353]  r10:00000010 r9:00000000 r8:0000007e r7:00000001 r6:cab923c8 r5:ca04be54
[67.043356]  r4:ca05c400
[67.043583] [<bf16b9a0>] (__ext4_get_inode_loc [ext4]) from [<bf170570>] (ext4_reserve_inode_write+0x30/0x90 [ext4])
[67.043592]  r10:cab923c8 r9:cf63d908 r8:00000000 r7:cab91080 r6:ca04be54 r5:cab91080
[67.043596]  r4:cab923c8
[67.043821] [<bf170540>] (ext4_reserve_inode_write [ext4]) from [<bf1705f8>] (ext4_mark_inode_dirty+0x28/0x160 [ext4])
[67.043828]  r7:00000000 r6:ca05c800 r5:cab91080 r4:cab923c8
[67.044054] [<bf1705d0>] (ext4_mark_inode_dirty [ext4]) from [<bf174300>] (ext4_dirty_inode+0x4c/0x68 [ext4])
[67.044062]  r8:00000000 r7:00000000 r6:ca04bf00 r5:cab91080 r4:cab923c8
[67.044180] [<bf1742b4>] (ext4_dirty_inode [ext4]) from [<c0244864>] (__mark_inode_dirty+0x38/0x210)
[67.044185]  r5:cab923c8 r4:00000801
[67.044199] [<c024482c>] (__mark_inode_dirty) from [<c0234a60>] (generic_update_time+0x7c/0xac)
[67.044208]  r9:cf63d908 r8:00000000 r7:00000000 r6:ca04bf00 r5:cab923c8 r4:00000001
[67.044218] [<c02349e4>] (generic_update_time) from [<c02364ec>] (touch_atime+0xa4/0xbc)
[67.044227]  r9:cf63d908 r8:00000000 r7:00000000 r6:ca04bef8 r5:ca164f10 r4:cab923c8
[67.044246] [<c0236448>] (touch_atime) from [<c022c374>] (iterate_dir+0x138/0x178)
[67.044251]  r6:cab92444 r5:00000001 r4:cf63d900
[67.044262] [<c022c23c>] (iterate_dir) from [<c022ca14>] (SyS_getdents64+0x84/0x128)
[67.044272]  r10:00000000 r9:ca04a000 r8:c0107dc4 r7:cf63d900 r6:cf63d900 r5:00008000
[67.044275]  r4:000c40b0
[67.044293] [<c022c990>] (SyS_getdents64) from [<c0107c00>] (ret_fast_syscall+0x0/0x44)
[67.044300]  r7:000000d9 r6:000c4094 r5:000c4090 r4:000c40b0
[67.044311] Code: 0a000062 e594302c e1590003 0a000043 (e5992030)

Segmentation fault[ 200.973760] —[ end trace 0000000000000002 ]—
[root@buildroot ~]# [ 200.973771] note: ls[352] exited with preempt_count 3
kernel:[ 200.378639] Internal error: Oops: 5 [#1] PREEMPT ARM

yongqing wang:

别的文件系统的U盘会出现这个问题吗

DachuanLiu:

回复 yongqing wang:

我看到一个14年的帖子也有类似的问题,现象类似,trace log死的点有差异
e2echina.ti.com/…/136243

挂vfat没问题
感觉是ext4不对

yongqing wang:

回复 DachuanLiu:

有没有更新版的系统跟新一下试试,按道理这个问题比较明显不应该出现才对

赞(0)
未经允许不得转载:TI中文支持网 » AM335x RT-Linux SDK4.02 ext4问题
分享到: 更多 (0)