Hi, sir:
I am porting alc5616 codec on nx platform, when i use aplay to play wav file. The alc5616 driver report the error:
[ 933.036215] Unable to handle kernel NULL pointer dereference at virtual address 00000628
[ 933.036392] Mem abort info:
[ 933.036446] ESR = 0x96000005
[ 933.036502] Exception class = DABT (current EL), IL = 32 bits
[ 933.036602] SET = 0, FnV = 0
[ 933.036663] EA = 0, S1PTW = 0
[ 933.036720] Data abort info:
[ 933.036771] ISV = 0, ISS = 0x00000005
[ 933.036839] CM = 0, WnR = 0
[ 933.036902] user pgtable: 4k pages, 39-bit VAs, pgd = ffffffc1c344d000
[ 933.037030] [0000000000000628] *pgd=0000000000000000, *pud=0000000000000000
[ 933.037168] Internal error: Oops: 96000005 [#1] PREEMPT SMP
[ 933.037265] Modules linked in: fuse xt_conntrack ipt_MASQUERADE nf_nat_masquerade_ipv4 nf_conntrack_netlink nfnetlink bnep xt_addrtype iptable_filter iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack br_netfilter zram rtl8821cu cfg80211 overlay rtk_btusb btusb btrtl btbcm btintel userspace_alert nvgpu GobiNet option usb_wwan ip_tables x_tables
[ 933.039155] CPU: 0 PID: 7835 Comm: aplay Not tainted 4.9.253-tegra #5
[ 933.041953] Hardware name: NVIDIA Jetson Xavier NX Developer Kit (DT)
[ 933.048251] task: ffffffc1eaca8e00 task.stack: ffffffc1f6bbc000
[ 933.054313] PC is at rt5616_hw_params+0x34/0x1d0
[ 933.058848] LR is at soc_dai_hw_params+0x48/0x98
[ 933.063389] pc : [] lr : [] pstate: 80400045
[ 933.070740] sp : ffffffc1f6bbf700
[ 933.073977] x29: ffffffc1f6bbf700 x28: 00000000ffffffff
[ 933.079402] x27: 00000000ffffffff x26: 0000000000000001
[ 933.085174] x25: ffffff800a1d8ae8 x24: ffffffc1f1378300
[ 933.090163] x23: 0000000000000001 x22: ffffffc1f2572300
[ 933.095159] x21: ffffffc1e8009800 x20: ffffffc1f6bbf7c8
[ 933.100409] x19: ffffffc1e8009800 x18: 0000000000000e57
[ 933.106348] x17: 0000007fa6038530 x16: 00000000016e575f
[ 933.112123] x15: 000000000148bcee x14: 00000000000a0a5b
[ 933.117809] x13: 000000000000035c x12: 071c71c71c71c71c
[ 933.123410] x11: 000000000000000b x10: 0000000000000a10
[ 933.129098] x9 : 0000000000000000 x8 : 0000000000000300
[ 933.134620] x7 : 0000000000000000 x6 : 0000000000000000
[ 933.140385] x5 : 0000000000000000 x4 : 0000000000000000
[ 933.145724] x3 : 0000000000000000 x2 : 000000000000ac44
[ 933.150808] x1 : ffffffc1e8009800 x0 : 0000000000000000
[ 933.157544] Process aplay (pid: 7835, stack limit = 0xffffffc1f6bbc000)
[ 933.163929] Call trace:
[ 933.166562] [] rt5616_hw_params+0x34/0x1d0
[ 933.171898] [] soc_dai_hw_params+0x48/0x98
[ 933.176977] [] snd_soc_dai_link_event+0x34c/0x3d0
[ 933.183097] [] dapm_seq_check_event.isra.27+0x118/0x2d0
[ 933.189228] [] dapm_seq_run_coalesced+0xa0/0x1e0
[ 933.195171] [] dapm_seq_run+0xb0/0x3d0
[ 933.200164] [] dapm_power_widgets+0x59c/0x9e0
[ 933.205864] [] snd_soc_dapm_stream_event+0x9c/0xb8
[ 933.211971] [] soc_pcm_prepare+0x118/0x258
[ 933.217045] [] snd_pcm_do_prepare+0x28/0x48
[ 933.222469] [] snd_pcm_action_single+0x4c/0xa0
[ 933.228591] [] snd_pcm_action_nonatomic+0x84/0xa8
[ 933.234636] [] snd_pcm_common_ioctl1+0xa0c/0xe98
[ 933.240839] [] snd_pcm_playback_ioctl1+0x298/0x8a8
[ 933.247145] [] snd_pcm_playback_ioctl+0x48/0x68
[ 933.253446] [] do_vfs_ioctl+0xb0/0x8d8
[ 933.258955] [] SyS_ioctl+0x8c/0xa8
[ 933.264118] [] el0_svc_naked+0x34/0x38
[ 933.269461] —[ end trace af8e9eb5c32b11c7 ]—