Skip to content

MI VDISP DEBUG SOP


REVISION HISTORY

Revision No.
Description
Date
1.00
  • Initial release
  • 01/18/2024

    PREFACE

    This document primarily provides guidance on troubleshooting methods for common issues encountered when using the VDISP function.

    1. ISSUES

    1.1 ABNORMAL OUTPUT DISPLAY

    STEP1 Verify whether vdisp input channels are aligned

    1. The vdisp module imposes alignment restrictions on the start position of input channels. The specific alignment value depends on the preceding module. If an input channel does not meet this restriction condition, the channel will not be created. Therefore, check whether there are any logs indicating misalignment.

    STEP2 Verify whether bdma driver is functioning normally

    1. The vdisp module is primarily implemented in software, but also utilizes bdma hardware. If screen corruption occurs, first verify whether bdma has any anomalies, such as abnormal logs.

    STEP3 Verify whether preceding module output is normal

    1. Use the following command to dump the input image to check for any abnormalities. If present, contact the owner of the preceding module.

      echo dumpin [devid, chnid, path, cnt] > /proc/mi_modules/mi_vdisp/mi_vdispxxx

    2. If the vdisp input is normal, enter the following command to capture kmsg information and submit it to the vdisp owner for analysis.

      echo 4 > /proc/mi_modules/mi_vdisp/debug_level

      cat /proc/kmsg > /mnt/xxx.txt

    1.2 DISPLAY FREEZE

    When the display freezes, a large number of the following logs will typically appear in the serial console:

    ## input:
    [MI WRN ]: _MI_SYS_Pass_Try_DequeueInputTaskNoLock[3394]:  [thread:vdisp0_P0_MAIN] mod[14] dev[0] pass[0] chn[16] inputtask CheckInputTaskStatus failed more than 14290ms,total pending task-1073432073
    ## output:
    [MI WRN ]: _MI_SYS_Pass_TryDequeueOutputTaskNoLock[6154]:  [thread:vdisp0_P0_MAIN] mod[14] dev[0] pass[0] chn[16] output not finished more than 5000ms
    

    STEP1 Verify whether pipeline performance meets requirements

    1. Verify whether performance parameters such as CPU loading and bandwidth of the entire pipeline are abnormal.

    STEP2 Verify the set value of vdisp output port frame rate

    1. If the output frame rate set value is 0, verify whether the preceding module has frozen.

    2. If the output frame rate set value is not 0, enter the following command to capture proc information (at least three times) and submit it to the vdisp owner for analysis.

      cat /proc/mi_modules/mi_vdisp/mi_vdispxxx

    1.3 INSUFFICIENT OUTPUT FRAME RATE

    STEP1 Verify whether the preceding module is operating slowly, causing frame drops

    1. Consider the impact of the preceding module only when the vdisp output frame rate set value is 0 (floating frame rate mode), or when any of vdisp chn0-chn15 channels are enabled.

    2. Execute cat multiple times on the preceding module's proc information to confirm output frame rate degradation. Check the PipeBuf_cnt field at the output port. If it remains non-zero for an extended period, contact the preceding module owner to investigate whether the module is operating slowly.

    STEP2 Verify whether the succeeding module holds a large number of vdisp buffers, causing frame drops

    1. Execute cat multiple times on the succeeding module's proc information. Check the BindInQ_cnt field at the input port. If it remains non-zero for an extended period, contact the succeeding module owner to investigate whether buffer consumption is not timely.

    STEP3 Verify vdisp performance parameters

    1. The default setting for vdisp output buffer BufCntQuota is currently 4 (viewable via cat vdisp proc information). Excluding the impact of preceding and succeeding modules, this setting meets the frame rate requirements for the majority of use cases.

    2. If vdisp BufCntQuota is 4 and the frame rate is still insufficient, check the usrDepth field at the Output port in the vdisp proc information to confirm whether it needs to be provided to the user. If not required, it can be configured to 0 or reduced, as this depth affects the release of vdisp buffers.

    3. If reducing the BufCntQuota for vdisp to save memory still doesn't meet the frame rate requirements, after excluding the impact of upstream/downstream stages and usrDepth, please refer to points 4 and 5 below for analysis to be provided to the vdisp owner.

    4. Execute the following command to capture proc information when the frame rate is insufficient and submit it to the vdisp owner for analysis.

      cat /proc/mi_modules/mi_vdisp/mi_vdispxxx

    5. When the frame rate is insufficient, execute command 1 "echo Y" to add timestamps to output logs, command 2 "echo 0" to disable serial console log output (otherwise frame rate will be affected by logs), command 3 "echo 4" to enable vdisp debug log information, and command 4 "cat" which must be executed in telnet terminal to capture vdisp debug log information and submit it to the vdisp owner for analysis.

      echo Y> /sys/module/printk/parameters/time

      echo 0 > /proc/sys/kernel/printk

      echo 4 >/proc/mi_modules/mi_vdisp/debug_level

      cat /proc/kmsg

    1.4 MEMORY CORRUPTION

    When vdisp memory corruption occurs, logs similar to the following will typically appear in the serial console:

    [MI WRN] MI_SYS_Mma_MmuCallback [mi_sys][365]: [MI_SYS_Mma_MmuCallback] Status=0x4, PhyAddr=0x41220000, ClientId=0x72, IsWrite=1
    

    STEP1 Execute the following commands to capture information

    1. Modify the debugMmu field in /config/modparam.json to enable the debug mmu function.

    2. Enter the following commands to capture kmsg information and submit it to the vdisp owner for analysis.

      echo 4 > /proc/mi_modules/mi_vdisp/debug_level

      echo debug_mmu debug_log 1 1 1 14 > /proc/mi_modules/mi_sys/mi_sys0

      cat /proc/kmsg > /mnt/xxx.txt

    1.5 OTHER ISSUES

    STEP1 Execute the following commands to capture information

    echo 4 > /proc/mi_modules/mi_vdisp/debug_level
    cat /proc/mi_modules/mi_vdisp/mi_vdispxxx
    
    1. After entering the above commands, capture proc and kmsg information and submit it to the vdisp owner for analysis.