@@ -123,7 +123,7 if [ "$BUILD_KERNEL" = true ] ; then | |||||
123 | fi |
|
123 | fi | |
124 |
|
124 | |||
125 | # enable basic KVM support; see https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=210546&start=25#p1300453 |
|
125 | # enable basic KVM support; see https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=210546&start=25#p1300453 | |
126 | if [ "$KERNEL_VIRT" = true ] && { [ "$RPI_MODEL" = 2 ] || [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 3P ] ; } ; then |
|
126 | if [ "$KERNEL_VIRT" = true ] && { [ "$RPI_MODEL" = 2 ] || [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 3P ] || [ "$RPI_MODEL" = 4 ]; } ; then | |
127 | set_kernel_config CONFIG_HAVE_KVM_IRQCHIP y |
|
127 | set_kernel_config CONFIG_HAVE_KVM_IRQCHIP y | |
128 | set_kernel_config CONFIG_HAVE_KVM_ARCH_TLB_FLUSH_ALL y |
|
128 | set_kernel_config CONFIG_HAVE_KVM_ARCH_TLB_FLUSH_ALL y | |
129 | set_kernel_config CONFIG_HAVE_KVM_CPU_RELAX_INTERCEPT y |
|
129 | set_kernel_config CONFIG_HAVE_KVM_CPU_RELAX_INTERCEPT y | |
@@ -537,20 +537,28 if [ "$BUILD_KERNEL" = true ] ; then | |||||
537 | fi |
|
537 | fi | |
538 |
|
538 | |||
539 | else # BUILD_KERNEL=false |
|
539 | else # BUILD_KERNEL=false | |
540 | if [ "$SET_ARCH" = 64 ] && { [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 3P ] ; } ; then |
|
540 | if [ "$SET_ARCH" = 64 ] | |
|
541 | if [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 3P ] ; then | |||
|
542 | # Use Sakakis modified kernel if ZSWAP is active | |||
|
543 | if [ "$KERNEL_ZSWAP" = true ] || [ "$KERNEL_VIRT" = true ] || [ "$KERNEL_NF" = true ] || [ "$KERNEL_BPF" = true ] ; then | |||
|
544 | RPI3_64_KERNEL_URL="${RPI3_64_BIS_KERNEL_URL}" | |||
|
545 | fi | |||
541 |
|
546 | |||
542 | # Use Sakakis modified kernel if ZSWAP is active |
|
547 | # Create temporary directory for dl | |
543 | if [ "$KERNEL_ZSWAP" = true ] || [ "$KERNEL_VIRT" = true ] || [ "$KERNEL_NF" = true ] || [ "$KERNEL_BPF" = true ] ; then |
|
548 | temp_dir=$(as_nobody mktemp -d) | |
544 | RPI3_64_KERNEL_URL="${RPI3_64_BIS_KERNEL_URL}" |
|
|||
545 | fi |
|
|||
546 |
|
549 | |||
547 | # Create temporary directory for dl |
|
550 | # Fetch kernel dl | |
548 | temp_dir=$(as_nobody mktemp -d) |
|
551 | as_nobody wget -O "${temp_dir}"/kernel.tar.xz -c "$RPI3_64_KERNEL_URL" | |
549 |
|
552 | fi | ||
550 | # Fetch kernel dl |
|
553 | if [ "$SET_ARCH" = 64 ] && [ "$RPI_MODEL" = 4 ] ; then | |
551 | as_nobody wget -O "${temp_dir}"/kernel.tar.xz -c "$RPI3_64_KERNEL_URL" |
|
554 | # Create temporary directory for dl | |
|
555 | temp_dir=$(as_nobody mktemp -d) | |||
552 |
|
556 | |||
553 | #extract download |
|
557 | # Fetch kernel dl | |
|
558 | as_nobody wget -O "${temp_dir}"/kernel.tar.xz -c "$RPI4_64_KERNEL_URL" | |||
|
559 | fi | |||
|
560 | ||||
|
561 | #extract download | |||
554 | tar -xJf "${temp_dir}"/kernel.tar.xz -C "${temp_dir}" |
|
562 | tar -xJf "${temp_dir}"/kernel.tar.xz -C "${temp_dir}" | |
555 |
|
563 | |||
556 | #move extracted kernel to /boot/firmware |
|
564 | #move extracted kernel to /boot/firmware | |
@@ -566,15 +574,15 else # BUILD_KERNEL=false | |||||
566 | chown -R root:root "${R}/lib/modules" |
|
574 | chown -R root:root "${R}/lib/modules" | |
567 | fi |
|
575 | fi | |
568 |
|
576 | |||
569 | # Install Kernel from hypriot comptabile with all Raspberry PI |
|
577 | # Install Kernel from hypriot comptabile with all Raspberry PI (dunno if its compatible with RPI4 - better compile your own kernel) | |
570 | if [ "$SET_ARCH" = 32 ] ; then |
|
578 | if [ "$SET_ARCH" = 32 ] && [ "$RPI_MODEL" != 4 ] ; then | |
571 | # Create temporary directory for dl |
|
579 | # Create temporary directory for dl | |
572 | temp_dir=$(as_nobody mktemp -d) |
|
580 | temp_dir=$(as_nobody mktemp -d) | |
573 |
|
581 | |||
574 | # Fetch kernel |
|
582 | # Fetch kernel | |
575 | as_nobody wget -O "${temp_dir}"/kernel.deb -c "$RPI_32_KERNEL_URL" |
|
583 | as_nobody wget -O "${temp_dir}"/kernel.deb -c "$RPI_32_KERNEL_URL" | |
576 |
|
584 | |||
577 |
# Copy downloaded |
|
585 | # Copy downloaded kernel package | |
578 | mv "${temp_dir}"/kernel.deb "${R}"/tmp/kernel.deb |
|
586 | mv "${temp_dir}"/kernel.deb "${R}"/tmp/kernel.deb | |
579 |
|
587 | |||
580 | # Set permissions |
|
588 | # Set permissions |
@@ -112,7 +112,7 if [ "$ENABLE_TURBO" = true ] ; then | |||||
112 | echo "boot_delay=1" >> "${BOOT_DIR}/config.txt" |
|
112 | echo "boot_delay=1" >> "${BOOT_DIR}/config.txt" | |
113 | fi |
|
113 | fi | |
114 |
|
114 | |||
115 | if [ "$RPI_MODEL" = 0 ] || [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 3P ] ; then |
|
115 | if [ "$RPI_MODEL" = 0 ] || [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 3P ] || [ "$RPI_MODEL" = 4 ]; then | |
116 |
|
116 | |||
117 | # Bluetooth enabled |
|
117 | # Bluetooth enabled | |
118 | if [ "$ENABLE_BLUETOOTH" = true ] ; then |
|
118 | if [ "$ENABLE_BLUETOOTH" = true ] ; then |
@@ -106,7 +106,7 if [ "$ENABLE_WIRELESS" = true ] ; then | |||||
106 | temp_dir=$(as_nobody mktemp -d) |
|
106 | temp_dir=$(as_nobody mktemp -d) | |
107 |
|
107 | |||
108 | # Fetch firmware binary blob for RPI3B+ |
|
108 | # Fetch firmware binary blob for RPI3B+ | |
109 | if [ "$RPI_MODEL" = 3P ] ; then |
|
109 | if [ "$RPI_MODEL" = 3P ] || [ "$RPI_MODEL" = 4 ] ; then | |
110 | # Fetch firmware binary blob for RPi3P |
|
110 | # Fetch firmware binary blob for RPi3P | |
111 | as_nobody wget -q -O "${temp_dir}/brcmfmac43455-sdio.bin" "${WLAN_FIRMWARE_URL}/brcmfmac43455-sdio.bin" |
|
111 | as_nobody wget -q -O "${temp_dir}/brcmfmac43455-sdio.bin" "${WLAN_FIRMWARE_URL}/brcmfmac43455-sdio.bin" | |
112 | as_nobody wget -q -O "${temp_dir}/brcmfmac43455-sdio.txt" "${WLAN_FIRMWARE_URL}/brcmfmac43455-sdio.txt" |
|
112 | as_nobody wget -q -O "${temp_dir}/brcmfmac43455-sdio.txt" "${WLAN_FIRMWARE_URL}/brcmfmac43455-sdio.txt" |
@@ -74,7 +74,7 if [ "$ENABLE_NEXMON" = true ] && [ "$ENABLE_WIRELESS" = true ]; then | |||||
74 | cp -f "${NEXMON_ROOT}"/patches/bcm43430a1/7_45_41_46/nexmon/brcmfmac43430-sdio.bin "${WLAN_FIRMWARE_DIR}"/brcmfmac43430-sdio.bin |
|
74 | cp -f "${NEXMON_ROOT}"/patches/bcm43430a1/7_45_41_46/nexmon/brcmfmac43430-sdio.bin "${WLAN_FIRMWARE_DIR}"/brcmfmac43430-sdio.bin | |
75 | fi |
|
75 | fi | |
76 |
|
76 | |||
77 | if [ "$RPI_MODEL" = 3P ] ; then |
|
77 | if [ "$RPI_MODEL" = 3P ] || [ "$RPI_MODEL" = 4 ] ; then | |
78 | cd "${NEXMON_ROOT}"/patches/bcm43455c0/7_45_154/nexmon || exit |
|
78 | cd "${NEXMON_ROOT}"/patches/bcm43455c0/7_45_154/nexmon || exit | |
79 | sed -i -e 's/all:.*/all: $(RAM_FILE)/g' ${NEXMON_ROOT}/patches/bcm43455c0/7_45_154/nexmon/Makefile |
|
79 | sed -i -e 's/all:.*/all: $(RAM_FILE)/g' ${NEXMON_ROOT}/patches/bcm43455c0/7_45_154/nexmon/Makefile | |
80 | make clean |
|
80 | make clean |
@@ -67,8 +67,11 RPI_32_KERNELHEADER_URL=${RPI_32_KERNELHEADER_URL:=https://github.com/hypriot/rp | |||||
67 | RPI3_64_BIS_KERNEL_URL=${RPI3_64_BIS_KERNEL_URL:=https://github.com/sakaki-/bcmrpi3-kernel-bis/releases/download/4.14.80.20181113/bcmrpi3-kernel-bis-4.14.80.20181113.tar.xz} |
|
67 | RPI3_64_BIS_KERNEL_URL=${RPI3_64_BIS_KERNEL_URL:=https://github.com/sakaki-/bcmrpi3-kernel-bis/releases/download/4.14.80.20181113/bcmrpi3-kernel-bis-4.14.80.20181113.tar.xz} | |
68 | # Default precompiled 64bit kernel |
|
68 | # Default precompiled 64bit kernel | |
69 | RPI3_64_DEF_KERNEL_URL=${RPI3_64_DEF_KERNEL_URL:=https://github.com/sakaki-/bcmrpi3-kernel/releases/download/4.14.80.20181113/bcmrpi3-kernel-4.14.80.20181113.tar.xz} |
|
69 | RPI3_64_DEF_KERNEL_URL=${RPI3_64_DEF_KERNEL_URL:=https://github.com/sakaki-/bcmrpi3-kernel/releases/download/4.14.80.20181113/bcmrpi3-kernel-4.14.80.20181113.tar.xz} | |
|
70 | # Sakaki BIS Kernel RPI4 | |||
|
71 | RPI4_64_DEF_KERNEL_URL=https://github.com/sakaki-/bcm2711-kernel-bis/releases/download/4.19.59.20190724/bcm2711-kernel-bis-4.19.59.20190724.tar.xz | |||
70 | # Generic |
|
72 | # Generic | |
71 | RPI3_64_KERNEL_URL=${RPI3_64_KERNEL_URL:=$RPI3_64_DEF_KERNEL_URL} |
|
73 | RPI3_64_KERNEL_URL=${RPI3_64_KERNEL_URL:=$RPI3_64_DEF_KERNEL_URL} | |
|
74 | RPI4_64_KERNEL_URL=${RPI3_64_KERNEL_URL:=$RPI4_64_DEF_KERNEL_URL} | |||
72 | # Kali kernel src - used if ENABLE_NEXMON=true (they patch the wlan kernel modul) |
|
75 | # Kali kernel src - used if ENABLE_NEXMON=true (they patch the wlan kernel modul) | |
73 | KALI_KERNEL_URL=${KALI_KERNEL_URL:=https://github.com/Re4son/re4son-raspberrypi-linux.git} |
|
76 | KALI_KERNEL_URL=${KALI_KERNEL_URL:=https://github.com/Re4son/re4son-raspberrypi-linux.git} | |
74 |
|
77 |
General Comments 0
Vous devez vous connecter pour laisser un commentaire.
Se connecter maintenant