mirror of
https://github.com/QuixiAI/nvdriver.git
synced 2026-12-06 06:28:39 +00:00
* kernel-open: add opt-in Tegra194 GV11B platform_driver and bus-agnostic rmapi_node registration * rmapi_node: support platform dev in nv_rs_rmapi_mmap * platform(gv11b): skip reset_control when Tegra genpd pm_domain owns GPU reset * kernel-open(gv11b): fault-map and revoke platform BAR IO VMAs on GPU removal * kernel-open(gv11b): extract rmapi_plat_io.h and test platform BAR VMA revocation in host fixture * kernel-open(gv11b): propagate and report actual platform DMA mask in proc gpu info * kernel-open(gv11b): document plat_io pgoff/BDF assumptions and harden !live release * kernel-open(gv11b): clean up orphaned plat_io mappings on file release * kernel-open(gv11b): resolve duplicate boot0/dma_bits fields after rebase * kernel-open(gv11b): gate file_ref_get() on Linux >= 6.13 or NV_RS_HAVE_FILE_REF
29 lines
1.8 KiB
Bash
Executable File
29 lines
1.8 KiB
Bash
Executable File
#!/bin/sh
|
|
set -eu
|
|
TASK_ROOT=$(CDPATH= cd -- "$(dirname -- "$0")/.." && pwd)
|
|
cd "$TASK_ROOT"
|
|
TASK_OUT="$TASK_ROOT/target/pci-bridge"
|
|
mkdir -p "$TASK_OUT"
|
|
if [ -z "${RUSTC:-}" ]; then
|
|
if RUSTC=$(command -v rustc 2>/dev/null); then
|
|
:
|
|
elif [ -n "${CARGO_HOME:-}" ] && [ -x "$CARGO_HOME/bin/rustc" ]; then
|
|
RUSTC="$CARGO_HOME/bin/rustc"
|
|
else
|
|
RUSTC="$HOME/.cargo/bin/rustc"
|
|
fi
|
|
fi
|
|
cc -std=c11 -Wall -Wextra -Werror -I src/nvidia/kernel src/nvidia/kernel/pci-fixtures.c -o "$TASK_OUT/c-fixture"
|
|
"$TASK_OUT/c-fixture"
|
|
cc -std=c11 -Wall -Wextra -Werror -DNV_RS_HAVE_VIDEO_IS_PRIMARY_DEVICE -DCONFIG_VIDEO=1 -I src/nvidia/kernel tests/pci-mock/rebar_fixture.c -o "$TASK_OUT/rebar-fixture-video"
|
|
"$TASK_OUT/rebar-fixture-video"
|
|
cc -std=c11 -Wall -Wextra -Werror -DNV_RS_HAVE_VIDEO_IS_PRIMARY_DEVICE -I src/nvidia/kernel tests/pci-mock/rebar_fixture.c -o "$TASK_OUT/rebar-fixture-vga"
|
|
"$TASK_OUT/rebar-fixture-vga"
|
|
cc -std=c11 -Wall -Wextra -Werror -I kernel-open/nvidia tests/platform-mock/platform_fixture.c -o "$TASK_OUT/platform-fixture"
|
|
"$TASK_OUT/platform-fixture"
|
|
cc -fPIC -std=c11 -Wall -Wextra -Werror -I src/nvidia/kernel -c tests/pci-mock/ffi.c -o "$TASK_OUT/c-adapter.o"
|
|
"$RUSTC" --edition=2024 --crate-name nv_rs_abi --crate-type=rlib src/common/abi/src/lib.rs -o "$TASK_OUT/libnv_rs_abi.rlib"
|
|
"$RUSTC" --edition=2024 --crate-name nv_rs_core --crate-type=rlib src/nvidia/src/lib.rs --extern nv_rs_abi="$TASK_OUT/libnv_rs_abi.rlib" -o "$TASK_OUT/libnv_rs_core.rlib"
|
|
"$RUSTC" --edition=2024 --test --crate-name nv_pci_bridge tests/pci-mock/ffi.rs --extern nv_rs_core="$TASK_OUT/libnv_rs_core.rlib" --extern nv_rs_abi="$TASK_OUT/libnv_rs_abi.rlib" -L dependency="$TASK_OUT" -C link-arg="$TASK_OUT/c-adapter.o" -o "$TASK_OUT/rust-fixture"
|
|
"$TASK_OUT/rust-fixture"
|