Skip to content

Commit

Permalink
Merge branch 'bits/210-gpu' into asahi-wip
Browse files Browse the repository at this point in the history
  • Loading branch information
jannau committed Oct 3, 2024
2 parents 90e2c7f + 632de37 commit 556e332
Showing 121 changed files with 30,107 additions and 379 deletions.
3 changes: 2 additions & 1 deletion drivers/block/rnull.rs
Original file line number Diff line number Diff line change
@@ -20,6 +20,7 @@ use kernel::{
error::Result,
new_mutex, pr_info,
prelude::*,
str::CStr,
sync::{Arc, Mutex},
types::ARef,
};
@@ -36,7 +37,7 @@ struct NullBlkModule {
}

impl kernel::Module for NullBlkModule {
fn init(_module: &'static ThisModule) -> Result<Self> {
fn init(_name: &'static CStr, _module: &'static ThisModule) -> Result<Self> {
pr_info!("Rust null_blk loaded\n");
let tagset = Arc::pin_init(TagSet::new(1, 256, 1), flags::GFP_KERNEL)?;

2 changes: 2 additions & 0 deletions drivers/gpu/drm/Kconfig
Original file line number Diff line number Diff line change
@@ -340,6 +340,8 @@ config DRM_VGEM

source "drivers/gpu/drm/vkms/Kconfig"

source "drivers/gpu/drm/asahi/Kconfig"

source "drivers/gpu/drm/exynos/Kconfig"

source "drivers/gpu/drm/rockchip/Kconfig"
1 change: 1 addition & 0 deletions drivers/gpu/drm/Makefile
Original file line number Diff line number Diff line change
@@ -219,3 +219,4 @@ obj-y += solomon/
obj-$(CONFIG_DRM_SPRD) += sprd/
obj-$(CONFIG_DRM_LOONGSON) += loongson/
obj-$(CONFIG_DRM_POWERVR) += imagination/
obj-$(CONFIG_DRM_ASAHI) += asahi/
45 changes: 45 additions & 0 deletions drivers/gpu/drm/asahi/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# SPDX-License-Identifier: GPL-2.0

config RUST_DRM_SCHED
bool
select DRM_SCHED

config RUST_DRM_GEM_SHMEM_HELPER
bool
select DRM_GEM_SHMEM_HELPER

config RUST_DRM_GPUVM
bool
select DRM_GPUVM

config RUST_APPLE_RTKIT
bool
select APPLE_RTKIT
select APPLE_MBOX

config DRM_ASAHI
tristate "Asahi (DRM support for Apple AGX GPUs)"
depends on RUST
depends on DRM
depends on (ARM64 && ARCH_APPLE) || (COMPILE_TEST && !GENERIC_ATOMIC64)
depends on MMU
select RUST_DRM_SCHED
select IOMMU_SUPPORT
select IOMMU_IO_PGTABLE_LPAE
select RUST_DRM_GEM_SHMEM_HELPER
select RUST_DRM_GPUVM
select RUST_APPLE_RTKIT
help
DRM driver for Apple AGX GPUs (G13x, found in the M1 SoC family)

config DRM_ASAHI_DEBUG_ALLOCATOR
bool "Use debug allocator"
depends on DRM_ASAHI
help
Use an alternate, simpler allocator which significantly reduces
performance, but can help find firmware- or GPU-side memory safety
issues. However, it can also trigger firmware bugs more easily,
so expect GPU crashes.

Say N unless you are debugging firmware structures or porting to a
new firmware version.
3 changes: 3 additions & 0 deletions drivers/gpu/drm/asahi/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# SPDX-License-Identifier: GPL-2.0

obj-$(CONFIG_DRM_ASAHI) += asahi.o
Loading

0 comments on commit 556e332

Please sign in to comment.