How would you debug this linux gpu issue? 

[    7.860082] devfreq 5000000.gpu: Couldn't update frequency transition information.
[    8.799065] [drm:adreno_idle [msm]] *ERROR* 5.0.9.0: timeout waiting to drain ringbuffer 0 rptr/wptr = 0/C
[    8.799466] msm_mdp c901000.display-controller: [drm:adreno_load_gpu [msm]] *ERROR* gpu hw init failed: -22
[  461.455739] [drm:mdp5_irq_error_handler [msm]] *ERROR* errors: 04000000
[  470.402215] ------------[ cut here ]------------
[  470.402237] gpucc_gfx3d_clk status stuck at 'off'
[  470.402285] WARNING: CPU: 0 PID: 3708 at drivers/clk/qcom/clk-branch.c:87 clk_branch_toggle+0x19c/0x1c0
[  470.402310] Modules linked in: zram zsmalloc nft_reject_inet nf_reject_ipv4 nf_reject_ipv6 nft_reject nft_ct nf_conntrack nf_defrag_ipv6 nf_defrag_ipv4 nf_tables nfnetlink ipv6 venus_enc venus_dec videobuf2_dma_contig videobuf2_memops apr pdr_interface qrtr_smd qcom_pd_mapper qcom_pdr_msg hci_uart btqca venus_core btrtl btintel v4l2_mem2mem btbcm videobuf2_v4l2 videodev bluetooth ath10k_snoc videobuf2_common mc ecdh_generic ath10k_core ecc ath mac80211 libarc4 cfg80211 qcom_spmi_temp_alarm qcom_spmi_adc5 qcom_spmi_rradc qcom_vadc_common qcom_spmi_haptics qrtr qcom_rng rfkill rng_core qcom_q6v5_mss qcom_q6v5_pas qcom_stats qcom_pil_info qcom_q6v5 qcom_sysmon qcom_common qmi_helpers rmtfs_mem msm mdt_loader drm_exec drm_dp_aux_bus qcom_aoss llcc_qcom ocmem qcom_pmi8998_charger gpu_sched industrialio qcom_fg drm_display_helper
[  470.402565] CPU: 0 PID: 3708 Comm: Xorg Tainted: G        W          6.10.9-sdm660 #1
[  470.402574] Hardware name: Xiaomi Phone(DT)
[  470.402581] pstate: 600000c5 (nZCv daIF -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[  470.402590] pc : clk_branch_toggle+0x19c/0x1c0
[  470.402600] lr : clk_branch_toggle+0x19c/0x1c0
[  470.402609] sp : ffff800082adb630
[  470.402613] x29: ffff800082adb640 x28: ffff6c0988a9d500 x27: ffff6c0983c54138
[  470.402629] x26: 0000000000000001 x25: 0000000000000000 x24: ffffcf8b0a4977b0
[  470.402643] x23: 0000000000000001 x22: 0000000000000001 x21: ffffcf8b0a8dea28
[  470.402657] x20: ffffcf8b09b6a2c8 x19: 0000000000000000 x18: 0000000000000000
[  470.402672] x17: 0000000000000000 x16: 0000000000000000 x15: 0000000000000000
[  470.402686] x14: 0000000000000000 x13: 6f27207461206b63 x12: 7574732073757461
[  470.402700] x11: ffffcf8b0a7a3cb8 x10: 0000000000000258 x9 : ffffcf8b09357274
[  470.402714] x8 : 0000000000017fe8 x7 : 00000000fffff257 x6 : ffffcf8b0a7fbcb8
[  470.402729] x5 : ffff6c0a3c309708 x4 : 0000000000000000 x3 : 0000000000000027
[  470.402743] x2 : 0000000000000000 x1 : 0000000000000000 x0 : ffff6c0988a9d500
[  470.402758] Call trace:
[  470.402763]  clk_branch_toggle+0x19c/0x1c0
[  470.402773]  clk_branch2_enable+0x24/0x40
[  470.402783]  clk_core_enable+0x78/0x200
[  470.402796]  clk_enable+0x34/0x60
[  470.402806]  clk_bulk_enable+0x3c/0xb8
[  470.402815]  msm_gpu_pm_resume+0xb4/0x220 [msm]
[  470.403085]  a5xx_pm_resume+0x20/0x208 [msm]
[  470.403274]  adreno_runtime_resume+0x30/0x48 [msm]
[  470.403465]  pm_generic_runtime_resume+0x34/0x60
[  470.403479]  __genpd_runtime_resume+0x38/0x98
[  470.403490]  genpd_runtime_resume+0x11c/0x2b0
[  470.403501]  __rpm_callback+0x50/0x1f0
[  470.403513]  rpm_callback+0x70/0x88
[  470.403524]  rpm_resume+0x470/0x680
[  470.403534]  __pm_runtime_resume+0x58/0xa8
[  470.403542]  adreno_load_gpu+0x80/0x238 [msm]
[  470.403732]  msm_open+0x100/0x120 [msm]
[  470.403921]  drm_file_alloc+0x178/0x2a0
[  470.403930]  drm_open_helper+0x78/0x120
[  470.403938]  drm_open+0x108/0x1d8
[  470.403945]  drm_stub_open+0xb0/0x108
[  470.403956]  chrdev_open+0xc0/0x238
[  470.403966]  do_dentry_open+0x1bc/0x4e8
[  470.403976]  vfs_open+0x34/0x100
[  470.403985]  path_openat+0xa3c/0x1020
[  470.403996]  do_filp_open+0xa8/0x168
[  470.404007]  do_sys_openat2+0xd0/0x110
[  470.404016]  __arm64_sys_openat+0x6c/0xc8
[  470.404025]  invoke_syscall+0x50/0x120
[  470.404037]  el0_svc_common.constprop.0+0x48/0xf0
[  470.404048]  do_el0_svc+0x24/0x38
[  470.404058]  el0_svc+0x34/0xe0
[  470.404068]  el0t_64_sync_handler+0x120/0x138
[  470.404077]  el0t_64_sync+0x190/0x198
[  470.404087] ---[ end trace 0000000000000000 ]---
[  470.404162] Failed to enable clk 'core': -16
[  470.404343] msm_mdp c901000.display-controller: [drm:adreno_load_gpu [msm]] *ERROR* Couldn't power up the GPU: -16
[  470.984548] msm_mdp c901000.display-controller: [drm:adreno_load_gpu [msm]] *ERROR* Couldn't power up the GPU: -22
[  470.993034] msm_mdp c901000.display-controller: [drm:adreno_load_gpu [msm]] *ERROR* Couldn't power up the GPU: -22