• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[ROM][UNOFFICIAL][Android 11]LineageOS 18.1 for Moto E5 Play (James)

Search This thread

musical_chairs

Senior Member
Mar 6, 2012
1,070
1,219
2okPze5.png

Please read this entire post before attempting to install!!

This ROM is built for and tested on a moto e5 play "james" XT1921-1 (Comcast). I think it will work on the other "james" variants. If you're asking about hannah or pettyl or another e5 variant...don't. I build for my own phone, because I feel like it.

Code:
/*
* Your warranty is now void.
*
* I am not responsible for bricked devices, dead SD cards,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you get upset at me for messing up your device, I will feel bad and go away.
*
*/


LineageOS is based on the Android Open Source Project with extra contributions from many people within the Android community. It can be used without any need to have any Google application installed. Linked below is a package that has come from another Android project that restores the Google parts. LineageOS does still include various hardware-specific code, which is also slowly being open-sourced anyway.

Instructions:
Follow Instructions Carefully - installation will fail otherwise :

  • WARNING: There doesn't seem to be a way to back up and restore using the 64 bit TWRP (probably due to forced encryption). Your data is toast if you install this, and toast again if you mess up a later installation. YOU HAVE BEEN WARNED!
  • Download TWRP for james from whodat711's Lineage 17.1 thread, linked below.
  • fastboot boot twrp-james-bootonly.img (ONLY BOOT IT!! TOO BIG TO FLASH!)
  • -- then --
  • Wipe -> ADVANCED -- select system + vendor -> SWIPE TO WIPE
  • reboot bootloader
  • fastboot boot recovery again
  • -- then --
  • Format data, Wipe cache & dalvik-cache
  • Flash ROM, Gapps 11 arm64 together (Download Gapps from downloads section)
  • Done-Reboot Now
  • Wait...and wait... the first boot takes 8 minutes (with gapps).

What's working:
  • WiFi
  • Camera and Camcorder
  • Bluetooth
  • Fingerprint
  • GPS
  • Sensors
  • Video Playback
  • Audio
  • RIL (Calls, sms/mms, VoLTE)
  • SELinux: Enforcing

Known issues:
  • Trust complains about the build being signed with a public key. This is an unofficial build, so it is slightly less secure. The warning can be turned off in settings.
Downloads:

Reporting Bugs
  • I guess just post them to this thread. I probably can't help, but maybe somebody else can.

Thanks to:
@whodat711 for bringing Lineage 17.1 to james.
@JarlPenguin for maintaining the kernel, vendor, and common-device trees.
(Note: If either of you want to build 18.1 for james, I will gladly run your builds and stop posting my own.)
The LineageOS team

Changelogs:

Code:
2021-06-13:
Initial 18.1 release.

2021-07-14:
Video recording sync issue is fixed.
Fix some SELinux denials.
July security patch.

2021-08-08:
August security patch.
Remove unneeded camera libs.

2021-10-10:
October security patch.


Source code:
 
Last edited:

Ayoseun

Senior Member
Aug 15, 2017
171
29
Almost 5days as a daily driver ,ROM is buttery smooth, no random reboot, no system failure , camera works 100% fine no failure whatsoever.
 

musical_chairs

Senior Member
Mar 6, 2012
1,070
1,219
Here I am, asking for help in my own thread...

Video camera is not using the correct clock source. Immediately on bootup, videos record properly. If the device sleeps, video will be later than audio by the sleep time. Audio plays at the beginning of the video (image is frozen), and moving video is at the end.

