linux-postmarketos-allwinner: 6.9.0 -> 6.9.10
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -1,29 +1,52 @@
|
|||||||
{ lib
|
{
|
||||||
, fetchurl
|
lib,
|
||||||
, linux-megous
|
fetchurl,
|
||||||
, linuxManualConfig
|
fetchFromGitea,
|
||||||
, sane-kernel-tools
|
fetchFromGitLab,
|
||||||
, writeTextFile
|
linux-megous,
|
||||||
#v nixpkgs calls `.override` on the kernel to configure additional things, but we don't care about those things
|
linuxManualConfig,
|
||||||
, features ? null
|
sane-kernel-tools,
|
||||||
, kernelPatches ? null
|
writeTextFile,
|
||||||
, randstructSeed ? ""
|
#VVV nixpkgs calls `.override` on the kernel to configure additional things, but we don't care about those things
|
||||||
, withModemPower ? false
|
features ? null,
|
||||||
|
kernelPatches ? null,
|
||||||
|
randstructSeed ? "",
|
||||||
|
withModemPower ? false,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
# keep in sync with linux-megous
|
# to update:
|
||||||
# to update: bump the `pmaportsRef` commit, null the hash in pmPatch, and `wget https://gitlab.com/postmarketOS/pmaports/-/raw/$pmaportsRef/device/main/linux-postmarketos-allwinner/config-postmarketos-allwinner.aarch64`
|
# - bump the `pmaportsRef` commit
|
||||||
|
# - null the hash in pmPatch
|
||||||
|
# - `wget https://gitlab.com/postmarketOS/pmaports/-/raw/$pmaportsRef/device/main/linux-postmarketos-allwinner/config-postmarketos-allwinner.aarch64`
|
||||||
|
# - update src/version/modDirVersion further down (take from pmaports APKBUILD)
|
||||||
let
|
let
|
||||||
pmaportsRef = "982799b9a83259b59b25a41e19ca591e63ae9062";
|
# VVV sources
|
||||||
pmPatch = { name, hash ? "" }: {
|
# - pmaports.rev: update this first.
|
||||||
inherit name;
|
# - src.rev, version: grab from pmaports device/main/linux-postmarketos-allwinner/APKBUILD
|
||||||
patch = fetchurl {
|
pmaports = fetchFromGitLab {
|
||||||
url = "https://gitlab.com/postmarketOS/pmaports/-/raw/${pmaportsRef}/device/main/linux-postmarketos-allwinner/${name}.patch";
|
owner = "postmarketOS";
|
||||||
inherit hash;
|
repo = "pmaports";
|
||||||
|
rev = "43d3b604c44881f78203353a40e2df62b5490abe";
|
||||||
|
hash = "sha256-6odymUb3Xxu851YWwLpQyDWFbBlx+Eb2pUh/cUVuSWI=";
|
||||||
};
|
};
|
||||||
|
src = fetchFromGitea {
|
||||||
|
domain = "codeberg.org";
|
||||||
|
owner = "megi";
|
||||||
|
repo = "linux";
|
||||||
|
rev = "orange-pi-6.9-20240721-2345";
|
||||||
|
hash = "sha256-WtLkMJnThYMLsZqbqTIhaTwQ0e2EE1Zq7DQX36L481o=";
|
||||||
|
};
|
||||||
|
version = "6.9.10";
|
||||||
|
modDirVersion = "6.9.10"; # or X.Y.Z-rcN
|
||||||
|
# ^^^ sources
|
||||||
|
|
||||||
|
pmPatch = name: {
|
||||||
|
inherit name;
|
||||||
|
patch = "${pmaports}/device/main/linux-postmarketos-allwinner/${name}.patch";
|
||||||
};
|
};
|
||||||
|
|
||||||
defconfigStr = (builtins.readFile ./config-postmarketos-allwinner.aarch64) + ''
|
# defconfigStr = (builtins.readFile ./config-postmarketos-allwinner.aarch64) + ''
|
||||||
|
defconfigStr = (builtins.readFile "${pmaports}/device/main/linux-postmarketos-allwinner/config-postmarketos-allwinner.aarch64") + ''
|
||||||
#
|
#
|
||||||
# Extra nixpkgs-specific options
|
# Extra nixpkgs-specific options
|
||||||
# nixos/modules/system/boot/systemd.nix wants CONFIG_DMIID
|
# nixos/modules/system/boot/systemd.nix wants CONFIG_DMIID
|
||||||
@@ -42,70 +65,35 @@ let
|
|||||||
'';
|
'';
|
||||||
|
|
||||||
in linuxManualConfig {
|
in linuxManualConfig {
|
||||||
inherit (linux-megous) extraMakeFlags modDirVersion src version;
|
inherit src version modDirVersion randstructSeed;
|
||||||
inherit randstructSeed;
|
# inherit (linux-megous) extraMakeFlags modDirVersion src version;
|
||||||
# inherit (linux-megou) kernelPatches;
|
# inherit (linux-megous) kernelPatches;
|
||||||
|
|
||||||
configfile = writeTextFile {
|
configfile = writeTextFile {
|
||||||
name = "config-postmarketos-allwinner.aarch64";
|
name = "config-postmarketos-allwinner.aarch64";
|
||||||
text = defconfigStr;
|
text = defconfigStr;
|
||||||
};
|
};
|
||||||
# nixpkgs requires to know the config as an attrset, to do various eval-time assertions.
|
# nixpkgs requires to know the config as an attrset, to do various eval-time assertions.
|
||||||
# this forces me to include the defconfig inline, instead of fetching it the way i do all the other pmOS kernel stuff.
|
# that config is sourced from the pmaports repo, hence this is import-from-derivation.
|
||||||
|
# if that causes issues, then copy the config inline to this repo.
|
||||||
config = sane-kernel-tools.parseDefconfig defconfigStr;
|
config = sane-kernel-tools.parseDefconfig defconfigStr;
|
||||||
|
|
||||||
# these likely aren't *all* required for pinephone: pmOS kernel is shared by many devices
|
# these likely aren't *all* required for pinephone: pmOS kernel is shared by many devices
|
||||||
kernelPatches = [
|
kernelPatches = [
|
||||||
(pmPatch {
|
(pmPatch "0001-dts-add-dontbeevil-pinephone-devkit")
|
||||||
name = "0001-dts-add-dontbeevil-pinephone-devkit";
|
(pmPatch "0002-dts-add-pinetab-dev-old-display-panel")
|
||||||
hash = "sha256-GpJDuS5vzGrT8ybSEl0s/+vPblr917qusOA3aRWcmoA=";
|
(pmPatch "0003-dts-pinetab-add-missing-ohci1")
|
||||||
})
|
(pmPatch "0004-dts-pinetab-make-audio-routing-consistent-with-pinep")
|
||||||
(pmPatch {
|
|
||||||
name = "0002-dts-add-pinetab-dev-old-display-panel";
|
|
||||||
hash = "sha256-e+bTJgycI0DOYVaskHXd/OuazwZxlfu0yWzVlGxipvo=";
|
|
||||||
})
|
|
||||||
(pmPatch {
|
|
||||||
name = "0003-dts-pinetab-add-missing-ohci1";
|
|
||||||
hash = "sha256-aCxglJo4oZafKxp2Mjs+AIB8vWBUNvvTuBugQVlBu1A=";
|
|
||||||
})
|
|
||||||
(pmPatch {
|
|
||||||
name = "0004-dts-pinetab-make-audio-routing-consistent-with-pinep";
|
|
||||||
hash = "sha256-0R69silFsQkkgNIcSo4iKjhFzXTGQLma6fZSwAwSj3s=";
|
|
||||||
})
|
|
||||||
] ++ lib.optionals (!withModemPower) [
|
] ++ lib.optionals (!withModemPower) [
|
||||||
(pmPatch {
|
(pmPatch "0005-dts-pinephone-drop-modem-power-node")
|
||||||
name = "0005-dts-pinephone-drop-modem-power-node";
|
|
||||||
hash = "sha256-59PdMo3hTfSh12pTIG/VzTSrsDQdK18nh+oCtnxvo50=";
|
|
||||||
})
|
|
||||||
] ++ [
|
] ++ [
|
||||||
(pmPatch {
|
(pmPatch "0006-drm-panel-simple-Add-Hannstar-TQTM070CB501")
|
||||||
name = "0006-drm-panel-simple-Add-Hannstar-TQTM070CB501";
|
(pmPatch "0007-ARM-dts-sun6i-Add-GoClever-Orion-70L-tablet")
|
||||||
hash = "sha256-KysfuhXwpSBUgdD2xd1IqbFdNz0GiGtFbP1xD5BeBPI=";
|
(pmPatch "0008-drm-panel-simple-Add-Hannstar-HSD070IDW1-A")
|
||||||
})
|
(pmPatch "0009-ARM-dts-sun6i-Add-Lark-FreeMe-70.2S-tablet")
|
||||||
(pmPatch {
|
(pmPatch "0010-eMMC-workaround")
|
||||||
name = "0007-ARM-dts-sun6i-Add-GoClever-Orion-70L-tablet";
|
(pmPatch "0011-arm64-dts-allwinner-orangepi-3-fix-ethernet")
|
||||||
hash = "sha256-iGy2oQgxa8HxaulsDWcAKCUG/ygK7gsL0gPyLUcDLAI=";
|
(pmPatch "0012-ARM-dts-allwinner-sun5i-a13-pocketbook-614-plus-Add-")
|
||||||
})
|
|
||||||
(pmPatch {
|
|
||||||
name = "0008-drm-panel-simple-Add-Hannstar-HSD070IDW1-A";
|
|
||||||
hash = "sha256-xdQh7z2Xn45Ku6c5xqsmYdFPutrjkRTi+nf7jKluu74=";
|
|
||||||
})
|
|
||||||
(pmPatch {
|
|
||||||
name = "0009-ARM-dts-sun6i-Add-Lark-FreeMe-70.2S-tablet";
|
|
||||||
hash = "sha256-c3xrtlmSQwEHt/XkjXHHvxO9ff6S34SGxtiej6zddgw=";
|
|
||||||
})
|
|
||||||
(pmPatch {
|
|
||||||
name = "0010-eMMC-workaround";
|
|
||||||
hash = "sha256-JXFCBAIBejhGdMSNef5HViGmJZ1RJsc8d++ioTVrjkI=";
|
|
||||||
})
|
|
||||||
(pmPatch {
|
|
||||||
name = "0011-arm64-dts-allwinner-orangepi-3-fix-ethernet";
|
|
||||||
hash = "sha256-vqZwlMFQhmA8AUfQDwi9lAHpPhtFaOrf+KgHgfBGWgQ=";
|
|
||||||
})
|
|
||||||
(pmPatch {
|
|
||||||
name = "0012-ARM-dts-allwinner-sun5i-a13-pocketbook-614-plus-Add-";
|
|
||||||
hash = "sha256-ZGMfbVr7s6zESC/BFwozHcJgRbF+xInzLkQaAWlfJ9w=";
|
|
||||||
})
|
|
||||||
{
|
{
|
||||||
name = "pinephone-1.2b-add-af8133j-magnetometer";
|
name = "pinephone-1.2b-add-af8133j-magnetometer";
|
||||||
patch = linux-megous.passthruPatches.af8133j;
|
patch = linux-megous.passthruPatches.af8133j;
|
||||||
|
Reference in New Issue
Block a user