feat: add kernel module for AWS Neuron INF instances
This commit is contained in:
parent
dab0271029
commit
b2b9b3f927
@ -10,7 +10,6 @@ license="Apache-2.0"
|
|||||||
makedepends="go bash"
|
makedepends="go bash"
|
||||||
options="!check chmod-clean"
|
options="!check chmod-clean"
|
||||||
source="$pkgname-$pkgver.tar.gz::https://github.com/kubernetes-sigs/$pkgname/archive/refs/tags/v$pkgver.tar.gz"
|
source="$pkgname-$pkgver.tar.gz::https://github.com/kubernetes-sigs/$pkgname/archive/refs/tags/v$pkgver.tar.gz"
|
||||||
arch="x86_64 aarch64 armv7 x86"
|
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
make bin
|
make bin
|
||||||
|
40
v3.15/aws-neuron-driver/APKBUILD
Normal file
40
v3.15/aws-neuron-driver/APKBUILD
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
# Contributor: Stefan Reimer <stefan@zero-downtime.net>
|
||||||
|
# Maintainer: Stefan Reimer <stefan@zero-downtime.net>
|
||||||
|
pkgname=aws-neuron-driver
|
||||||
|
pkgver=0.1.0
|
||||||
|
pkgrel=0
|
||||||
|
pkgdesc="Linux Kernel module for AWS Neuron INF instances"
|
||||||
|
url="https://github.com/aws/aws-neuron-driver"
|
||||||
|
arch="x86_64"
|
||||||
|
license="GPL-2.0"
|
||||||
|
makedepends="bash linux-headers linux-virt-dev"
|
||||||
|
options="!check"
|
||||||
|
|
||||||
|
# No Tags nor releases ;-(
|
||||||
|
# cad466aa978944bc8ef51f2228c2ca80618d3103"
|
||||||
|
source="$pkgname-$pkgver.zip::https://github.com/aws/$pkgname/archive/refs/heads/master.zip
|
||||||
|
missing-io.patch
|
||||||
|
"
|
||||||
|
|
||||||
|
builddir="$srcdir/aws-neuron-driver-master"
|
||||||
|
|
||||||
|
build() {
|
||||||
|
# Hack running the build inside a container other uname -r returns host kernel
|
||||||
|
KERNEL_VERSION=$(basename $(ls -d /lib/modules/*-virt))
|
||||||
|
|
||||||
|
make KERNEL_SRC_DIR=/lib/modules/$KERNEL_VERSION/build
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
KERNEL_VERSION=$(basename $(ls -d /lib/modules/*-virt))
|
||||||
|
|
||||||
|
mkdir -p "$pkgdir"/lib/modules/$KERNEL_VERSION "$pkgdir"/lib/udev/rules.d
|
||||||
|
cp neuron.ko "$pkgdir"/lib/modules/$KERNEL_VERSION
|
||||||
|
|
||||||
|
echo 'KERNEL=="neuron*", MODE="0666"' > "$pkgdir"/lib/udev/rules.d/90-neuron-udev.rules
|
||||||
|
}
|
||||||
|
|
||||||
|
sha512sums="
|
||||||
|
521c65cbdf4f5c05d20a2dbee2c3c597b075189cb729fa3213691e10486706f10776316da7c16dc8d869489c979878d4040f73eddfed1c29f9fec83ef19faf27 aws-neuron-driver-0.1.0.zip
|
||||||
|
6658805f1cc830020544b3fe42c4e0a28791f84d0c6d9594961c11761b9228b9591841f740ac78bf9411655c3138af3286da5fa9eb9cb3f03a1cd6bf0d58a8f3 missing-io.patch
|
||||||
|
"
|
12
v3.15/aws-neuron-driver/missing-io.patch
Normal file
12
v3.15/aws-neuron-driver/missing-io.patch
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
diff --git a/neuron_reg_access.h b/neuron_reg_access.h
|
||||||
|
index a547c4b..c0f4db8 100644
|
||||||
|
--- a/neuron_reg_access.h
|
||||||
|
+++ b/neuron_reg_access.h
|
||||||
|
@@ -9,6 +9,7 @@
|
||||||
|
|
||||||
|
#include <linux/kernel.h>
|
||||||
|
#include <linux/slab.h>
|
||||||
|
+#include <linux/io.h>
|
||||||
|
#include <asm/bug.h>
|
||||||
|
#include <asm/barrier.h>
|
||||||
|
#include <asm/delay.h>
|
@ -10,7 +10,6 @@ license="Apache-2.0"
|
|||||||
makedepends="go bash"
|
makedepends="go bash"
|
||||||
options="!check chmod-clean"
|
options="!check chmod-clean"
|
||||||
source="$pkgname-$pkgver.tar.gz::https://github.com/kubernetes/cloud-provider-aws/archive/refs/tags/v$pkgver.tar.gz"
|
source="$pkgname-$pkgver.tar.gz::https://github.com/kubernetes/cloud-provider-aws/archive/refs/tags/v$pkgver.tar.gz"
|
||||||
arch="x86_64 aarch64 armv7 x86"
|
|
||||||
|
|
||||||
builddir="$srcdir/cloud-provider-aws-$pkgver"
|
builddir="$srcdir/cloud-provider-aws-$pkgver"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user