Logcat is showing the following error:
Code:
12-13 19:17:45.520     0     0 E [    1.514286,1] /soc/qcom,cam_smmu/msm_cam_smmu_cb1: could not get #iommu-cells for /soc/qcom,[email protected]
12-13 19:17:45.520     0     0 E         : [    1.514895,1] CAM-SMMU cam_populate_smmu_context_banks:1586 Invalid pointer of ctx : vfe_secure rc = -517
12-13 19:17:45.520     0     0 E         : [    1.514903,1] CAM-SMMU cam_smmu_probe:1636 Error: populating context banks
12-13 19:17:45.520     0     0 W [    1.514917,1] msm_cam_smmu: probe of soc:qcom,cam_smmu:msm_cam_smmu_cb2 failed with error -12
12-13 19:17:45.520     0     0 E [    1.514949,1] /soc/qcom,cam_smmu/msm_cam_smmu_cb3: could not get #iommu-cells for /soc/qcom,[email protected]
12-13 19:17:45.520     0     0 E [    1.515237,1] /soc/qcom,cam_smmu/msm_cam_smmu_cb4: could not get #iommu-cells for /soc/qcom,[email protected]
12-13 19:17:45.520     0     0 E         : [    1.516102,1] CAM-SMMU cam_populate_smmu_context_banks:1586 Invalid pointer of ctx : vfe_secure rc = -517
12-13 19:17:45.520     0     0 E         : [    1.516109,1] CAM-SMMU cam_smmu_probe:1636 Error: populating context banks
12-13 19:17:45.520     0     0 W [    1.516121,1] msm_cam_smmu: probe of soc:qcom,cam_smmu:msm_cam_smmu_cb2 failed with error -12
12-13 19:17:45.520     0     0 E [    1.517721,1] msm_camera_get_dt_vreg_data: 1201 number of entries is 0 or not present in dts
12-13 19:17:45.520     0     0 E [    1.519965,1] msm_camera_get_dt_vreg_data: 1201 number of entries is 0 or not present in dts
12-13 19:17:45.520     0     0 E [    1.520298,1] msm_camera_get_dt_vreg_data: 1201 number of entries is 0 or not present in dts
12-13 19:17:45.520     0     0 E [    1.521149,1] msm_camera_get_dt_vreg_data: 1201 number of entries is 0 or not present in dts
12-13 19:17:45.520     0     0 E [    1.521409,1] msm_camera_get_dt_vreg_data: 1201 number of entries is 0 or not present in dts
12-13 19:17:45.520     0     0 E [    1.521657,1] msm_camera_get_dt_vreg_data: 1201 number of entries is 0 or not present in dts
12-13 19:17:45.520     0     0 I [    1.522825,1] msm_actuator_platform_probe: 2088 No valid actuator GPIOs data
12-13 19:17:45.520     0     0 E         : [    1.523701,1] msm_eeprom_platform_probe failed 2192
12-13 19:17:45.520     0     0 E         : [    1.524066,1] msm_eeprom_platform_probe failed 2192
12-13 19:17:45.520     0     0 E [    1.525104,1] msm_flash_get_pmic_source_info: 989 alternate current: read failed
12-13 19:17:45.520     0     0 E [    1.525113,1] msm_flash_get_pmic_source_info: 1009 alternate max-current: read failed
12-13 19:17:45.520     0     0 E [    1.525120,1] msm_flash_get_pmic_source_info: 1029 alternate duration: read failed
12-13 19:17:45.520     0     0 E [    1.525130,1] msm_flash_get_pmic_source_info: 989 alternate current: read failed
12-13 19:17:45.520     0     0 E [    1.525136,1] msm_flash_get_pmic_source_info: 1009 alternate max-current: read failed
12-13 19:17:45.520     0     0 E [    1.525143,1] msm_flash_get_pmic_source_info: 1029 alternate duration: read failed
12-13 19:17:45.520     0     0 E [    1.525155,1] msm_flash_get_pmic_source_info: 1099 alternate current: read failed
12-13 19:17:45.520     0     0 E [    1.525162,1] msm_flash_get_pmic_source_info: 1119 alternate current: read failed
12-13 19:17:45.520     0     0 E [    1.525172,1] msm_flash_get_pmic_source_info: 1099 alternate current: read failed
12-13 19:17:45.520     0     0 E [    1.525178,1] msm_flash_get_pmic_source_info: 1119 alternate current: read failed
12-13 19:17:45.520     0     0 I [    1.525186,1] msm_flash_get_dt_data: 1192 No valid flash GPIOs data
12-13 19:17:45.520     0     0 E [    1.525192,1] msm_camera_get_dt_vreg_data: 1201 number of entries is 0 or not present in dts
12-13 19:17:45.520     0     0 E         : [    1.526443,1] adp1660 i2c_add_driver success
12-13 19:17:45.520     0     0 E         : [    1.528211,1] msm_camera_get_dt_gpio_set_tbl failed 794
12-13 19:17:45.520     0     0 E         : [    1.528527,1] msm_camera_get_dt_gpio_set_tbl failed 794
12-13 19:17:45.520     0     0 W         : [    1.531600,1] ------------[ cut here ]------------
12-13 19:17:45.520     0     0 W [    1.531614,1] WARNING: CPU: 1 PID: 1 at /media/Data/android/LOS18/kernel/motorola/msm8953/drivers/clk/msm/clock-local2.c:234 rcg_clk_enable+0x98/0x9c()
12-13 19:17:45.520     0     0 W         : [    1.531620,1] Attempting to prepare camss_top_ahb_clk_src before setting its rate. Set the rate first!
12-13 19:17:45.520     0     0 W         : [    1.531626,1] Modules linked in:
12-13 19:17:45.520     0     0 W [    1.531636,1] CPU: 1 PID: 1 Comm: swapper/0 Not tainted 3.18.140-perf-g7dcd956f3beb #2
12-13 19:17:45.520     0     0 W         : [    1.531641,1] Hardware name: james (DT)
12-13 19:17:45.520     0     0 F         : [    1.531646,1] Call trace:
12-13 19:17:45.520     0     0 W         : [    1.531655,1] [<ffffffc00008b8fc>] dump_backtrace+0x0/0x2d0
12-13 19:17:45.520     0     0 W         : [    1.531662,1] [<ffffffc00008b8f4>] show_stack+0x14/0x1c
12-13 19:17:45.520     0     0 W         : [    1.531670,1] [<ffffffc00039f7e8>] dump_stack+0xac/0xe4
12-13 19:17:45.520     0     0 W         : [    1.531678,1] [<ffffffc0000aa15c>] warn_slowpath_common+0xa0/0xe4
12-13 19:17:45.520     0     0 W         : [    1.531685,1] [<ffffffc0000aa098>] warn_slowpath_fmt+0x50/0x74
12-13 19:17:45.520     0     0 W         : [    1.531692,1] [<ffffffc000ac3590>] rcg_clk_enable+0x98/0x9c
12-13 19:17:45.520     0     0 W         : [    1.531699,1] [<ffffffc000ac0284>] clk_enable+0x180/0x1bc
12-13 19:17:45.520     0     0 W         : [    1.531706,1] [<ffffffc000ac019c>] clk_enable+0x98/0x1bc
12-13 19:17:45.520     0     0 W         : [    1.531715,1] [<ffffffc0008723f4>] msm_camera_clk_enable+0xd4/0x238
12-13 19:17:45.520     0     0 W         : [    1.531722,1] [<ffffffc00089c000>] cpp_init_hardware+0x7c/0x4bc
12-13 19:17:45.520     0     0 W         : [    1.531729,1] [<ffffffc00089bae8>] cpp_probe+0x318/0x670
12-13 19:17:45.520     0     0 W         : [    1.531737,1] [<ffffffc0005c73f4>] platform_drv_probe+0x3c/0x88
12-13 19:17:45.520     0     0 W         : [    1.531744,1] [<ffffffc0005c4f7c>] driver_probe_device+0xc8/0x1f8
12-13 19:17:45.520     0     0 W         : [    1.531750,1] [<ffffffc0005c52b8>] __driver_attach+0x64/0x90
12-13 19:17:45.520     0     0 W         : [    1.531759,1] [<ffffffc0005c34dc>] bus_for_each_dev+0x80/0xc8
12-13 19:17:45.520     0     0 W         : [    1.531765,1] [<ffffffc0005c524c>] driver_attach+0x20/0x28
12-13 19:17:45.520     0     0 W         : [    1.531772,1] [<ffffffc0005c3c8c>] bus_add_driver+0x118/0x1e0
12-13 19:17:45.520     0     0 W         : [    1.531778,1] [<ffffffc0005c6074>] driver_register+0x8c/0xd8
12-13 19:17:45.520     0     0 W         : [    1.531785,1] [<ffffffc0005c73b0>] __platform_driver_register+0x5c/0x64
12-13 19:17:45.520     0     0 W         : [    1.531793,1] [<ffffffc0014f9610>] msm_cpp_init_module+0x18/0x20
12-13 19:17:45.520     0     0 W         : [    1.531800,1] [<ffffffc000082b78>] do_one_initcall+0xd8/0x1b0
12-13 19:17:45.520     0     0 W         : [    1.531808,1] [<ffffffc0014b7bc0>] kernel_init_freeable+0x144/0x1d4
12-13 19:17:45.520     0     0 W         : [    1.531816,1] [<ffffffc000de2c64>] kernel_init+0x10/0x124
12-13 19:17:45.520     0     0 W         : [    1.531840,1] ---[ end trace 3c7185295746ec5f ]---
I appreciate any help or suggestions anyone can give me!
 
  • Haha
