├── .github └── workflows │ ├── build_kernel_6-9.yml │ └── main.yml ├── Dockerfile ├── Readme.md ├── action.yml ├── compile.sh ├── compile_all.sh ├── compile_v6-3.sh └── compile_v6-6.sh /.github/workflows/build_kernel_6-9.yml: -------------------------------------------------------------------------------- 1 | name: Build a kernel for the PineNote (6.9 branch) 2 | 3 | permissions: 4 | contents: write 5 | 6 | on: 7 | # push: 8 | # branches: 9 | # - 'mw/rk35/pinenote-next-t1' 10 | workflow_dispatch: 11 | 12 | jobs: 13 | compile_kernel: 14 | runs-on: ubuntu-latest 15 | name: Compile the pinenote kernel 16 | steps: 17 | - uses: actions/checkout@v3 18 | - name: Install requirements 19 | run: | 20 | sudo apt -y install git vim debhelper 21 | sudo apt -y install build-essential linux-source bc kmod cpio flex libncurses5-dev libelf-dev libssl-dev dwarves bison 22 | sudo apt -y install gcc-aarch64-linux-gnu 23 | sudo apt -y install rsync rename 24 | 25 | - name: Clone kernel branch 26 | run: | 27 | git clone --depth 1 --branch branch_pinenote_6-9_v1 https://github.com/m-weigand/linux 28 | 29 | - name: Compile kernel branch 30 | run: | 31 | cd linux 32 | test -d pack && rm -r pack 33 | mkdir pack 34 | make clean 35 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- pinenote_defconfig 36 | make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- LOCALVERSION=-pinenote-`date +%Y%m%d%H%M` KDEB_PKGVERSION="" KBUILD_IMAGE=arch/arm64/boot/Image deb-pkg 37 | cd .. 38 | rename 's/.deb/_no_compression.deb/' linux-image* 39 | mv *.deb linux/pack/ 40 | mv linux-upstream* linux/pack/ 41 | tree -L 4 linux/pack 42 | 43 | - name: Compile kernel branch step 2 44 | run: | 45 | cd linux 46 | # # make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- LOCALVERSION=-pinenote-`date +%Y%m%d%H%M` KDEB_PKGVERSION="" bindeb-pkg 47 | # # mv ../*.deb pack/ 48 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_MOD_PATH=${PWD}/pack modules_install 49 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_PATH=${PWD}/pack dtbs_install 50 | cd .. 51 | tar cvzf linux/pack/modules.tar.gz linux/pack/lib 52 | rm -r linux/pack/lib 53 | tree -L 4 linux/pack 54 | 55 | # cp ./arch/arm64/boot/dts/rockchip/rk3566-pinenote-v1.2.dtb pack/ 56 | # cp ./arch/arm64/boot/Image pack/ 57 | # # rename 's/.deb/_with_compression.deb/' linux-image* 58 | # cd pack 59 | # tar cvzf modules.tar.gz lib 60 | # rm -r lib 61 | # cd ../.. 62 | # 63 | # # extract the results from the Docker container 64 | # cp -r linux/pack /github/home/pack_v6.9 65 | # 66 | # - name: Compile kernel branch 67 | # run: | 68 | 69 | 70 | - uses: actions/upload-artifact@v3 71 | with: 72 | name: pinenote_kernel_module_dtb 73 | path: linux/pack 74 | 75 | # do_release: 76 | # runs-on: ubuntu-latest 77 | # needs: 78 | # - compile_kernel 79 | # steps: 80 | # - name: Clone workflow repository 81 | # uses: actions/checkout@v3 82 | # - name: Download image artifacts 83 | # uses: actions/download-artifact@v3 84 | # with: 85 | # path: artifacts/ 86 | # - name: Make release 87 | # uses: softprops/action-gh-release@v0.1.15 88 | # with: 89 | # draft: true 90 | # files: | 91 | # # artifacts/pinenote_kernel_module_dtb_v6.3/*.deb 92 | # # artifacts/pinenote_kernel_module_dtb_v6.3/linux-upstream* 93 | # artifacts/pinenote_kernel_module_dtb_v6.6/*.deb 94 | # artifacts/pinenote_kernel_module_dtb_v6.6/linux-upstream* 95 | -------------------------------------------------------------------------------- /.github/workflows/main.yml: -------------------------------------------------------------------------------- 1 | name: Build a kernel for the PineNote 2 | 3 | permissions: 4 | contents: write 5 | 6 | on: 7 | # push: 8 | # branches: 9 | # - 'mw/rk35/pinenote-next-t1' 10 | workflow_dispatch: 11 | 12 | jobs: 13 | compile_kernel: 14 | runs-on: ubuntu-latest 15 | name: Compile the pinenote kernel 16 | steps: 17 | - name: Docker-based compilation 18 | id: compile-kernel-in-docker 19 | uses: m-weigand/linux@description 20 | # - uses: actions/upload-artifact@v3 21 | # with: 22 | # name: pinenote_kernel_modules_dtb 23 | # path: /home/runner/work/_temp/_github_home/pack/ 24 | # - uses: actions/upload-artifact@v3 25 | # with: 26 | # name: pinenote_kernel_module_dtb_v6.2 27 | # path: /home/runner/work/_temp/_github_home/pack_v6.2/ 28 | # - uses: actions/upload-artifact@v3 29 | # with: 30 | # name: pinenote_kernel_module_dtb_v6.3 31 | # path: /home/runner/work/_temp/_github_home/pack_v6.3/ 32 | - uses: actions/upload-artifact@v3 33 | with: 34 | name: pinenote_kernel_module_dtb_v6.6 35 | path: /home/runner/work/_temp/_github_home/pack_v6.6/ 36 | 37 | do_release: 38 | runs-on: ubuntu-latest 39 | needs: 40 | - compile_kernel 41 | steps: 42 | - name: Clone workflow repository 43 | uses: actions/checkout@v3 44 | - name: Download image artifacts 45 | uses: actions/download-artifact@v3 46 | with: 47 | path: artifacts/ 48 | - name: Make release 49 | uses: softprops/action-gh-release@v0.1.15 50 | with: 51 | draft: true 52 | files: | 53 | # artifacts/pinenote_kernel_module_dtb_v6.3/*.deb 54 | # artifacts/pinenote_kernel_module_dtb_v6.3/linux-upstream* 55 | artifacts/pinenote_kernel_module_dtb_v6.6/*.deb 56 | artifacts/pinenote_kernel_module_dtb_v6.6/linux-upstream* 57 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM debian:bookworm 2 | 3 | RUN apt -y update 4 | RUN apt -y upgrade 5 | RUN apt -y install git vim debhelper 6 | RUN apt -y install build-essential linux-source bc kmod cpio flex libncurses5-dev libelf-dev libssl-dev dwarves bison 7 | RUN apt -y install gcc-aarch64-linux-gnu 8 | RUN apt -y install rsync rename 9 | 10 | RUN mkdir /root/kernel 11 | 12 | COPY compile.sh /root/kernel/ 13 | 14 | RUN mkdir /root/kernel_v6.3 15 | COPY compile_v6-3.sh /root/kernel_v6.3/ 16 | 17 | RUN mkdir /root/kernel_v6.6 18 | COPY compile_v6-6.sh /root/kernel_v6.6/ 19 | 20 | COPY compile_all.sh /root/ 21 | 22 | ENTRYPOINT /root/compile_all.sh 23 | -------------------------------------------------------------------------------- /Readme.md: -------------------------------------------------------------------------------- 1 | # Description of new branches and merge order 2 | 3 | ** If you are looking for a PineNote kernel, use the branch_pinenote_6-6-22 branch (https://github.com/m-weigand/linux/tree/branch_pinenote_6-6-22)** 4 | 5 | ## Branch structure 6 | 7 | I try to structure my branches into merged, ready-to-test kernels, and branches 8 | that contain feature-specific patches based upon an upstream or stable tree. 9 | 10 | Branches for use on the pinenote usual start with **branch_pinenote** 11 | 12 | Branches with feature patches start with **branch_rebase** 13 | 14 | ## Branches 15 | 16 | * **branch_pinenote_6-6-22** A v6.6.22 kernel with various patches for the 17 | PineNote applied: 18 | This branch was created by merging the following branches on top of v6.6.22: 19 | * branch_rebase_6.6.22_btpen 20 | * branch_rebase_6.6.22_cyttsp5 21 | * branch_rebase_6.6.22_defconfig 22 | * branch_rebase_6.6.22_ebc 23 | * branch_rebase_6.6.22_iio_accel 24 | * branch_rebase_6.6.22_lm3630a 25 | * branch_rebase_6.6.22_pn_dts_v2 26 | * branch_rebase_6.6.22_quartz64 27 | * branch_rebase_6.6.22_rga2 28 | * branch_rebase_6.6.22_rk817 29 | * branch_rebase_6.6.22_rk_suspend_driver 30 | * branch_rebase_6.6.22_tps65185 31 | 32 | ## Branch description, old and incomplete 33 | 34 | * (pinenote_6-2_v3)[https://github.com/m-weigand/linux/tree/pinenote_6-2_v3] -- 35 | Kernel 6.2 with patches applied to work on the Pinenote. See section below 36 | for a list of merged branches 37 | * **mw/rk35/pinenote-next-t1** -- Contains all changes merged into one branch 38 | that can be used on the Pinenote. 39 | * **mw/rk35/ebc-drm-v5-modifications-t1** -- Changes to the rockchip_ebc driver 40 | controlling the Pinenote epd display 41 | * **mw/rk35/pinenote-defconfig-changes** -- Changes to the Pinenote defconfig tree 42 | * **mw/rk35/pinenote_dts_changes** -- Changes to the Pinenote device tree 43 | * **mw/rk35/rk356x-rga** -- Changes to the RGA V4L2 driver for the rockchip-rga of 44 | the Pinenote. The RGA can be used to convert RGB images to Y4 grayscale for 45 | the EPD display. It also supports dithering to monochrome colors. 46 | * [mw/rk35/tps65185](https://github.com/m-weigand/linux/tree/mw/rk35/tps65185) -- some fixes/additions to the tps65185 epd pmic driver, mostly related to resume/suspend 47 | * [lm3630a](https://github.com/m-weigand/linux/tree/lm3630a) Small fixes to the lm3630a backlight led driver 48 | 49 | * **master**: this is the main branch forked from torvalds/linux 50 | 51 | ## Kernel 6.2 52 | 53 | The Kernel 6.2 branch, 54 | (pinenote_6-2_v3)[https://github.com/m-weigand/linux/tree/pinenote_6-2_v3], 55 | consists of a vanilla mainline 6.2 kernel with the following branches merged 56 | in: 57 | 58 | * branch_rebase_6.2_rk_suspend_driver (rockchip suspend driver required for proper suspend/resume) 59 | * branch_rebase_6.2_pn_dts_v2 (dts changes for the PineNote) 60 | * branch_rebase_6.2_cyttsp5 (changes to the touchscreen driver) 61 | * branch_rebase_6.2_tps65185 (driver for the ebc pmic) 62 | * branch_rebase_6.2_ebc (driver for the ebc display driver) 63 | * branch_rebase_6.2_defconfig (defconfig for the Pinenote) 64 | * branch_rebase_6.2_lm3630a (modifications of the backlight driver) 65 | -------------------------------------------------------------------------------- /action.yml: -------------------------------------------------------------------------------- 1 | # action.yml 2 | name: 'Pinenote kernel' 3 | description: 'Compile a 6.x kernel for the Pine64 PineNote' 4 | runs: 5 | using: 'docker' 6 | image: 'Dockerfile' 7 | -------------------------------------------------------------------------------- /compile.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | cd /root/kernel 3 | 4 | if [ ! -d linux ]; then 5 | git clone --depth 1 --branch mw/rk35/pinenote-next-t1 https://github.com/m-weigand/linux 6 | fi 7 | 8 | cd linux 9 | test -d pack && rm -r pack 10 | mkdir pack 11 | 12 | make clean 13 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- pinenote_defconfig 14 | # build deb package with uncompressed Image 15 | make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- LOCALVERSION=-`date +%Y%m%d%H%M` KDEB_PKGVERSION="" KBUILD_IMAGE=arch/arm64/boot/Image deb-pkg 16 | make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- all 17 | cd .. 18 | rm *dbg*.deb 19 | # mv linux-image*.deb linux-image_with_uncompressed_image.deb 20 | rename 's/.deb/_no_compression.deb/' linux-image* 21 | 22 | cd linux 23 | make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- LOCALVERSION=-`date +%Y%m%d%H%M` KDEB_PKGVERSION="" deb-pkg 24 | mv ../*.deb pack/ 25 | 26 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_MOD_PATH=${PWD}/pack modules_install 27 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_PATH=${PWD}/pack dtbs_install 28 | cp ./arch/arm64/boot/dts/rockchip/rk3566-pinenote-v1.2.dtb pack/ 29 | cp ./arch/arm64/boot/Image pack/ 30 | cd pack 31 | tar cvf modules.tar.gz lib 32 | rm -r lib 33 | cd ../.. 34 | 35 | # extract the results from the Docker container 36 | cp -r linux/pack /github/home 37 | -------------------------------------------------------------------------------- /compile_all.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env sh 2 | 3 | # /root/kernel/compile.sh 4 | 5 | # /root/kernel_v6.3/compile_v6-3.sh 6 | /root/kernel_v6.6/compile_v6-6.sh 7 | -------------------------------------------------------------------------------- /compile_v6-3.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | cd /root/kernel_v6.3 4 | 5 | if [ ! -d linux ]; then 6 | # git clone --depth 1 --branch branch_pinenote_6-3_v2 https://github.com/m-weigand/linux 7 | git clone --depth 1 --branch branch_pinenote_6-3-10_v1 https://github.com/m-weigand/linux 8 | fi 9 | 10 | cd linux 11 | 12 | test -d pack && rm -r pack 13 | mkdir pack 14 | 15 | make clean 16 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- pinenote_defconfig 17 | # build deb package with uncompressed Image 18 | # make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- all 19 | make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- LOCALVERSION=-pinenote-`date +%Y%m%d%H%M` KDEB_PKGVERSION="" KBUILD_IMAGE=arch/arm64/boot/Image deb-pkg 20 | cd .. 21 | ls 22 | rm *dbg*.deb 23 | # mv linux-image*.deb linux-image_with_uncompressed_image.deb 24 | rename 's/.deb/_no_compression.deb/' linux-image* 25 | 26 | mv *.deb linux/pack/ 27 | mv linux-upstream* linux/pack/ 28 | 29 | cd linux 30 | # make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- LOCALVERSION=-pinenote-`date +%Y%m%d%H%M` KDEB_PKGVERSION="" bindeb-pkg 31 | # mv ../*.deb pack/ 32 | 33 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_MOD_PATH=${PWD}/pack modules_install 34 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_PATH=${PWD}/pack dtbs_install 35 | cp ./arch/arm64/boot/dts/rockchip/rk3566-pinenote-v1.2.dtb pack/ 36 | cp ./arch/arm64/boot/Image pack/ 37 | # rename 's/.deb/_with_compression.deb/' linux-image* 38 | cd pack 39 | tar cvzf modules.tar.gz lib 40 | rm -r lib 41 | cd ../.. 42 | 43 | # extract the results from the Docker container 44 | cp -r linux/pack /github/home/pack_v6.3 45 | -------------------------------------------------------------------------------- /compile_v6-6.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | cd /root/kernel_v6.6 4 | 5 | if [ ! -d linux ]; then 6 | branch="branch_pinenote_6-6-30" 7 | git clone --depth 1 --branch ${branch} https://github.com/m-weigand/linux 8 | fi 9 | 10 | cd linux 11 | 12 | test -d pack && rm -r pack 13 | mkdir pack 14 | 15 | make clean 16 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- pinenote_defconfig 17 | # build deb package with uncompressed Image 18 | # make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- all 19 | make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- LOCALVERSION=-pinenote-`date +%Y%m%d%H%M` KDEB_PKGVERSION="" KBUILD_IMAGE=arch/arm64/boot/Image deb-pkg 20 | cd .. 21 | ls 22 | rm *dbg*.deb 23 | # mv linux-image*.deb linux-image_with_uncompressed_image.deb 24 | rename 's/.deb/_no_compression.deb/' linux-image* 25 | 26 | mv *.deb linux/pack/ 27 | mv linux-upstream* linux/pack/ 28 | 29 | cd linux 30 | # make -j 2 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- LOCALVERSION=-pinenote-`date +%Y%m%d%H%M` KDEB_PKGVERSION="" bindeb-pkg 31 | # mv ../*.deb pack/ 32 | 33 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_MOD_PATH=${PWD}/pack modules_install 34 | make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_PATH=${PWD}/pack dtbs_install 35 | cp ./arch/arm64/boot/dts/rockchip/rk3566-pinenote-v1.2.dtb pack/ 36 | cp ./arch/arm64/boot/Image pack/ 37 | # rename 's/.deb/_with_compression.deb/' linux-image* 38 | cd pack 39 | tar cvzf modules.tar.gz lib 40 | rm -r lib 41 | cd ../.. 42 | 43 | # extract the results from the Docker container 44 | cp -r linux/pack /github/home/pack_v6.6 45 | --------------------------------------------------------------------------------