From patchwork Thu Aug 29 09:16:09 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Sam Bingner X-Patchwork-Id: 1978451 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=185.125.189.65; helo=lists.ubuntu.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=patchwork.ozlabs.org) Received: from lists.ubuntu.com (lists.ubuntu.com [185.125.189.65]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Wvj045XbCz1yZ9 for ; Thu, 29 Aug 2024 23:33:07 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=lists.ubuntu.com) by lists.ubuntu.com with esmtp (Exim 4.86_2) (envelope-from ) id 1sjfGg-0006zE-EJ; Thu, 29 Aug 2024 13:32:54 +0000 Received: from mailer.bingner.com ([64.62.210.4] helo=mail.bingner.com) by lists.ubuntu.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1sjbGN-0004PO-CC for kernel-team@lists.ubuntu.com; Thu, 29 Aug 2024 09:16:19 +0000 Content-Language: en-US Received: from EX01.ds.sbdhi.com (2001:470:3c:1::21) by EX02.ds.sbdhi.com (2001:470:3c:1::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Wed, 28 Aug 2024 23:16:16 -1000 Received: from EX01.ds.sbdhi.com ([fe80::44d3:ef59:fdca:d83]) by EX01.ds.sbdhi.com ([fe80::44d3:ef59:fdca:d83%3]) with mapi id 15.01.2507.039; Wed, 28 Aug 2024 23:16:09 -1000 From: Sam Bingner To: "'kernel-team@lists.ubuntu.com'" Subject: Kernel Patch to fix amdgpu Thread-Topic: Kernel Patch to fix amdgpu Thread-Index: Adr586PD1qh8igZaSpmz+3fMmVIIsw== Date: Thu, 29 Aug 2024 09:16:09 +0000 Message-ID: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [98.155.121.4] MIME-Version: 1.0 Received-SPF: pass client-ip=64.62.210.4; envelope-from=sam@bingner.com; helo=mail.bingner.com X-Mailman-Approved-At: Thu, 29 Aug 2024 13:32:52 +0000 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" Please apply the attached patch from https://github.com/torvalds/linux/commit/0cdb3f9740844b9d95ca413e3fcff11f81223ecf to the 6.8.0 kernel. This is causing a panic when it tries to remove the module on some qualcomm servers. I have verified that this applies cleanly, and that it corrects the problem. As you can see this is a very safe patch. r/ Sam Bingner From 0cdb3f9740844b9d95ca413e3fcff11f81223ecf Mon Sep 17 00:00:00 2001 From: Friedrich Vock Date: Tue, 14 May 2024 09:06:38 +0200 Subject: [PATCH] drm/amdgpu: Check if NBIO funcs are NULL in amdgpu_device_baco_exit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The special case for VM passthrough doesn't check adev->nbio.funcs before dereferencing it. If GPUs that don't have an NBIO block are passed through, this leads to a NULL pointer dereference on startup. Signed-off-by: Friedrich Vock Fixes: 1bece222eabe ("drm/amdgpu: Clear doorbell interrupt status for Sienna Cichlid") Cc: Alex Deucher Cc: Christian König Acked-by: Christian König Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index 00fe3c2d54310f..e72e774d17e6a5 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c @@ -6167,7 +6167,7 @@ int amdgpu_device_baco_exit(struct drm_device *dev) adev->nbio.funcs->enable_doorbell_interrupt) adev->nbio.funcs->enable_doorbell_interrupt(adev, true); - if (amdgpu_passthrough(adev) && + if (amdgpu_passthrough(adev) && adev->nbio.funcs && adev->nbio.funcs->clear_doorbell_interrupt) adev->nbio.funcs->clear_doorbell_interrupt(adev);