Reactions: GOOGLE_USER

Xt4

Member
Jul 3, 2021
7
1
France
Hi musical_chairs,
first thank you for this custom ROM.
It's working fine except :
-the videorecorder (same issue you have sound first image at the end)
-GPS not working

I have xt1921-1, just flashed the rom (no gapps and no root).

Will post the logcat for GPS soon.
 
Last edited:

m3dteam

Senior Member
Apr 22, 2011
113
18
Thanks musical_chair for making this ROM. I am trying to build it on my own but it seems that I am hitting a wall.

First here is my .repo/local_manifests/roomservice.xml: (let me know if I am missing anything, I suspect that this is the root of my issues)
Code:
<?xml version="1.0" encoding="UTF-8"?>
<manifest>
  <project path="device/motorola/james" remote="github" name="musical-chairs/android_device_motorola_james" />
  <project path="device/motorola/msm8937-common" remote="github" name="musical-chairs/android_device_motorola_msm8937-common" />
  <project path="kernel/motorola/msm8953" remote="github" name="musical-chairs/android_kernel_motorola_msm8953" />
  <project path="vendor/motorola" remote="github" name="musical-chairs/proprietary_vendor_motorola" revision="lineage-18.1-james"/>
</manifest>

The issue is that whenever I run james/extract-files.sh I am getting:
Code:
$DEVICE must be set before including this script!

