# Troubleshoot camera

Collect camera logs using one of the following commands:

# cat /var/log/messages > log.txt
    Copy to clipboard

Or:

# journalctl -f > log.txt
    Copy to clipboard

This command collects both KMD and UMD logs. To collect only KMD logs, use the following command:

# dmesg -w > dmesg.txt
    Copy to clipboard

## Capture user mode logs

A variety of log levels available in the camera software. Based on need, developers can enable these log levels to debug issues efficiently.

Log levels are controlled through the following override settings.

| **Description** | **Override setting** | **Default value** |
| --- | --- | --- |
| Verbose log mask | logVerboseMask | 0 |
| Entry/exit log mask | logEntryExitMask | 0 |
| Info log mask | logInfoMask | 0xFFFFFFFF |
| Warning log mask | logWarningMask | 0xFFFFFFFF |
| System log enable | systemLogEnable | TRUE |

To enable logging:

1. On first use, create a text filename `camxoverridesettings.txt`.
2. Add the required log mask to this text file. For example, LogVerboseMask=0XFF11 and LogInfoMask=0x1C09811.
3. Push the modified file to `/var/cache/camera/camxoverridesettings.txt.` A device reboot may be required after changing override settings.

**Example 1**

Controlled debug log messages determine which groups of the camera system output logs for each log level. To enable verbose and entry or exit log settings, add the following to the `/var/cache/camera/camxoverridesettings.txt` file:

logVerboseMask=0xFFFFFFFF
    logEntryExitMask=0xFFFFFFFF
    Copy to clipboard

**Example 2**

To enable verbose logs for HAL CSL groups only, enable warnings from sensor, HAL, and CSL and disable system logging:

logVerboseMask=0x00000480
    logWarningMask=0x482
    Copy to clipboard

### Camera UMD logs

The camera driver is implemented with debug log messages. The log messages can be filtered to limit what’s displayed according to user interest (verbosity level and group). Each log comes from a specified group and has a verbosity level ranging from verbose to error.
All camera debug logs follow the same format:

CamX: [<Verbosity Level>][<Group>] <File>:<Line Number> <Function Name> <Message>
    Copy to clipboard

For example:

CamX: [INFO][CORE] camxexamplefile:123 ExampleFunction()This is the message.
    Copy to clipboard

The following verbosity levels are supported by the driver to gain insight into problems when debugging camera applications.

| Error | Fatal and non-fatal errors. Errors can’t guarantee successful continued operation. |
| --- | --- |
| Warning | Non-fatal conditions which are unexpected, but not necessarily an error. Used to indicate issues such as slow performance paths, fallback code, etc. |
| Entry or exit | Entry or exit API tracing. Allows simple, high-level call flow logging. |
| Info | Informational logs, short one-time configuration, etc. |
| Verbose | All other logs. Doesn’t necessarily provide any useful information for debugging purposes. |

### Camera user mode logging groups

The driver is split into various logical components known as groups. Using a specific group allows you to reduce the amount of log messages sent to the component(s) you are interested in obtaining information from.
This is accomplished with a bitmask to selectively choose which logs to enable from different components of the camera system.

The following table lists the UMD logging groups.

