Skip to content

Commit

Permalink
feat: Add ayaneo-platform driver (#123)
Browse files Browse the repository at this point in the history
  • Loading branch information
KyleGospo authored Feb 5, 2024
1 parent 83a5958 commit e723d28
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 0 deletions.
1 change: 1 addition & 0 deletions Containerfile.common
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ RUN if grep -qv "surface" <<< "${KERNEL_FLAVOR}"; then \
/tmp/build-kmod-openrgb.sh && \
/tmp/build-kmod-steamdeck.sh \
; fi && \
/tmp/build-kmod-ayaneo-platform.sh && \
/tmp/build-kmod-ayn-platform.sh && \
/tmp/build-kmod-bmi260.sh && \
/tmp/build-kmod-bmi323.sh && \
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Feel free to PR more kmod build scripts into this repo!
- ublue-os-nvidia-addons - installs extra repos enabling our nvidia support
- [nvidia container selinux policy](https://github.com/NVIDIA/dgx-selinux/tree/master/src/nvidia-container-selinux) - uses RHEL9 policy as the closest match
- [nvidia-container-tookkit repo](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html#installing-with-yum-or-dnf) - version 1.14 (and newer) provide CDI for podman use of nvidia gpus
- [ayaneo-platform](https://github.com/ShadowBlip/ayaneo-platform) - Linux drivers for AYANEO x86 handhelds (akmod from [ublue-os/akmods copr](https://copr.fedorainfracloud.org/coprs/ublue-os/akmods/))
- [ayn-platform](https://github.com/ShadowBlip/ayn-platform) - Linux drivers for AYN x86 handhelds (akmod from [ublue-os/akmods copr](https://copr.fedorainfracloud.org/coprs/ublue-os/akmods/))
- [bmi260](https://github.com/hhd-dev/bmi260) - kernel module driver for the Bosch BMI260 IMU (akmod from [ublue-os/akmods copr](https://copr.fedorainfracloud.org/coprs/ublue-os/akmods/))
- [bmi323](https://github.com/hhd-dev/bmi260) - kernel module driver for the Bosch BMI323 IMU (akmod from [ublue-os/akmods copr](https://copr.fedorainfracloud.org/coprs/ublue-os/akmods/))
Expand Down
17 changes: 17 additions & 0 deletions build-kmod-ayaneo-platform.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/sh

set -oeux pipefail

cp /tmp/ublue-os-akmods-addons/rpmbuild/SOURCES/_copr_ublue-os-akmods.repo /etc/yum.repos.d/

ARCH="$(rpm -E '%_arch')"
KERNEL="$(rpm -q "${KERNEL_NAME}" --queryformat '%{VERSION}-%{RELEASE}.%{ARCH}')"
RELEASE="$(rpm -E '%fedora')"

rpm-ostree install \
akmod-ayaneo-platform-*.fc${RELEASE}.${ARCH}
akmods --force --kernels "${KERNEL}" --kmod ayaneo-platform
modinfo /usr/lib/modules/${KERNEL}/extra/ayaneo-platform/ayaneo-platform.ko.xz > /dev/null \
|| (find /var/cache/akmods/ayaneo-platform/ -name \*.log -print -exec cat {} \; && exit 1)

rm -f /etc/yum.repos.d/_copr_ublue-os-akmods.repo

0 comments on commit e723d28

Please sign in to comment.