I added echo "$1" to extract-utils.sh and it is really blank, and removed all if blocks in msm8937-common/extract-files.sh that dont have setup_vendor "${DEVICE}", and I could not figure out where is it getting called from.

it is happening because "${BOARD_COMMON}" is blank, where is it supposed to be setup?

any help from your side would be greatly appreciated.


Update:
if I set BOARD_COMMON=msm8937-common [same as in hannah-common] the scripts starts pulling alot of files from lib64, which don't exit in a 32 bit device. This is telling me that BOARD_COMMON is supposed to be blank, but if that is the case, then why is the script always failing?


Update2: so I decided to build lineage os 17.1 for james from @whodat711 and it completed successfully. It is most likely that some of the paths in my manifest are wrong/not compatible with each other.
 
Last edited:

musical_chairs

Senior Member
Mar 6, 2012
1,070
1,219
The issue is that whenever I run james/extract-files.sh I am getting:
Code:
$DEVICE must be set before including this script!
It's probably happening because I haven't given extract-files.sh any attention; I'm not used to working that way - I just build from the vendor tree. So something is probably messed up there. I just lunch and make bacon.

You'll want to switch the vendor tree to the lineage-18.1-james2 branch as I did my best to unify my vendor tree to JarlPenguin's, to keep it in sync with his device tree. I don't think the build will boot without doing that.

I have some updates to push as soon as I get a chance. I fixed the error I posted earlier, also fixed some camera-related SELinux denials. Unfortunately, video record sync is still borked. Once I get a few minutes to clean everything up, I'll push my latest changes to github and then try to get a new build up.
 

m3dteam

Senior Member
Apr 22, 2011
113
18
Ok, so I can just do the following:
Code:
repo init -u https://github.com/LineageOS/android.git -b lineage-18.1
repo sync
croot
lunch james-userdebug
make bacon
And that should be enough to build the rom, right?

Also, how did you make the vendor tree (in case if I have a different device )? did you just copy everything from /vendor/ & /system/ from your stock phone?

oh, also, this the mainfist you used, right?
Code:
<manifest>
  <project path="device/motorola/james" remote="github" name="musical-chairs/android_device_motorola_james" />
  <project path="device/motorola/msm8937-common" remote="github" name="musical-chairs/android_device_motorola_msm8937-common" />
  <project path="kernel/motorola/msm8953" remote="github" name="musical-chairs/android_kernel_motorola_msm8953" />
  <project path="vendor/motorola" remote="github" name="musical-chairs/proprietary_vendor_motorola" revision="lineage-18.1-james2"/>
