device-samsung-manta: switch to mainline kernel (MR 4406)
Samsung Manta is now supported by linux-posmarketos-exynos5. Update device-samsung-manta to use it, and move downstream kernel and device to unmaintained. Also adds a script and networkmanager configuration to autoconfigure WiFi MAC address from /proc/cmdline. Signed-off-by: Alexandre Marquet <tb@a-marquet.fr>
This commit is contained in:
parent
08f32ffa4d
commit
db2b912a0a
1
device/testing/device-samsung-manta/100-wlan-mac.rules
Normal file
1
device/testing/device-samsung-manta/100-wlan-mac.rules
Normal file
|
@ -0,0 +1 @@
|
|||
ACTION=="add", SUBSYSTEM=="net", KERNEL=="wlan0", RUN+="/usr/lib/device-samsung-manta/wifi-macaddr.sh"
|
|
@ -1,29 +1,21 @@
|
|||
# Reference: <https://postmarketos.org/devicepkg>
|
||||
pkgname=device-samsung-manta
|
||||
pkgdesc="Google Nexus 10"
|
||||
pkgver=0.5
|
||||
pkgrel=2
|
||||
pkgver=1
|
||||
pkgrel=0
|
||||
url="https://postmarketos.org"
|
||||
license="MIT"
|
||||
arch="armv7"
|
||||
options="!check !archcheck"
|
||||
depends="postmarketos-base linux-samsung-manta mkbootimg watchdog-kick alsa-ucm-conf"
|
||||
depends="postmarketos-base linux-postmarketos-exynos5 mkbootimg"
|
||||
makedepends="devicepkg-dev"
|
||||
subpackages="$pkgname-nonfree-firmware:nonfree_firmware"
|
||||
source="
|
||||
deviceinfo
|
||||
pointercal
|
||||
modules-load.conf
|
||||
100-manta-charging.rules
|
||||
autodetect-charger.sh
|
||||
sink-usb-power.sh
|
||||
led-charging-manta.sh
|
||||
led-discharging-manta.sh
|
||||
100-wlan-mac.rules
|
||||
wifi-macaddr.sh
|
||||
networkmanager.conf
|
||||
ucm/Manta-I2S.conf
|
||||
ucm/HiFi.conf
|
||||
ucm/Manta-SPDIF.conf
|
||||
ucm/SPDIF.conf
|
||||
"
|
||||
|
||||
build() {
|
||||
|
@ -36,48 +28,27 @@ package() {
|
|||
install -D -m644 "$srcdir"/networkmanager.conf \
|
||||
"$pkgdir"/etc/NetworkManager/conf.d/10-manta.conf
|
||||
|
||||
install -Dm744 "$srcdir"/autodetect-charger.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/autodetect-charger.sh
|
||||
install -Dm744 "$srcdir"/sink-usb-power.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/sink-usb-power.sh
|
||||
install -Dm744 "$srcdir"/led-charging-manta.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/led-charging-manta.sh
|
||||
install -Dm744 "$srcdir"/led-discharging-manta.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/led-discharging-manta.sh
|
||||
install -Dm744 "$srcdir"/wifi-macaddr.sh \
|
||||
-t "$pkgdir"/usr/lib/device-samsung-manta/
|
||||
|
||||
install -Dm644 "$srcdir"/100-manta-charging.rules \
|
||||
"$pkgdir"/usr/lib/udev/rules.d/100-manta-charging.rules
|
||||
|
||||
install -D -m644 "$srcdir"/pointercal \
|
||||
"$pkgdir"/etc/pointercal
|
||||
|
||||
install -Dm644 -t "$pkgdir"/usr/share/alsa/ucm2/conf.d/Manta-I2S \
|
||||
"$srcdir"/Manta-I2S.conf \
|
||||
"$srcdir"/HiFi.conf
|
||||
|
||||
install -Dm644 -t "$pkgdir"/usr/share/alsa/ucm2/conf.d/Manta-SPDIF \
|
||||
"$srcdir"/Manta-SPDIF.conf \
|
||||
"$srcdir"/SPDIF.conf
|
||||
install -Dm644 "$srcdir"/100-wlan-mac.rules \
|
||||
-t "$pkgdir"/usr/lib/udev/rules.d/
|
||||
}
|
||||
|
||||
nonfree_firmware() {
|
||||
pkgdesc="Firmware for Samsung Manta (Nexus 10)"
|
||||
depends="firmware-samsung-manta"
|
||||
depends="
|
||||
firmware-samsung-manta
|
||||
linux-firmware-brcm
|
||||
linux-firmware-s5p-mfc
|
||||
"
|
||||
mkdir "$subpkgdir"
|
||||
}
|
||||
|
||||
sha512sums="
|
||||
58a40f3ea8942e868d384f185e3bfadb3b1b1d1d3b785425ccc2fd851189595b6c645edda9aad1e158abcd2ead0e169470e43392d2263742e36d7f4fac5cb0e9 deviceinfo
|
||||
4a4a1e478131175d628669c45c780db6eace39653d7c331e13042d315a1d04a1feebbf3ab1caea959f84d3203dcf0402da0a51dfd90728bc0a2a52a069069c52 pointercal
|
||||
aa65eddbf733af7a8c143f810aa21319ea267bfe473080faba634419146ff14f57e9e07cecdf64aefe0d060bf03564637d606be7b436ccb7de512697097460d5 modules-load.conf
|
||||
e479dd64f2c27aeeafcc57ea1ae650b382e07a7ea2addf994406b2f64e9b3eff7df451637ceeef85e484be39a8d5a19e35d35c2643b9538b29abf55c67bcecc3 100-manta-charging.rules
|
||||
edb46f0de37835c7c5a55f47f57acd40012817e0a734153d49033d7aa82404192abdd8f100c93df80702a09698e0d13eb3e26f4bcc86dc427322a2b68498bbb4 autodetect-charger.sh
|
||||
71a4bf6d25b55acb94fd624625c94cc9c74fe57c4328cddb488f57274443f8c9354c0a5a6f52df40f0ca54ed0713db73f1f90b5fcfd0f8e25ed9cc755b30dea3 sink-usb-power.sh
|
||||
797f5dce8e27bb5e1fb77a6fa9a917847067f533f14b7b6339703f0aa2969cd8bee686fcdd83e91d21c2fefb6d44365f6b5b0c7726950febfee8a99f9faf8be7 led-charging-manta.sh
|
||||
a6c9ac55b8d343bcef8765498b450d3e17993b7ad72b274c2fe3e9d3b1a94f917f3790a3595394c0a4de5f1debffbcfbfccd1e4eb637604d6a3da54741cf6091 led-discharging-manta.sh
|
||||
a6d59c86fc7c47ba25fe125fe57cfbc0b82cb41e3729c3b0387e611386c2e449fa14360b999bc7593527f30a01f3f85bacf2d81762f167a547b37271456343bd networkmanager.conf
|
||||
20bd1a5ced8f816c931353abb939936f3c71c5ae1e7a6736dc7c596e721fd59dff70866dc056ef8732fa3cd68f50f08875698696f75ca15e8d618d7778342da4 Manta-I2S.conf
|
||||
684f1dacb031dcbfd17d55c43db08a1da89d1e7c8197e4c9b8200096e74895469cffabeef3233a4ff380eb92e5fd5618819770ade4f86d1aad9e12e9da7ef122 HiFi.conf
|
||||
d9e1847f74e46091e2c0bf6cf088cd85ad866fde3e0b8aff8fb02b2dc8869c44977303e40f2be86751ad083838c5a659dd70e434746b92bafd2d0a618f135bcb Manta-SPDIF.conf
|
||||
5e1bae638cbd88a38b10b45f675bc4e5fdb84155923a945168207e49db2053a31ae9e7b5233936b832ed60b3a367e31dee7b2d85b52b2922dcfa5df1a813aaa7 SPDIF.conf
|
||||
ec542216d7ee2608781c41b6afc82a7ae272c2e032dbdbb88343b5e6140e0e298a2243ddba7b48ebccffbe0ebd79f8dfb816767a0502067acf278a73cc7647ff deviceinfo
|
||||
fe65b8e792e5d69dfff707e7b9a415ce7c4786fbcc1ad0aba638450c8470e81b0eb3cf170bc95a38e1234e1a3a5d6a013cc06d771a6c61015fbd12c07038e918 modules-load.conf
|
||||
37a18d36e1e08ddcc605de73214dc02a9e7737f6a66b2e4be301fca816bbf3c2ba6b5ead1f12c745fd0fa019e2a8e959e4fc20386ad94ca7277d4c7d7f9fb703 100-wlan-mac.rules
|
||||
ef18bd3e5c4c8c69dce3293c9e70fa0b30820ba12cb8217346b63392db95513169c31e9bf730aac5cecea15e2cda4166b093bbf0e456055a5432e57400ecb9b1 wifi-macaddr.sh
|
||||
5c3a692f22a29fca792c114c6d94ff1bf0d6921f068f207a2894a8f99c73dcc319e7c803ed7adfe64eb3e60088f37e2a2730118b2ed57aa01b35415664085567 networkmanager.conf
|
||||
"
|
||||
|
|
|
@ -17,15 +17,18 @@ deviceinfo_screen_height="1600"
|
|||
deviceinfo_dev_touchscreen="/dev/input/event2"
|
||||
|
||||
# Bootloader related
|
||||
deviceinfo_flash_method="heimdall-bootimg"
|
||||
deviceinfo_flash_method="fastboot"
|
||||
deviceinfo_flash_sparse="true"
|
||||
deviceinfo_generate_bootimg="true"
|
||||
deviceinfo_bootimg_qcdt="false"
|
||||
deviceinfo_bootimg_dtb_second="false"
|
||||
deviceinfo_flash_offset_base="0x10000000"
|
||||
deviceinfo_flash_offset_kernel="0x00008000"
|
||||
deviceinfo_flash_offset_ramdisk="0x01000000"
|
||||
deviceinfo_flash_offset_second="0x00f00000"
|
||||
deviceinfo_flash_offset_tags="0x00000100"
|
||||
deviceinfo_flash_pagesize="2048"
|
||||
deviceinfo_flash_heimdall_partition_kernel="boot"
|
||||
deviceinfo_flash_heimdall_partition_system="system"
|
||||
|
||||
# Kernel options
|
||||
deviceinfo_dtb="exynos5250-samsung-nexus10-manta"
|
||||
deviceinfo_append_dtb="true"
|
||||
|
|
|
@ -3,3 +3,7 @@
|
|||
|
||||
# touch
|
||||
atmel_mxt_ts
|
||||
|
||||
# DS2784 Fuelgauge
|
||||
ds2482
|
||||
ds2784_battery
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
[keyfile]
|
||||
unmanaged-devices=interface-name:p2p*
|
||||
[connection]
|
||||
wifi.cloned-mac-address=preserve
|
||||
|
|
5
device/testing/device-samsung-manta/wifi-macaddr.sh
Normal file
5
device/testing/device-samsung-manta/wifi-macaddr.sh
Normal file
|
@ -0,0 +1,5 @@
|
|||
#!/bin/sh
|
||||
|
||||
macaddr=$(cat /proc/cmdline | sed -n "s/^.*androidboot\.wifimacaddr=\(\([0-9A-Fa-f]\{2\}:\)\{5\}[0-9A-Fa-f]\{2\}\).*$/\1/p")
|
||||
|
||||
/sbin/ip link set wlan0 address $macaddr
|
|
@ -0,0 +1 @@
|
|||
ACTION=="add", SUBSYSTEM=="net", KERNEL=="wlan0", RUN+="/usr/lib/device-samsung-manta/wifi-macaddr.sh"
|
92
device/unmaintained/device-samsung-manta-downstream/APKBUILD
Normal file
92
device/unmaintained/device-samsung-manta-downstream/APKBUILD
Normal file
|
@ -0,0 +1,92 @@
|
|||
# Unmaintained: Downstream port, only for testing. Use mainline port (samsung-manta)!
|
||||
# Reference: <https://postmarketos.org/devicepkg>
|
||||
pkgname=device-samsung-manta-downstream
|
||||
pkgdesc="Google Nexus 10"
|
||||
pkgver=0.5
|
||||
pkgrel=0
|
||||
url="https://postmarketos.org"
|
||||
license="MIT"
|
||||
arch="armv7"
|
||||
options="!check !archcheck"
|
||||
depends="postmarketos-base linux-samsung-manta-downstream mkbootimg watchdog-kick alsa-ucm-conf"
|
||||
makedepends="devicepkg-dev"
|
||||
subpackages="$pkgname-nonfree-firmware:nonfree_firmware"
|
||||
source="
|
||||
deviceinfo
|
||||
pointercal
|
||||
modules-load.conf
|
||||
100-manta-charging.rules
|
||||
110-wlan-mac.rules
|
||||
autodetect-charger.sh
|
||||
sink-usb-power.sh
|
||||
led-charging-manta.sh
|
||||
led-discharging-manta.sh
|
||||
wifi-macaddr.sh
|
||||
networkmanager.conf
|
||||
ucm/Manta-I2S.conf
|
||||
ucm/HiFi.conf
|
||||
ucm/Manta-SPDIF.conf
|
||||
ucm/SPDIF.conf
|
||||
"
|
||||
|
||||
build() {
|
||||
devicepkg_build $startdir $pkgname
|
||||
}
|
||||
|
||||
package() {
|
||||
devicepkg_package $startdir $pkgname
|
||||
|
||||
install -D -m644 "$srcdir"/networkmanager.conf \
|
||||
"$pkgdir"/etc/NetworkManager/conf.d/10-manta.conf
|
||||
|
||||
install -Dm744 "$srcdir"/autodetect-charger.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/autodetect-charger.sh
|
||||
install -Dm744 "$srcdir"/sink-usb-power.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/sink-usb-power.sh
|
||||
install -Dm744 "$srcdir"/led-charging-manta.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/led-charging-manta.sh
|
||||
install -Dm744 "$srcdir"/led-discharging-manta.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/led-discharging-manta.sh
|
||||
install -Dm744 "$srcdir"/wifi-macaddr.sh \
|
||||
"$pkgdir"/usr/lib/device-samsung-manta/wifi-macaddr.sh
|
||||
|
||||
install -Dm644 "$srcdir"/100-manta-charging.rules \
|
||||
"$pkgdir"/usr/lib/udev/rules.d/100-manta-charging.rules
|
||||
install -Dm644 "$srcdir"/110-wlan-mac.rules \
|
||||
"$pkgdir"/usr/lib/udev/rules.d/110-wlan-mac.rules
|
||||
|
||||
install -D -m644 "$srcdir"/pointercal \
|
||||
"$pkgdir"/etc/pointercal
|
||||
|
||||
install -Dm644 -t "$pkgdir"/usr/share/alsa/ucm2/conf.d/Manta-I2S \
|
||||
"$srcdir"/Manta-I2S.conf \
|
||||
"$srcdir"/HiFi.conf
|
||||
|
||||
install -Dm644 -t "$pkgdir"/usr/share/alsa/ucm2/conf.d/Manta-SPDIF \
|
||||
"$srcdir"/Manta-SPDIF.conf \
|
||||
"$srcdir"/SPDIF.conf
|
||||
}
|
||||
|
||||
nonfree_firmware() {
|
||||
pkgdesc="Firmware for Samsung Manta (Nexus 10)"
|
||||
depends="firmware-samsung-manta"
|
||||
mkdir "$subpkgdir"
|
||||
}
|
||||
|
||||
sha512sums="
|
||||
f7e430647f49ac7b21c6c90e8ebc03d39bd18a60a5e09eeb77a19c20a2c2bc71f08dec568fbc7bc1abead5c459a0c3fa6243e64c87a0a0dae812badf1b1d143b deviceinfo
|
||||
4a4a1e478131175d628669c45c780db6eace39653d7c331e13042d315a1d04a1feebbf3ab1caea959f84d3203dcf0402da0a51dfd90728bc0a2a52a069069c52 pointercal
|
||||
aa65eddbf733af7a8c143f810aa21319ea267bfe473080faba634419146ff14f57e9e07cecdf64aefe0d060bf03564637d606be7b436ccb7de512697097460d5 modules-load.conf
|
||||
e479dd64f2c27aeeafcc57ea1ae650b382e07a7ea2addf994406b2f64e9b3eff7df451637ceeef85e484be39a8d5a19e35d35c2643b9538b29abf55c67bcecc3 100-manta-charging.rules
|
||||
37a18d36e1e08ddcc605de73214dc02a9e7737f6a66b2e4be301fca816bbf3c2ba6b5ead1f12c745fd0fa019e2a8e959e4fc20386ad94ca7277d4c7d7f9fb703 110-wlan-mac.rules
|
||||
edb46f0de37835c7c5a55f47f57acd40012817e0a734153d49033d7aa82404192abdd8f100c93df80702a09698e0d13eb3e26f4bcc86dc427322a2b68498bbb4 autodetect-charger.sh
|
||||
71a4bf6d25b55acb94fd624625c94cc9c74fe57c4328cddb488f57274443f8c9354c0a5a6f52df40f0ca54ed0713db73f1f90b5fcfd0f8e25ed9cc755b30dea3 sink-usb-power.sh
|
||||
797f5dce8e27bb5e1fb77a6fa9a917847067f533f14b7b6339703f0aa2969cd8bee686fcdd83e91d21c2fefb6d44365f6b5b0c7726950febfee8a99f9faf8be7 led-charging-manta.sh
|
||||
a6c9ac55b8d343bcef8765498b450d3e17993b7ad72b274c2fe3e9d3b1a94f917f3790a3595394c0a4de5f1debffbcfbfccd1e4eb637604d6a3da54741cf6091 led-discharging-manta.sh
|
||||
ef18bd3e5c4c8c69dce3293c9e70fa0b30820ba12cb8217346b63392db95513169c31e9bf730aac5cecea15e2cda4166b093bbf0e456055a5432e57400ecb9b1 wifi-macaddr.sh
|
||||
e4b07d07000e7647bd7b1a7cc9ff93d90873356aeb47fc727a7e2724a998c44550e640b5eaa4f34739c585366fd46fef709a9f6d1d66904ecabf6b99809e16a4 networkmanager.conf
|
||||
20bd1a5ced8f816c931353abb939936f3c71c5ae1e7a6736dc7c596e721fd59dff70866dc056ef8732fa3cd68f50f08875698696f75ca15e8d618d7778342da4 Manta-I2S.conf
|
||||
684f1dacb031dcbfd17d55c43db08a1da89d1e7c8197e4c9b8200096e74895469cffabeef3233a4ff380eb92e5fd5618819770ade4f86d1aad9e12e9da7ef122 HiFi.conf
|
||||
d9e1847f74e46091e2c0bf6cf088cd85ad866fde3e0b8aff8fb02b2dc8869c44977303e40f2be86751ad083838c5a659dd70e434746b92bafd2d0a618f135bcb Manta-SPDIF.conf
|
||||
5e1bae638cbd88a38b10b45f675bc4e5fdb84155923a945168207e49db2053a31ae9e7b5233936b832ed60b3a367e31dee7b2d85b52b2922dcfa5df1a813aaa7 SPDIF.conf
|
||||
"
|
|
@ -0,0 +1,32 @@
|
|||
# Reference: <https://postmarketos.org/deviceinfo>
|
||||
# Please use double quotes only. You can source this file in shell scripts.
|
||||
|
||||
deviceinfo_format_version="0"
|
||||
deviceinfo_name="Google Nexus 10"
|
||||
deviceinfo_manufacturer="Samsung"
|
||||
deviceinfo_codename="samsung-manta-downstream"
|
||||
deviceinfo_year="2012"
|
||||
deviceinfo_arch="armv7"
|
||||
|
||||
# Device related
|
||||
deviceinfo_chassis="tablet"
|
||||
deviceinfo_keyboard="false"
|
||||
deviceinfo_external_storage="false"
|
||||
deviceinfo_screen_width="2560"
|
||||
deviceinfo_screen_height="1600"
|
||||
deviceinfo_dev_touchscreen="/dev/input/event2"
|
||||
|
||||
# Bootloader related
|
||||
deviceinfo_flash_method="heimdall-bootimg"
|
||||
deviceinfo_flash_sparse="true"
|
||||
deviceinfo_generate_bootimg="true"
|
||||
deviceinfo_bootimg_qcdt="false"
|
||||
deviceinfo_flash_offset_base="0x10000000"
|
||||
deviceinfo_flash_offset_kernel="0x00008000"
|
||||
deviceinfo_flash_offset_ramdisk="0x01000000"
|
||||
deviceinfo_flash_offset_second="0x00f00000"
|
||||
deviceinfo_flash_offset_tags="0x00000100"
|
||||
deviceinfo_flash_pagesize="2048"
|
||||
deviceinfo_flash_heimdall_partition_kernel="boot"
|
||||
deviceinfo_flash_heimdall_partition_system="system"
|
||||
deviceinfo_zram_swap_pct="0"
|
|
@ -0,0 +1,5 @@
|
|||
# This file contains the names of kernel modules that should be loaded
|
||||
# at boot time, one per line. Lines beginning with "#" are ignored.
|
||||
|
||||
# touch
|
||||
atmel_mxt_ts
|
|
@ -0,0 +1,5 @@
|
|||
[keyfile]
|
||||
unmanaged-devices=interface-name:p2p*
|
||||
|
||||
[connection]
|
||||
wifi.cloned-mac-address=preserve
|
|
@ -0,0 +1,5 @@
|
|||
#!/bin/sh
|
||||
|
||||
macaddr=$(cat /proc/cmdline | sed -n "s/^.*androidboot\.wifimacaddr=\(\([0-9A-Fa-f]\{2\}:\)\{5\}[0-9A-Fa-f]\{2\}\).*$/\1/p")
|
||||
|
||||
/sbin/ip link set wlan0 address $macaddr
|
|
@ -1,8 +1,9 @@
|
|||
# Unmaintained: Downstream port, only for testing. Use mainline port (samsung-manta)!
|
||||
# Kernel config based on: arch/arm/configs/lineage_manta_defconfig
|
||||
|
||||
pkgname=linux-samsung-manta
|
||||
pkgname=linux-samsung-manta-downstream
|
||||
pkgver=3.4.113
|
||||
pkgrel=7
|
||||
pkgrel=0
|
||||
pkgdesc="Google Nexus 10 kernel fork"
|
||||
arch="armv7"
|
||||
_carch="arm"
|
||||
|
@ -52,7 +53,7 @@ package() {
|
|||
}
|
||||
|
||||
sha512sums="
|
||||
36a60bd023016adf6c1e579293d69e03cca6d0eb1efbb62ee698af72f2d19b3cd2e60941965a56702d325dede99481a1f4e09e6644016005bc27798153d48455 linux-samsung-manta-2eb797e4d1338dcf963a762491790484a5dd0612.tar.gz
|
||||
36a60bd023016adf6c1e579293d69e03cca6d0eb1efbb62ee698af72f2d19b3cd2e60941965a56702d325dede99481a1f4e09e6644016005bc27798153d48455 linux-samsung-manta-downstream-2eb797e4d1338dcf963a762491790484a5dd0612.tar.gz
|
||||
3699b8d1b3ced3cbdfe0bab45da0a22ce6f9cbefb72c9c037207b21ed7f2ca5604a80b16cbbe2e2249ff46775a800bad1fab2502275ff5fca22ad6ae80e6e180 config-samsung-manta.armv7
|
||||
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
|
||||
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
|
Loading…
Reference in New Issue
Block a user