huawei k3v2oem1 kernel compile

compile huawei k3v2oem1 kernel

get source code :

android_kernel_huawei_k3v2oem1

pre-compile

which device can use it ?
README_Version.txt

Kernel release package version instruction

USE zImage NOTE:

1¡¢This package make out zImage only, you have to get ramdisk and add kernel cmdline to generate a total boot.img before replace your phone's bootimage.
2¡¢If your phone already enable secboot feature, please decrypt or unlock the secboot feature first.
3¡¢Please make sure your phone software version is same with this release package, if not, please download the match version first.

This kernel package is released for the phone software version U9508 V100R001CHNC00B550

how to compile it?
README_Kernel.txt

################################################################################

1. How to Build
    - get Toolchain
        From android git server , codesourcery and etc ..
         - arm-linux-androideabi-4.6

    - edit Makefile
        edit "CROSS_COMPILE" to right toolchain path(You downloaded).
          EX)   CROSS_COMPILE= $(android platform directory you download)/android/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.6/bin/arm-linux-androideabi-
          Ex)   CROSS_COMPILE=/usr/local/toolchain/arm-linux-androideabi-4.6/bin/arm-linux-androideabi-          // check the location of toolchain
          or
          Ex)Exexport CROSS_COMPILE=arm-linux-androideabi-
          Ex)Exexport PATH=$PATH:<toolchain_parent_dir>/arm-linux-androideabi-4.6/bin

        $ make ARCH=arm hisi_k3v2oem1_defconfig
        $ make ARCH=arm zImage

2. Output files
    - Kernel : arch/arm/boot/zImage
    - module : drivers/*/*.ko

3. How to Clean
        $ make ARCH=arm distclean
################################################################################

compile

error fix:

<1> perl parse excel fail.
arch/arm/mach-k3v2/ipps_para_gen.pl line 3 error

make sure your have perl installed with perl -v
install perl excel parse library
sudo cpan
    install OLE::Storage_Lite
    install Spreadsheet::ParseExcel

<2> lzop not found.
OBJCOPY arch/arm/boot/Image
Kernel: arch/arm/boot/Image is ready
AS arch/arm/boot/compressed/head.o
LZO arch/arm/boot/compressed/piggy.lzo
/bin/sh: 1: lzop: not found
make[2]: [arch/arm/boot/compressed/piggy.lzo] Error 1
make1:
[arch/arm/boot/compressed/vmlinux] Error 2
make: * [zImage] Error 2

sudo apt-get install lzop

Test

repack boot.img , then flash it with fastboot, please make sure you had unlocked your phone.
huawei u9508 with this to unlock

fastboot oem unlock UUUUUUUUUUUUUUUU

repack boot.img

mkboot boot.img out
... replace out/zImage
mkboot out new_boot.img

flash

adb reboot bootloader
fastboot flash boot new_boot.img
or 
fastboot flash:raw boot zImage ramdisk.gz
fastboot reboot