</manifest>

Many thanks for your help, this is my first build.
 
Last edited:

musical_chairs

Senior Member
Mar 6, 2012
1,070
1,219
Ok, so I can just do the following:
Code:
repo init -u https://github.com/LineageOS/android.git -b lineage-18.1
repo sync
croot
lunch james-userdebug
make bacon
And that should be enough to build the rom, right?
Something like that. I do
Code:
source build/envsetup.sh
instead of croot, but maybe my way is outdated.

Also, how did you make the vendor tree (in case if I have a different device )? did you just copy everything from /vendor/ & /system/ from your stock phone?
I fork other people's vendor trees and use them as a base. For james, I used https://github.com/moto-msm8937/proprietary_vendor_motorola and https://github.com/HyperTeam/proprietary_vendor_motorola. I've never tried to start from scratch on a new device. I'm not quite on that level.

oh, also, this the mainfist you used, right?
Code:
<manifest>
  <project path="device/motorola/james" remote="github" name="musical-chairs/android_device_motorola_james" />
  <project path="device/motorola/msm8937-common" remote="github" name="musical-chairs/android_device_motorola_msm8937-common" />
  <project path="kernel/motorola/msm8953" remote="github" name="musical-chairs/android_kernel_motorola_msm8953" />
  <project path="vendor/motorola" remote="github" name="musical-chairs/proprietary_vendor_motorola" revision="lineage-18.1-james2"/>
</manifest>

Many thanks for your help, this is my first build.
Yup, that's what I'm working with. I believe I had to add
Code:
  <!--Dependencies-->
  <project path="external/bson" name="LineageOS/android_external_bson" />
  <project path="system/qcom" name="LineageOS/android_system_qcom" />
to get it to build successfully.

You're welcome! Hopefully it is a pleasant learning experience for you!
 

m3dteam

Senior Member
Apr 22, 2011
113
18
Many thanks, I will update the manifest, use your method and report back.
Also, I noticed that @whodat711 used msm8937 kernel while you are using msm8953? I am guessing it is because 17.1 vs 18.1
 

