[Moto G5 ROMs, Kernels, Recoveries, & Other Develop] christianix:
Kernel update

I'd like to have an updated kernel, so I have all the latest security fixes from upstream. That's why I'm running a Lineageos 14.1 with device and vendor repos from [MENTION=6810779]wzedlare[/MENTION] and Kernel from [MENTION=5532305]sohamlad7[/MENTION]: https://github.com/Sohamlad7/android_kernel_motorola_msm8937.git.

With a few patches it seems to work well, except for the camera. The camera app crashes on start:

07-01 11:33:22.577 4959 4959 I CameraManagerGlobal: Connecting to camera service
07-01 11:33:22.583 4959 4959 D CAM_Activity: Camera API 2 supported: false
07-01 11:33:22.583 4959 4959 D CAM_Activity: Camera API 2 enabled: false
...
07-01 11:33:22.651 4959 4987 V CAM_PhotoModule: Open camera device.
07-01 11:33:22.651 4959 4987 V CameraHolder: open camera 0
07-01 11:33:22.653 4959 4987 E CameraHolder: fail to connect Camera:-1, aborting.
07-01 11:33:22.653 4959 4987 E CAM_PhotoModule: Failed to open camera:0

In the kernel log I see the following messages:

[ 0.520628,2] /soc/qcom,cam_smmu/msm_cam_smmu_cb1: could not get #iommu-cells for /soc/qcom,iommu@1e00000
[ 0.520659,2] /soc/qcom,cam_smmu/msm_cam_smmu_cb3: could not get #iommu-cells for /soc/qcom,iommu@1e00000
[ 0.520687,2] /soc/qcom,cam_smmu/msm_cam_smmu_cb4: could not get #iommu-cells for /soc/qcom,iommu@1e00000
...
[ 1.223593,3] /soc/qcom,cam_smmu/msm_cam_smmu_cb1: could not get #iommu-cells for /soc/qcom,iommu@1e00000
[ 1.224081,3] CAM-SMMU cam_populate_smmu_context_banks:1586 Invalid pointer of ctx : vfe_secure rc = -517
[ 1.224089,3] CAM-SMMU cam_smmu_probe:1636 Error: populating context banks
[ 1.224103,3] msm_cam_smmu: probe of soc:qcom,cam_smmu:msm_cam_smmu_cb2 failed with error -12
[ 1.224149,3] /soc/qcom,cam_smmu/msm_cam_smmu_cb3: could not get #iommu-cells for /soc/qcom,iommu@1e00000
[ 1.224415,3] /soc/qcom,cam_smmu/msm_cam_smmu_cb4: could not get #iommu-cells for /soc/qcom,iommu@1e00000
[ 1.224872,3] CAM-SMMU cam_populate_smmu_context_banks:1586 Invalid pointer of ctx : vfe_secure rc = -517
[ 1.224880,3] CAM-SMMU cam_smmu_probe:1636 Error: populating context banks
[ 1.224890,3] msm_cam_smmu: probe of soc:qcom,cam_smmu:msm_cam_smmu_cb2 failed with error -12
[ 1.227000,3] msm_camera_get_dt_vreg_data:1198 number of entries is 0 or not present in dts
...
[ 1.246721,3] CAM-SOC msm_camera_get_reg_base:787 err: mem resource vfe_fuse not found
[ 1.246729,3] CAM-SOC msm_camera_get_res_size:830 err: mem resource vfe_fuse not found
[ 1.248232,3] CAM-SOC msm_camera_get_reg_base:787 err: mem resource vfe_fuse not found
[ 1.248240,3] CAM-SOC msm_camera_get_res_size:830 err: mem resource vfe_fuse not found
...
[ 3.075190,5] init: SELinux: Could not set context for /persist/camera: Operation not supported on transport endpoint
[ 3.075603,5] init: SELinux: Could not set context for /persist/camera/focus: Operation not supported on transport endpoint
[ 3.075753,5] init: SELinux: Could not set context for /persist/camera/ledcal: Operation not supported on transport endpoint

Does anyone have an idea what could go wrong? Device tree was my first guess. But diff with Motorola kernel looks good. :confused:

If the ROM works for me, I'll share it here, of course. If anyone is interested, I can also provide you with my default kernel config and the patch.