| **Driver group name** | **Value** | **Description** |
| --- | --- | --- |
| CamxLogGroupAFD | (1&lt;&lt; 0) | AFD |
| CamxLogGroupSensor | (1&lt;&lt; 1) | Sensor |
| CamxLogGroupTracker | (1&lt;&lt; 2) | Tracker |
| CamxLogGroupISP | (1&lt;&lt; 3) | ISP |
| CamxLogGroupPProc | (1&lt;&lt; 4) | Post processor |
| CamxLogGroupMemMgr | (1 &lt;&lt; 5) | MemMgr |
| CamxLogGroupPower | (1 &lt;&lt; 6) | Power (clock, bandwidth related) |
| CamxLogGroupHAL | (1&lt;&lt; 7) | HAL |
| CamxLogGroupJPEG | (1&lt;&lt; 8) | JPEG |
| CamxLogGroupStats | (1&lt;&lt; 9) | 3A algorithms |
| CamxLogGroupCSL | (1&lt;&lt; 10) | Camera service layer |
| CamxLogGroupApp | (1&lt;&lt; 11) | Application |
| CamxLogGroupUtils | (1&lt;&lt; 12) | Utilities |
| CamxLogGroupSync | (1&lt;&lt; 13) | Synchronization/mutex/fences |
| CamxLogGroupMemSpy | (1&lt;&lt; 14) | MemSpy |
| CamxLogGroupFormat | (1&lt;&lt; 15) | Format |
| CamxLogGroupCore | (1&lt;&lt; 16) | Core camera system |
| CamxLogGroupHWL | (1&lt;&lt; 17) | Hardware layer |
| CamxLogGroupChi | (1&lt;&lt; 18) | CameraHALinterface |
| CamxLogGroupDRQ | (1&lt;&lt; 19) | Deferred request queue |
| CamxLogGroupFD | (1&lt;&lt; 20) | Face detection |
| CamxLogGroupIQMod | (1&lt;&lt; 21) | IQ module |
| CamxLogGroupLRME | (1&lt;&lt; 22) | LRME |
| CamxLogGroupCVP | (1&lt;&lt; 22) | CVP |
| CamxLogGroupNCS | (1&lt;&lt; 23) | NCS |
| CamxLogGroupMeta | (1&lt;&lt; 24) | Metadata |
| CamxLogGroupAEC | (1&lt;&lt; 25) | AEC |
| CamxLogGroupAWB | (1&lt;&lt; 26) | AWB |
| CamxLogGroupAF | (1&lt;&lt; 27) | AF |
| CamxLogGroupSWP | (1&lt;&lt; 28) | SW Process |
| CamxLogGroupHist | (1&lt;&lt; 29) | HistogramProcess |
| CamxLogGroupBPS | (1&lt;&lt; 30) | BPS |
| CamxLogGroupDebugData | (1&lt;&lt; 31) | Debug data framework, 3A debug data, and tuning metadata |

## Capture kernel mode logs

KMD log messages are enabled by default and appear in the kernel logs. Camera KMD logs all start with the CAM prefix. Additional debugging logs are available in the KMD and are controlled through groups.

The following table lists the KMD logging groups.

