yashsingh1/xdaforums huggingface dataset:
[Android Software/Hacking General [Developers Only]] nathanchance:
Number 7 should be

export CROSS_COMPILE=$(pwd)/aarch64-linux-android-4.9/bin/aarch64-linux-android-
[Android Software/Hacking General [Developers Only]] zurik:
That works now....

I now typed "make bullhead_defconfig" and I get this now:

HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
SHIPPED scripts/kconfig/zconf.tab.c
SHIPPED scripts/kconfig/zconf.lex.c
SHIPPED scripts/kconfig/zconf.hash.c
HOSTCC scripts/kconfig/zconf.tab.o
In file included from scripts/kconfig/zconf.tab.c:2503:0:
scripts/kconfig/menu.c: In function ‘get_symbol_str’:
scripts/kconfig/menu.c:567:18: warning: ‘jump’ may be used uninitialized in this function [-Wmaybe-uninitialized]
jump->offset = r->len - 1;
^
scripts/kconfig/menu.c:528:19: note: ‘jump’ was declared here
struct jump_key *jump;
^
HOSTLD scripts/kconfig/conf
warning: (PCI_MSM && AMD_IOMMU) selects PCI_MSI which has unmet direct dependencies (PCI && ARCH_SUPPORTS_MSI)
warning: (SND_SOC_APQ8074 && SND_SOC_MSM8994) selects SND_SOC_MSM_HDMI_CODEC_RX which has unmet direct dependencies (SOUND && !M68K && !UML && SND && SND_SOC && FB_MSM_MDSS_HDMI_PANEL && (SND_SOC_MSM8974 || SND_SOC_APQ8084 || SND_SOC_MSM8994))
warning: (ARCH_MSM) selects DEVFREQ_GOV_MSM_BW_HWMON which has unmet direct dependencies (PM_DEVFREQ && (ARCH_MSM_KRAIT || ARCH_MSM_BIMC_BWMON))
warning: (PCI_MSM && AMD_IOMMU) selects PCI_MSI which has unmet direct dependencies (PCI && ARCH_SUPPORTS_MSI)
warning: (SND_SOC_APQ8074 && SND_SOC_MSM8994) selects SND_SOC_MSM_HDMI_CODEC_RX which has unmet direct dependencies (SOUND && !M68K && !UML && SND && SND_SOC && FB_MSM_MDSS_HDMI_PANEL && (SND_SOC_MSM8974 || SND_SOC_APQ8084 || SND_SOC_MSM8994))
warning: (ARCH_MSM) selects DEVFREQ_GOV_MSM_BW_HWMON which has unmet direct dependencies (PM_DEVFREQ && (ARCH_MSM_KRAIT || ARCH_MSM_BIMC_BWMON))
#
# configuration written to .config
#

I will try again...
[Android Software/Hacking General [Developers Only]] nathanchance:
That's normal, now type make -j$(nproc --all)
[Android Software/Hacking General [Developers Only]] zurik:
I started from 1 now. :)

---------- Post added at 19:40 ---------- Previous post was at 19:14 ----------

May I use the method from old guide for AnyKernel2?

These commands:

git clone https://github.com/nathanchance/AnyKernel2.git anykernel

cd /home/user/Kernel/anykernel && git checkout bullhead-stock-decrypt

???

