Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Unverified Commit d4998688 authored by derfelot's avatar derfelot
Browse files

README: Add Sony README_Xperia

Taken from Sony 47.2.A.10.107 stock kernel
parent 8cc1278c
Loading
Loading
Loading
Loading

README_Xperia

0 → 100644
+65 −0
Original line number Diff line number Diff line
Configuration files can be found in arch/arm64/configs.

  defconfig using in common:
    msmcortex-perf_defconfig

  diffconfigs for each product:
    Xperia XZ Premium G8141       => maple_diffconfig
    Xperia XZ Premium Dual G8142  => maple_dsds_diffconfig
    Xperia XZ1 G8341/G8343        => poplar_diffconfig
    Xperia XZ1 G8342              => poplar_dsds_diffconfig
    Xperia XZ1 Compact G8441      => lilac_diffconfig


How to build your kernel:

  Prerequisites:

    * ramdisk.img - root fs

    * mkbootimg - boot.img generator

    * The ARM cross-compiler
      You can use prebuild executable binary which is included in
      standard Android repository. Please visit to external site.
      In case of this platform, we recommend to use gcc 4.9 or later
      such as aarch64-linux-android-4.9 to avoid known issues.


  Step 1: Build Your Kernel
    $ cd kernel/msm-4.4

    $ export ARCH=arm64

    $ export PATH=<path-to-cross-compiler-executables>:$PATH
      NOTE: Please set the location of the ARM cross-compiler.

    $ export CROSS_COMPILE=<toolchain-prefix>
      NOTE: Please set the prefix of the ARM cross-compiler.
            ex) aarch64-linux-android-

    $ export KBUILD_DIFFCONFIG=maple_diffconfig
      NOTE: Please set a configuration file you want to build.

    $ make msmcortex-perf_defconfig O=./out

    $ make O=./out

    You can see arch/arm64/boot/Image-dtb if you succeed in building.


  Step 2: Assembling the boot.img
    (In the Linux Kernel directory)
    $ mkbootimg \
        --kernel out/arch/arm64/boot/Image.gz-dtb \
        --ramdisk ramdisk.img \
        --cmdline "androidboot.hardware=qcom user_debug=31 msm_rtb.filter=0x237 ehci-hcd.park=3 lpm_levels.sleep_disabled=1 sched_enable_hmp=1 sched_enable_power_aware=1 service_locator.enable=1 swiotlb=2048 androidboot.configfs=true androidboot.usbcontroller=a800000.dwc3 zram.backend=z3fold buildvariant=userdebug" \
        --os_version 9 \
        --os_patch_level 2019-06-01 \
        --base 0x00000000 \
        --kernel_offset 0x00008000 \
        --ramdisk_offset 0x01000000 \
        --tags_offset 0x00000100 \
        --pagesize 4096 \
        -o boot.img