Top Liked Posts

  • There are no posts matching your filters.
  • 1
    Hi folks! There's a new build up. There aren't any major changes, it's just the updated security patches. The link is in the OP. Enjoy!
    1
    Android 12 build coming soon?:sneaky:
    by the way this Rom is great I don't know why it's not Official on LineageOS website well apart from front Flash it doesn't work but everything is perfect
    Thanks! I guess I've been too lazy to do the work of pursuing official builds. For a while the vendor tree was a royal mess, there's no way any maintainer in their right mind would have merged it.

    The front flash works in Open Camera, though not with the Lineage camera app - I haven't yet figured out how to enable it there.
  • 3
    2okPze5.png

    Please read this entire post before attempting to install!!

    This ROM is built for and tested on a moto e5 play "james" XT1921-1 (Comcast). I think it will work on the other "james" variants. If you're asking about hannah or pettyl or another e5 variant...don't. I build for my own phone, because I feel like it.

    Code:
    /*
    * Your warranty is now void.
    *
    * I am not responsible for bricked devices, dead SD cards,
    * thermonuclear war, or you getting fired because the alarm app failed. Please
    * do some research if you have any concerns about features included in this ROM
    * before flashing it! YOU are choosing to make these modifications, and if
    * you get upset at me for messing up your device, I will feel bad and go away.
    *
    */


    LineageOS is based on the Android Open Source Project with extra contributions from many people within the Android community. It can be used without any need to have any Google application installed. Linked below is a package that has come from another Android project that restores the Google parts. LineageOS does still include various hardware-specific code, which is also slowly being open-sourced anyway.

    Instructions:
    Follow Instructions Carefully - installation will fail otherwise :

    • WARNING: There doesn't seem to be a way to back up and restore using the 64 bit TWRP (probably due to forced encryption). Your data is toast if you install this, and toast again if you mess up a later installation. YOU HAVE BEEN WARNED!
    • Download TWRP for james from whodat711's Lineage 17.1 thread, linked below.
    • fastboot boot twrp-james-bootonly.img (ONLY BOOT IT!! TOO BIG TO FLASH!)
    • -- then --
    • Wipe -> ADVANCED -- select system + vendor -> SWIPE TO WIPE
    • reboot bootloader
    • fastboot boot recovery again
    • -- then --
    • Format data, Wipe cache & dalvik-cache
    • Flash ROM, Gapps 11 arm64 together (Download Gapps from downloads section)
    • Done-Reboot Now
    • Wait...and wait... the first boot takes 8 minutes (with gapps).

    What's working:
    • WiFi
    • Camera and Camcorder
    • Bluetooth
    • Fingerprint
    • GPS
    • Sensors
    • Video Playback
    • Audio
    • RIL (Calls, sms/mms, VoLTE)
    • SELinux: Enforcing

    Known issues:
    • Trust complains about the build being signed with a public key. This is an unofficial build, so it is slightly less secure. The warning can be turned off in settings.
    Downloads:

    Reporting Bugs
    • I guess just post them to this thread. I probably can't help, but maybe somebody else can.

    Thanks to:
    @whodat711 for bringing Lineage 17.1 to james.
    @JarlPenguin for maintaining the kernel, vendor, and common-device trees.
    (Note: If either of you want to build 18.1 for james, I will gladly run your builds and stop posting my own.)
    The LineageOS team

    Changelogs:

    Code:
    2021-06-13:
    Initial 18.1 release.
    
    2021-07-14:
    Video recording sync issue is fixed.
    Fix some SELinux denials.
    July security patch.
    
    2021-08-08:
    August security patch.
    Remove unneeded camera libs.
    
    2021-10-10:
    October security patch.


    Source code:
    2
    just flashed it now , everything going fine, not a bug seen
    Great! Thanks for the feedback.
    2
    Ok, so I can just do the following:
    Code:
    repo init -u https://github.com/LineageOS/android.git -b lineage-18.1
    repo sync
    croot
    lunch james-userdebug
    make bacon
    And that should be enough to build the rom, right?
    Something like that. I do
    Code:
    source build/envsetup.sh
    instead of croot, but maybe my way is outdated.

    Also, how did you make the vendor tree (in case if I have a different device )? did you just copy everything from /vendor/ & /system/ from your stock phone?
    I fork other people's vendor trees and use them as a base. For james, I used https://github.com/moto-msm8937/proprietary_vendor_motorola and https://github.com/HyperTeam/proprietary_vendor_motorola. I've never tried to start from scratch on a new device. I'm not quite on that level.

    oh, also, this the mainfist you used, right?
    Code:
    <manifest>
      <project path="device/motorola/james" remote="github" name="musical-chairs/android_device_motorola_james" />
      <project path="device/motorola/msm8937-common" remote="github" name="musical-chairs/android_device_motorola_msm8937-common" />
      <project path="kernel/motorola/msm8953" remote="github" name="musical-chairs/android_kernel_motorola_msm8953" />
      <project path="vendor/motorola" remote="github" name="musical-chairs/proprietary_vendor_motorola" revision="lineage-18.1-james2"/>
    </manifest>

    Many thanks for your help, this is my first build.
    Yup, that's what I'm working with. I believe I had to add
    Code:
      <!--Dependencies-->
      <project path="external/bson" name="LineageOS/android_external_bson" />
      <project path="system/qcom" name="LineageOS/android_system_qcom" />
    to get it to build successfully.

    You're welcome! Hopefully it is a pleasant learning experience for you!
    2
    The issue is that whenever I run james/extract-files.sh I am getting:
    Code:
    $DEVICE must be set before including this script!
    It's probably happening because I haven't given extract-files.sh any attention; I'm not used to working that way - I just build from the vendor tree. So something is probably messed up there. I just lunch and make bacon.

    You'll want to switch the vendor tree to the lineage-18.1-james2 branch as I did my best to unify my vendor tree to JarlPenguin's, to keep it in sync with his device tree. I don't think the build will boot without doing that.

    I have some updates to push as soon as I get a chance. I fixed the error I posted earlier, also fixed some camera-related SELinux denials. Unfortunately, video record sync is still borked. Once I get a few minutes to clean everything up, I'll push my latest changes to github and then try to get a new build up.
    1
    i love you man