Because on 4th step (Flash Kernel), I didn't understand what I need to do with...
[Android Software/Hacking General [Developers Only]] Uzephi:
Are you flashing it in custom recovery or editing a boot image? No TWRP on my device so I had to use Android image kitchen to replace the stock kernel with mine by unpacking the img, replace the kernel image with mine then repack. AIK has two simple commands: unpack and repack. I personally haven't tried anykernel yet
[Android Software/Hacking General [Developers Only]] zurik:
I didn't ever used the Android Image Kitchen. I have TWRP in Nexus 5X so for me, the AnyKernel2 method is more familiar to me now. I didn't know if something changed between the AnyKernel that OP provided months ago from Nexus 5X forum and this one .
[Android Software/Hacking General [Developers Only]] Uzephi:
If you're building a kernel for the 5X, I would follow that guide as it probably has the fstab info you need. for it to flash right via zip flash on custom recoveries.
[Android Software/Hacking General [Developers Only]] zurik:
I think this commands for decrypt bullhead stock is for bullhead.
[Android Software/Hacking General [Developers Only]] zurik:
Tried the method of AnyKernel from old thread for Nexus 5X and it works !!!! Thanks to Nathan for the guide! And others for commits...
[Android Software/Hacking General [Developers Only]] Yaznas:
How do i get the kernel to get built with the ROM? Everytime i try to build the kernel with the ROM, i get error like "make mrproper" after doing that the changes in kernel are gone.
[Android Software/Hacking General [Developers Only]] palmbeach05:
Yeah
[Android Software/Hacking General [Developers Only]] ebrahimwaleed:
hello i have been trying for a month now to compile kernel for my huawei enjoy max ars-al00 i tried too many tool chain i always get error related to the tool chain like error while loading shared library or there is some some missing files and -fstack-protector-strong not support by compiler i tired making it to not set any help will be lovely and what should i provide for better help
[Android Software/Hacking General [Developers Only]] newbit:
I can try to help...

What are the details of your Build / Development Environment?

And where is your Kernel Source to download?

In the Huawei Kernels I buld, was allways a little HowTo in form of a Readme.txt what one needs to do to get the source build.

Cheers

NewBit
[Android Software/Hacking General [Developers Only]] ebrahimwaleed:
i am using ubuntu desktop latest version

installed all the requirements

and here is the kernel source code

http://download-c1.huawei.com/download/downloadCenter?downloadId=100506&version=431424&siteCode=worldwide

i would to chat with you through telegram if its possible

Telegram: Contact @SimpleHima

t.me
[Android Software/Hacking General [Developers Only]] newbit:
I had quite some issues with the newest ubuntu version. Some libs were depreciated, especially the QT libs, so I had to go back to an older version for my huawei p9 plus kernel. Try a 19er Version or even lower.

Your README_Kernel.txt says very similar to the P9 Plus what to do:

Spoiler content hidden.

Check out my post How to build the kernel for your Huawei P9 Plus

There you will find the build tools to install, also the toolchain. I would try with one, that is closest

to your Kernel Date. Unsupported NDK Downloads

Btw: I assume your Bootloader is already unlocked? If not, don't bother to build the kernel.

Thanks for your Telegram offer, but lets keep the discussion here, so others can benefit from this as well.

Cheers

NewBit
[Android Software/Hacking General [Developers Only]] ebrahimwaleed:
yes my bootloader is unlocked okay i will check ur post and reply back to you and thanks in advance <3
[Android Software/Hacking General [Developers Only]] newbit:
I almost got it working. After disabling the huawei cfi feature in the devconfig, which is not the merge_msm8953_64_defconfig as in the

README_Kernel.txt proposed. It is merge_sdm660_64_defconfig

It starts compiling, with the 16 and 17 NDK toolchain. After approx. 100 manually include changes, from <> to "",

i.e. #include <athdefs.h> > #include "athdefs.h"

it kept compiling, until some missing wlan drivers in kernel/vendor/qcom/opensource/wlan/

Which I could get from the linux foundation as mentioned somewhere in the kernel source.

But still, the end of the line is a missing athdefs.h from the file: /kernel/drivers/wlan_driver/core/dp/ol/inc/ol_txrx_ctrl_api.h

This athdefs.h I couldn't find it anywhere in the source, so I took one from the linux foundation, but this just generates a ton of other issues.

Can you pull the file /proc/config.gz from your phone?

What is your kernel version? uname -a

Cheers NewBit
[Android Software/Hacking General [Developers Only]] ebrahimwaleed:
i have just updated the phone to android pie i will install twrp and root it tomorrow morning and can you tell me how to pull /proc/config.gz

and there is another source code for android pie 9.1 i dont know if this will change anything but here is pie source code

http://download-c1.huawei.com/download/downloadCenter?downloadId=100885&version=436618&siteCode=worldwide
[Android Software/Hacking General [Developers Only]] kyvaith:
Hi,

In past I've created definitions and build first Android TV x86 ISO which was near perfection, so I have some knowlage about AOSP building and troubleshooting in *nix environment.

This week I've decided to build kernel for my Nvidia Shield TV 2017 and I'm feeling like an idiot since I don't know where to start.