| **KMD group** | **Value** | **Description** |
| --- | --- | --- |
| CAM\_CDM | (1&lt;&lt; 0) | Camera data mover |
| CAM\_CORE | (1&lt;&lt; 1) | Camera core |
| CAM\_CPAS | (1&lt;&lt; 2) | Camera peripherals and support |
| CAM\_ISP | (1&lt;&lt; 3) | Image signal processor |
| CAM\_CRM | (1&lt;&lt; 4) | Camera request manager |
| CAM\_SENSOR | (1&lt;&lt; 5) | Sensor |
| CAM\_SMMU | (1&lt;&lt; 6) | Shared memory management unit |
| CAM\_SYNC | (1&lt;&lt; 7) | Synchronization |
| CAM\_ICP | (1&lt;&lt; 8) | Image control processor |
| CAM\_JPEG | (1&lt;&lt; 9) | JPEG |
| CAM\_FD | (1&lt;&lt; 10) | Face detection |
| CAM\_LRME | (1&lt;&lt; 11) | Low resolution motion estimation |
| CAM\_FLASH | (1&lt;&lt; 12) | Flash |
| CAM\_ACTUATOR | (1&lt;&lt; 13) | Actuator |
| CAM\_CCI | (1&lt;&lt; 14) | Camera control interface |
| CAM\_CSIPHY | (1&lt;&lt; 15) | Camera serial interface |
| CAM\_EEPROM | (1&lt;&lt; 16) | Electronically erasable programmable read-only memory |
| CAM\_UTIL | (1&lt;&lt; 17) | Utilities |
| CAM\_HFI | (1&lt;&lt; 18) | Host-firmware interface |
| CAM\_CTXT | (1&lt;&lt; 19) | Camera context |
| CAMX\_OIS | (1&lt;&lt; 20) | Optical image stabilization |
| CAM\_RES | (1&lt;&lt; 21) | Camera shared resource API |
| CAM\_MEM | (1&lt;&lt; 22) | For camera memory manager |
| CAM\_IRQ\_CTRL | (1&lt;&lt; 23) | For events in IRQ controller |
| CAM\_REQ | (1&lt;&lt; 24) | Tracks a request submitted to KMD |
| CAM\_PERF | (1&lt;&lt; 25) | Used for performance (clock, bandwidth, etc.) logs |
| CAM\_CUSTOM | (1 &lt;&lt; 26) | For custom hardware node |
| CAM\_PRESIL | (1&lt;&lt;27) | Presil changes |
| CAM\_OPE | (1&lt;&lt;28) | Offline processing engine |
| CAM\_IO\_ACCESS | (1&lt;&lt;29) | Camera I/O access(reg read/write, etc.) |
| CAM\_SFE | (1&lt;&lt;30) | Streaming front-end |
| CAM\_IR\_LED | (1&lt;&lt;31 | IR LED |

### Enable camera kernel mode driver logs

1. To enable CAM\_SENSOR and CAM\_ICP debug logs in the KMD, run the following commands in an SSH shell:

> 
> 
> - QCS6490
> 
> 
> 
> > 
> > 
> > # echo 0x120 > /sys/module/camera_qcm6490/parameters/debug_mdl
> >         # cat /var/log/kern.log > name_of_kmd_logs.txt
> >         Copy to clipboard
> - QCS9075/QCS8275
> 
> 
> 
> > 
> > 
> > # echo 0x120 > /sys/module/camera_qcs9100/parameters/debug_mdl
> >         # cat /var/log/kern.log > name_of_kmd_logs.txt
> >         Copy to clipboard
> - QCS615
> 
> 
> 
> > 
> > 
> > # echo 0x120 > /sys/module/camera_qcs615/parameters/debug_mdl
> >         # cat /var/log/kern.log > name_of_kmd_logs.txt
> >         Copy to clipboard

2. To enable CSID IRQ logs dynamically, use the appropriate mask value(s) with the following commands.

    - QCS6490

> 
> 
> # mount -t debugfs none /sys/kernel/debug/
>             # echo MASKVALUE > /sys/kernel/debug/camera_ife/ife_csid_debug
>             Copy to clipboard
    - QCS9075/QCS8275/QCS615

> 
> 
> # mount -t debugfs none /sys/kernel/debug/
>             # echo MASKVALUE > /sys/kernel/debug/camera/ife/ife_csid_debug
>             Copy to clipboard

    The following table lists the CSID debug groups.

    | CSID debug group | Value | Description |
    | --- | --- | --- |
    | CSID\_DEBUG\_ENABLE\_SOF\_IRQ | (1&lt;&lt; 0) | Start of frame |
    | CSID\_DEBUG\_ENABLE\_EOF\_IRQ | (1&lt;&lt; 1) | End of frame |
    | CSID\_DEBUG\_ENABLE\_SOT\_IRQ | (1&lt;&lt; 2) | Start of transmission |
    | CSID\_DEBUG\_ENABLE\_EOT\_IRQ | (1&lt;&lt; 3) | End of transmission |
    | CSID\_DEBUG\_ENABLE\_SHORT\_PKT\_CAPTURE | (1&lt;&lt; 4) | Short packet capture |
    | CSID\_DEBUG\_ENABLE\_LONG\_PKT\_CAPTURE | (1&lt;&lt; 5) | Long packet capture |
    | CSID\_DEBUG\_ENABLE\_CPHY\_PKT\_CAPTURE | (1&lt;&lt; 6) | CPHY packet capture |

    For example:

> 
> 
> - To enable SOF, EOF, SOT, and EOT IRQs:
> 
> 
> 
> > 
> > 
> > # echo 0xf > /sys/kernel/debug/camera/ife/ife_csid_debug
> >             Copy to clipboard
>     - To set only short packet and long packet capture IRQs:
> 
> 
> 
> > 
> > 
> > # echo 0x30 > /sys/kernel/debug/camera/ife/ife_csid_debug
> >             Copy to clipboard

    Information is logged to kmsg and can be obtained using the following command:

> 
> 
> # cat /var/log/kern.log > name_of_kmd_logs.txt
>         Copy to clipboard

    The captured logs can help provide details about the SOF and EOF and indicate which sensor is streaming. The following is an example log:

> 
> 
> CAM_INFO: CAM-ISP: cam_ife_csid_irq: 5288 CSID:1 IPP SOF received
>         CAM_INFO: CAM-ISP: cam_ife_csid_irq: 5300 CSID:1 IPP EOF received
>         CAM_INFO: CAM-ISP: cam_ife_csid_irq: 5288 CSID:1 IPP SOF received
>         CAM_INFO: CAM-ISP: cam_ife_csid_irq: 5300 CSID:1 IPP EOF received
>         CAM_INFO: CAM-ISP: cam_ife_csid_irq: 5288 CSID:1 IPP SOF received
>         CAM_INFO: CAM-ISP: cam_ife_csid_irq: 5300 CSID:1 IPP EOF received
>         Copy to clipboard

### Enable CSIPHY log dumps

To enable CSIPHY log dumps:

1. Use the following command to get log dumps from CSIPHY:

> 
> 
> # echo 1 > /sys/module/camera_<chipset_name>/parameters/csiphy_dump
>     Copy to clipboard
> 
> 
> The information is logged to kmsg.

2. Use the following command to obtain the log dump file:

> 
> 
> # cat /proc/kmsg > name_of_kmd_logs.txt
>     Copy to clipboard

Note

In these logs, `<chipset name>` corresponds to the following:

> 
> 
> - `qcm6490` - RB3gen2
> - `qcs9100` - RB8/RB4
> - `qcs615` - IQ-615-EVK

### Enable CSID SOF/EOF IRQ logs

To enable CSID SOF/EOF IRQ logs, run the following commands for trace logs:

# mount -t debugfs none /sys/kernel/debug/
    # echo 0x8 > /sys/module/camera_<chipset_name>/parameters/debug_mdl
    
    # For RB3gen2
    # echo 3 >/sys/kernel/debug/camera/camera_ife/ife_csid_debug
    
    # For RB8 / RB4 / IQ-615-EVK
    # echo 3 >/sys/kernel/debug/camera/ife/ife_csid_debug
    Copy to clipboard

Note

In these logs, `<chipset name>` corresponds to the following:

> 
> 
> - `qcm6490` - RB3gen2
> - `qcs9100` - RB8/RB4
> - `qcs615` - IQ-615-EVK

### Collect CPAS logs

To collect clock voting information in the camera log:

1. Run the following command using `camxoverridesettings.txt` for core, HAL, IFE, and power:

> 
> 
> # echo "logInfoMask=0x500C8" >> /var/cache/camera/camxoverridesettings.txt
>     Copy to clipboard

2. After rebooting, enable the KMD CAM\_CPAS|CAM\_PERF|CAM\_REQ mask:

> 
> 
> # echo 0x3000004 > /sys/module/camera_<chipset_name>/parameters/debug_mdl
>     # echo 0x1 > /sys/module/camera_<chipset_name>/parameters/cpas_dump
>     Copy to clipboard

3. Collect the log, and run the use case:

> 
> 
> # cat /var/log/messages > log.txt
>     # cat /proc/kmsg > kmesg. txt
>     Copy to clipboard

Note

In these logs, `<chipset name>` corresponds to the following:

> 
> 
> - `qcm6490` - RB3gen2
> - `qcs9100` - RB8/RB4
> - `qcs615` - IQ-615-EVK

### Enable kernel run-time log mask

Run the following command to enable CRM logs:

# echo 0x10 > /sys/module/camera_<chipset_name>/parameters/debug_mdl
    Copy to clipboard

For example, to enable CRM, ISP, and CPAS logs:

# echo 0x1C > /sys/module/camera_<chipset_name>/parameters/debug_mdl
    Copy to clipboard

Note

In these logs, `<chipset name>` corresponds to the following:

> 
> 
> - `qcm6490` - RB3gen2
> - `qcs9100` - RB8/RB4
> - `qcs615` - IQ-615-EVK

No device reboot is required. If you reboot, run this command again before opening the camera application.

The following list provides the debug bitmask for each driver.

CAM_CDM (1 << 0)
    CAM_CORE (1 << 1)
    CAM_CPAS (1 << 2)
    CAM_ISP (1 << 3)
    CAM_CRM (1 << 4)
    CAM_SENSOR (1 << 5)
    CAM_SMMU (1 << 6)
    CAM_SYNC (1 << 7)
    CAM_ICP (1 << 8)
    CAM_JPEG (1 << 9)
    CAM_FD (1 << 10)
    CAM_LRME (1 << 11)
    CAM_FLASH (1 << 12)
    CAM_ACTUATOR (1 << 13)
    CAM_CCI (1 << 14)
    CAM_CSIPHY (1 << 15)
    CAM_EEPROM (1 << 16)
    CAM_UTIL (1 << 17)
    CAM_HFI (1 << 18)
    CAM_CTXT (1 << 19)
    CAM_OIS (1 << 20)
    CAM_RES(1 << 21)
    CAM_MEM (1 << 22) /*Memory manager logs*/ CAM_IRQ_CTRL(1 << 23)
    CAM_REQ (1 << 24) /*Tracks a request across kernel drivers*/ CAM_PERF (1 << 25) /*Performance related logs i.e. clk, BW vote etc*/ CAM_CUSTOM (1 << 26)
    CAM_PRESIL (1 << 27)
    CAM_OPE (1 << 28)
    CAM_IO_ACCESS (1 << 29)
    CAM_SFE (1 << 30)
    CAM_IR_LED (1 << 31)
    Copy to clipboard

Last Published: May 26, 2026

[Previous Topic
Switch linear vs. SHDR mode automatically](https://docs.qualcomm.com/bundle/publicresource/80-80022-17/topics/auto-linear-vs-shdr-mode-switch.md) [Next Topic
References](https://docs.qualcomm.com/bundle/publicresource/80-80022-17/topics/references.md)