The problem is Nvidia released full AOSP tree only for Android 8 (GFE 7.x.x) and for Android 9 (GFE 8.x.x) there are only some definitions in manifest.:

fully buildable tree: https://nv-tegra.nvidia.com/gitweb/...artner;hb=refs/heads/rel-24-foster-r7-partner

tree I want to use to build kernel: https://nv-tegra.nvidia.com/gitweb/...source;hb=refs/heads/rel-32-shield-opensource

there is even no build tools in updated tree...

I wanted to just do mp bootimage -j5 to build boot image but it's impossible.

Also I don't know how to build kernel outside AOSP tree.

Hint: somebody compiled kernel for Pie here but author is not answering question how to do this by ourself https://xdaforums.com/t/kernel-rooted-pie-performance-enhanced-overclock-kernel.3943079/

Please point me a direction how can I build this kernel. I'd like to backport DVB support to it and aff some firmware blobs.

Thank you,

Tom.
[Android Software/Hacking General [Developers Only]] ebrahimwaleed:
update 1

i am working on phone original firmware and unlocking the bootloader after the update it is locked and the phone firmware will be updated to 9.1.0.174 but i think the kernel is the same i will check the kernel version as soon as i install the the latest firmware and back it up

update 2

after following all you steps now when i compile the kernel with FIRMWARE_sdm660_64_defconfig there are 2 missing drivers i will dump the kernel.img from the phone and try to unpack it and provide it in a link idk but i think it might help

i get

CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
HOSTCC scripts/sign-file
CHK scripts/mod/devicetable-offsets.h
HOSTCC scripts/extract-cert
find lcdkit qcom folder, include it now!
CC kernel/bounds.s
CHK include/generated/timeconst.h
UPD include/generated/timeconst.h
CHK include/generated/bounds.h
UPD include/generated/bounds.h
CC arch/arm64/kernel/asm-offsets.s
CHK include/generated/asm-offsets.h
UPD include/generated/asm-offsets.h
CALL scripts/checksyscalls.sh
drivers/wlan_driver/Kbuild:218: CONFIG_with_build_kernel
drivers/wlan_driver/Kbuild:679: drivers/../vendor/qcom/opensource/wlan/qcacld-3.0/hw_qca_decoupled/Kbuild: No such file or directory
make[2]: *** No rule to make target 'drivers/../vendor/qcom/opensource/wlan/qcacld-3.0/hw_qca_decoupled/Kbuild'. Stop.
make[1]: *** [scripts/Makefile.modbuiltin:54: drivers/wlan_driver] Error 2
make: *** [Makefile:1221: drivers/modules.builtin] Error 2
make: *** Waiting for unfinished jobs....

and thanks for all what you have done really god bless you this is the first progress i had since a month<3

Cheers
[Android Software/Hacking General [Developers Only]] ebrahimwaleed:
after doing some researches about the CFI from what i have found the cfi stands for Control flow integrity please can you have a look here " https://source.android.com/devices/tech/debug/kcfi " and here "https://android-developers.googleblog.com/2018/10/control-flow-integrity-in-android-kernel.html"
[Android Software/Hacking General [Developers Only]] tohtorin:
Hi.

I am trying to compile stock kernel for OnePlus 8T and cannot get it to build.

What I am doing wrong? Wrong clang version? (Tried 2 of em) Wrong defconfig? Wrong gcc?

I have clang r383902b and AOSP 4.9 gcc toolchain.

This is what I have tried so far:

1. git clone https://github.com/OnePlusOSS/android_kernel_oneplus_sm8250

3. cd android_kernel_oneplus_sm8250

2. git checkout oneplus/SM8250_R_11.0

3. run these exports:

export ARCH=arm64

export SUBARCH=arm64

export DTC_EXT=dtc

4. mkdir out

5. make O=out ARCH=arm64 defconfig (what is ringh config for the device? there is 3 of em:

cuttlefish_defconfig

defconfig

ranchu64_defconfig

What should I use? (Tried even grab one from phones /proc/config.gz without luck)

6. PATH=/home/user/android/clang-r383902b/bin:/home/user/android/toolchain/bin:${PATH} make -j$(nproc --all) O=out ARCH=arm64 CC=clang CLANG_TRIPLE=aarch64-linux-gnu- CROSS_COMPILE=aarch64-linux-android-

This asks few questions:

Clang Shadow Call Stack (SHADOW_CALL_STACK) [N/y/?] (NEW)

I answered no.

> 1. no automatic initialization (weakest) (INIT_STACK_NONE)

2. 0xAA-init everything on the stack (strongest) (INIT_STACK_ALL) (NEW)

choice[1-2?]:

Just pressed enter.

It starts compiling (few minutes) until it fails:

In file included from ../arch/arm64/kernel/machine_kexec.c:27:

../arch/arm64/kernel/cpu-reset.h:19:31: error: static declaration of 'cpu_soft_restart' follows non-static declaration

static inline void __noreturn cpu_soft_restart(unsigned long entry, ^

../arch/arm64/include/asm/proc-fns.h:35:6: note: previous declaration is here

void cpu_soft_restart(phys_addr_t cpu_reset,

^

../arch/arm64/kernel/machine_kexec.c:217:58: error: too many arguments to function call, expected 2, have 4

cpu_soft_restart(reboot_code_buffer_phys, kimage->head, kimage->start, 0);

~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~

../arch/arm64/include/asm/proc-fns.h:35:1: note: 'cpu_soft_restart' declared here

void cpu_soft_restart(phys_addr_t cpu_reset,

^

2 errors generated.

make[2]: *** [../scripts/Makefile.build:339: arch/arm64/kernel/machine_kexec.o] Error 1

make[1]: *** [/storage/android/android_kernel_oneplus_sm8250/Makefile:1181: arch/arm64/kernel] Error 2

make[1]: *** Waiting for unfinished jobs....

CC arch/arm64/xen/../../arm/xen/grant-table.o

CC arch/arm64/xen/../../arm/xen/p2m.o

CC arch/arm64/xen/../../arm/xen/mm.o

AS arch/arm64/xen/hypercall.o

CC arch/arm64/xen/../../arm/xen/efi.o

AR arch/arm64/xen/built-in.a

make[1]: Leaving directory '/storage/android/android_kernel_oneplus_sm8250/out'

make: *** [Makefile:146: sub-make] Error 2
[Android Software/Hacking General [Developers Only]] tohtorin:
Oh got it to work! I dont know why I needed correct op8-perf.defconfig file which did NOT come with the source tree.
[Android Software/Hacking General [Developers Only]] Sid127:
I've been trying to compile my kernel in-line with Paranoid Android Ruby, and have constantly running into this error. I've tried using different versions of clang, adding the ld path to $PATH, among many other attempts.

I'm building on Ubuntu 20.04 LTS, if that makes a difference, and here's my kernel sources

Absolutely any help is appreciated <3
[Android Software/Hacking General [Developers Only]] tohtorin:
I thought I got it to work until next error appeared:

make[3]: *** No rule to make target 'arch/arm64/boot/dts/qcom/apq8016-sbc.dtb', needed by '__build'. Stop.

make[3]: *** Waiting for unfinished jobs....

make[2]: *** [../scripts/Makefile.build:642: arch/arm64/boot/dts/qcom] Error 2

make[1]: *** [arch/arm64/Makefile:172: dtbs] Error 2

make[1]: *** Waiting for unfinished jobs....
[Android Software/Hacking General [Developers Only]] tohtorin:
I managed to get it compiled (needed few commits from another great op8 devs around the github) and it boots now. But now I am facing a new issue. It would not load default modules and my wifi wont work and probably lots of other stuff as well.

Even this commit did not help:

module.c: allow stock modules to load · tbalden/android_kernel_oneplus_sm8250@44fd595

Signed-off-by: engstk <eng.stk@sapo.pt>

github.com

When running insmod / modprobe I get warning about Required key not available.

Here is my dmesg attached from that kernel.

EDIT:

I think this is related somehow to this:

Building the GKI modules

Android 11 introduced GKI, which separates the kernel into a Google-maintained kernel image and vendor-maintained modules, which are built separately.

From https://source.android.com/setup/build/building-kernels
[Android Software/Hacking General [Developers Only]] newbit:
Yeah was wondering why you choose this kernel source, other people were already complaining about the broken wifi in the issues!

I was assuming you knew already about this and how to fix it.

sorry to hear that it doesn't work for you after all.

I don't think this is GKI related. There is no build.config.gki file in your kernel source.

Also, as far as I understood it, the GKI feature makes it even easier for us to build the kernel,

because we don't have to struggle anymore merging any vendor drivers into the kernel, this is all done by the vendor.

I did build a 5.4 Kernel from an AVD, which was built with GKI, and I totally left it out and it works very well. See my Signature.

Which defconfig file did you use?

Your log file doesn't start from [000000], there is no kernel info in it like I mentioned before.

On the AVD Kernel, it didn't wanted to boot, because the modules won't load. And they didn't load because of the missing localversion string.

After I added that string, it boots just fine.
[Android Software/Hacking General [Developers Only]] tohtorin:
I did not notice those issues on github yet.

Seems that it wont load any module on boot. And I think LTE modem is compiled inline and wifi as module and thats why wifi wont work.

When manually trying to load modules it complains something about keys. Should I turn off module signatures?

What other trees I could compile against because this tree is for my device .. ?
[Android Software/Hacking General [Developers Only]] ebrahimwaleed:
i guess there is no hope with my kernel , is there any other ways or something or what do you recommend
[Android Software/Hacking General [Developers Only]] newbit:
This sounds a bit like that extraversion thing a mentioned. In den Kernel messages you could see the kernel itself was

booting, and them when init took over, the stock kernel just kept loading module after module the custom kernel did not.

So it could be worth a shot. Maybe you could perform an AB Compare. Comparing the boot log messages from the stock

kernel with custom kernel, especially when the moduls start. I am still interested in your Kernel [0000000] String and defconfig file

pulled from proc.

Can't say much about inline and module and signatures. I didn't get this far yet of understanding the whole thing. Sorry

No Idea!

Well, this might be a bit philosophical, but nothing is really impossible, if you really want it and put the necessary effort to it

to accomplish it.

It turns out, that these missing qcacld-3.0 drivers are kind of common, so merging them into kernels is pretty often documented.

Even @nathanchance has some topics about it and in his telegram help/support group are little guides provided:

Initial merge:
git remote add qcacld-3.0 https://source.codeaurora.org/quic/la/platform/vendor/qcom-opensource/wlan/qcacld-3.0
git fetch qcacld-3.0 <TAG>
git merge -s ours --no-commit --allow-unrelated-histories FETCH_HEAD
git read-tree --prefix=drivers/staging/qcacld-3.0 -u FETCH_HEAD
git commit
Updating to a newer tag:
git fetch qcacld-3.0 <TAG>
git merge -X subtree=drivers/staging/qcacld-3.0 FETCH_HEAD
Repeat the above for
qca-wifi-host-cmn and fw-api as well.
qcacld-3.0 source: https://source.codeaurora.org/quic/la/platform/vendor/qcom-opensource/wlan/qcacld-3.0
fw-api source: https://source.codeaurora.org/quic/la/platform/vendor/qcom-opensource/wlan/fw-api
qca-wifi-host-cmn source: https://source.codeaurora.org/quic/la/platform/vendor/qcom-opensource/wlan/qca-wifi-host-cmn

So I would recommend to dig deep into this topic on how you merge these drivers into your kernel and keep going.

Cheers
[Android Software/Hacking General [Developers Only]] ebrahimwaleed:
i cant be more thankful really thank you for all your support and efforts it means alot to me i will start studying it and learn more about kernel compiling and keep trying and if i reached something i will update you ❤️
[Android Software/Hacking General [Developers Only]] tohtorin:
It was LOCALVERSION issue. Fixed. Now it compiles and boots fine. Wifi working and modules gets loaded.

But I think its weird that you need 10 commits from other people to get stock tree to compile.
[Android Software/Hacking General [Developers Only]] newbit:
Good Job! Thats very good news, congrats! You should commit this with your defconfig file and close the issues about it.

Not sure If the amount of commits is a meter to define the quality of a stock tree.

Cheers
[Android Software/Hacking General [Developers Only]] IMM02:
anyone can help me.

i have successfully built the kernel but when it is done there is no Zimage or boot.img file. there are only files "image and image.gz"
[Android Software/Hacking General [Developers Only]] newbit:
@ebrahimwaleed

Any progress so far?

I ran into a very similar issue the other days on a different project. How ever, I thought I give it another try and I was able to

get the kernel build finished. So it is up to you now to test if its booting your phone and if the wifi is working correctly.

After cloning the repo, you can run the configure gcc toolchain script and source .exports, and then you should be good to go.

git clone https://github.com/newbit1/ARES_PIE_EMUI9.1.0_opensource.git source
cd source
./configure_gcc_toolchain
source .exports
make ARCH=arm64 distclean
make ARCH=arm64 merge_sdm660_64_defconfig
time make ARCH=arm64 -j$(nproc)

Long story short, I've disintegrated drivers/wlan_driver at all,

merged and integrated the qcom-opensource drivers at first without any Huawei relations.

Until it stoped with some errors only the Huawei stuff could solve.

-> drivers/wlan_driver/hw_qca_decoupled/core/hdd/inc/hdd_auto_config_ini.h

has a lot of headers incl. that are needed.

So I used the awesome tool Meld to upgrade just the Huawei related changes from wlan_driver

to the staging/qcacld-3.0. sudo apt install meld

Especially the folder drivers/wlan_driver/core had a lot of those Huawei related changes.

So If you run into some driver issues not working properly or so, this would be your first place to look at.

@IMM02

check out your file arch/arm64/boot/Makefile

In there should be something like this

install: $(obj)/Image
$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \
$(obj)/Image System.map "$(INSTALL_PATH)"

zinstall: $(obj)/Image.gz
$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \
$(obj)/Image.gz System.map "$(INSTALL_PATH)"

Cheers

NewBit
[Android Software/Hacking General [Developers Only]] IMM02:
like this?

#

# arch/arm64/boot/Makefile

#

# This file is included by the global makefile so that you can add your own

# architecture-specific flags and dependencies.

#

# This file is subject to the terms and conditions of the GNU General Public

# License. See the file "COPYING" in the main directory of this archive

# for more details.

#

# Copyright (C) 2012, ARM Ltd.

# Author: Will Deacon <will.deacon@arm.com>

#

# Based on the ia64 boot/Makefile.

#

include $(srctree)/arch/arm64/boot/dts/Makefile

OBJCOPYFLAGS_Image :=-O binary -R .note -R .note.gnu.build-id -R .comment -S

targets := Image Image.gz

DTB_NAMES := $(subst $\",,$(CONFIG_BUILD_ARM64_APPENDED_DTB_IMAGE_NAMES))

ifneq ($(DTB_NAMES),)

DTB_LIST := $(addsuffix .dtb,$(DTB_NAMES))

else

DTB_LIST := $(dtb-y) $(dtbo-y)

endif

DTB_OBJS := $(addprefix $(obj)/dts/,$(DTB_LIST))

$(obj)/Image: vmlinux FORCE

$(call if_changed,objcopy)

$(obj)/Image.bz2: $(obj)/Image FORCE

$(call if_changed,bzip2)

$(obj)/Image-dtb: $(obj)/Image $(DTB_OBJS) FORCE

$(call if_changed,cat)

$(obj)/Image.gz: $(obj)/Image FORCE

$(call if_changed,gzip)

$(obj)/Image.lz4: $(obj)/Image FORCE

$(call if_changed,lz4)

$(obj)/Image.lzma: $(obj)/Image FORCE

$(call if_changed,lzma)

$(obj)/Image.lzo: $(obj)/Image FORCE

$(call if_changed,lzo)

$(obj)/Image.gz-dtb: $(obj)/Image.gz $(DTB_OBJS) FORCE

$(call if_changed,cat)

install:

$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \

$(obj)/Image System.map "$(INSTALL_PATH)"

zinstall:

$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \

$(obj)/Image.gz System.map "$(INSTALL_PATH)"
[Android Software/Hacking General [Developers Only]] newbit:
So i double checked my build, and it also has just the image.gz file.

do you have a link to your repo with a build readme?
[Android Software/Hacking General [Developers Only]] adeii:
Is there any easier way for upgrading msm8937 kernel 3.18.140 to 4.4 or 4.9. ???

Simple compiling LA.UM.8.6.2.r2-02100-89xx.0 with GCC7 or GCC10 with working 3.18.140 defconfig can not be done without a bunch of errors. And merging with 3.18.140 will do for few months.