From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from fout-a3-smtp.messagingengine.com (fout-a3-smtp.messagingengine.com [103.168.172.146]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CF7B92FF140 for ; Mon, 22 Dec 2025 21:33:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=103.168.172.146 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1766439198; cv=none; b=JMccFp/vH4smoxlx1Ys2ZwwgmURpunxBgVKa35LPklNVsIDoAFco3+/bCJh/WS9tZ3d1wuIqt+ibvMkpHYdoePnSFClgkkiXB0ZrWvi4vdZq/rj3LSPbe7GRfpFA46dBpvdkh3GVVzBfVl7P7uXC2RsgknZNTzwcDe1hzRvGCc8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1766439198; c=relaxed/simple; bh=53N+t8rp2ASN0FzbKT7m4+lkDQgiFlNPJBLIxsg3ee8=; h=MIME-Version:Date:From:To:Cc:Message-Id:In-Reply-To:References: Subject:Content-Type; b=iBYzkgzAiMgddEzGidSPcyQLRYjF6c4HpERVUhFq+KoM/nlMN/yfDD0neqfv3jKitVIWhjp8NcHxd6nE6jXeQspHO0aQwxSLlsodu/71FW8ay/yaZhRmQZZWPgPc0g7sqI6LWN8Hh2bxkK4kw9nb6U+LiYk3cNvwO7Z7FuYNYpA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arndb.de; spf=pass smtp.mailfrom=arndb.de; dkim=pass (2048-bit key) header.d=arndb.de header.i=@arndb.de header.b=JrvtLO6W; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=ABHtA8nt; arc=none smtp.client-ip=103.168.172.146 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arndb.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arndb.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=arndb.de header.i=@arndb.de header.b="JrvtLO6W"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="ABHtA8nt" Received: from phl-compute-04.internal (phl-compute-04.internal [10.202.2.44]) by mailfout.phl.internal (Postfix) with ESMTP id 1FBCFEC0091; Mon, 22 Dec 2025 16:33:15 -0500 (EST) Received: from phl-imap-02 ([10.202.2.81]) by phl-compute-04.internal (MEProxy); Mon, 22 Dec 2025 16:33:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arndb.de; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm1; t=1766439195; x=1766525595; bh=hlZZc2/NQjeFTAUATJePoi9eA1h+qvYR8jAewG6kWX8=; b= JrvtLO6WskTrq/D0sE6sGwmT/moOJf6iq14x11Wd0a0tS0fFUFBHqkia6180F6f8 jhz8PS8f1fF++f4vYubAnJZKdBs0ef7zNfNKXF2fsfX2ZjcDMNsw1mTchFACYtx8 p6HJbPOcAklbm2tq5Xj6WB0zsw69r96AQxox9QZX2khLs2Vqf4ZCjCC+MIIbxoMZ v3Ujyu7JeQhQjC4S/dygX0Uf10PJ75es8VTUXUj+jZZ4shyEZXedNxU5rGMvKYem jgXml+BmrVeH3TZLVVJhG6pqhkj7lhshbz/QYW+pzXjoUWA2cXd4/5KmwmnyS+91 ylH/8BieBC3hkwDRGT4XEA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t=1766439195; x= 1766525595; bh=hlZZc2/NQjeFTAUATJePoi9eA1h+qvYR8jAewG6kWX8=; b=A BHtA8ntJBqqM3sAM5REb9PtwwpnIxlo4PRqNdE4Y6jQsgl84cj30NSbCHXLzJP0i 7R6kvs+lBT6Sz9PsJq/BCaAX48nd6gbr/qwRfOO1hY/M/ybaSQiL7vOhJ72McOn5 Tiqqo93MDxWwfuDc2Ml5bQQP1OR4U4jnmaBEO5Hn2IW5FrV+PgaOZ5fjKP9ij+zJ HnwvR+aMztvEkl3xWkLikqJrsFwM16ksdK+DxO87hsC4fykdqC9jlyNFPblUSaJa H5vAhWFrBzckVo+b4P3NFO9OJJ+/bRl/JrsOgd3Gfm7BxXIurDAAGUPlgb5DuwYI OB2D4E3ZVZB8VGYEpr5SA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgdehkedtfecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpuffrtefokffrpgfnqfghnecuuegr ihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjug hrpefoggffhffvvefkjghfufgtgfesthejredtredttdenucfhrhhomhepfdetrhhnugcu uegvrhhgmhgrnhhnfdcuoegrrhhnugesrghrnhgusgdruggvqeenucggtffrrghtthgvrh hnpefhtdfhvddtfeehudekteeggffghfejgeegteefgffgvedugeduveelvdekhfdvieen ucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrrhhnug esrghrnhgusgdruggvpdhnsggprhgtphhtthhopeduuddpmhhouggvpehsmhhtphhouhht pdhrtghpthhtoheprghlvgigrghnuggvrhdruggvuhgthhgvrhesrghmugdrtghomhdprh gtphhtthhopegthhhrihhsthhirghnrdhkohgvnhhighesrghmugdrtghomhdprhgtphht thhopehsihhmohhnrgesfhhffihllhdrtghhpdhrtghpthhtoheprghirhhlihgvugesgh hmrghilhdrtghomhdprhgtphhtthhopehrrggsvghnuggrrdgtnhesghhmrghilhdrtgho mhdprhgtphhtthhopehgrghohhgrnhesihhstggrshdrrggtrdgtnhdprhgtphhtthhope grmhguqdhgfhigsehlihhsthhsrdhfrhgvvgguvghskhhtohhprdhorhhgpdhrtghpthht ohepughrihdquggvvhgvlheslhhishhtshdrfhhrvggvuggvshhkthhophdrohhrghdprh gtphhtthhopehlihhnuhigqdhrihhstghvsehlihhsthhsrdhinhhfrhgruggvrggurdho rhhg X-ME-Proxy: Feedback-ID: i56a14606:Fastmail Received: by mailuser.phl.internal (Postfix, from userid 501) id 049C4700065; Mon, 22 Dec 2025 16:33:14 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-ThreadId: A6eaVLahbyw3 Date: Mon, 22 Dec 2025 22:32:43 +0100 From: "Arnd Bergmann" To: "Han Gao" , "Alex Deucher" , =?UTF-8?Q?Christian_K=C3=B6nig?= , "Dave Airlie" , "Simona Vetter" , amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Cc: "Han Gao" , linux-riscv@lists.infradead.org, sophgo@lists.linux.dev Message-Id: In-Reply-To: <20251220163338.3852399-1-gaohan@iscas.ac.cn> References: <20251220163338.3852399-1-gaohan@iscas.ac.cn> Subject: Re: [PATCH] drm/radeon: bypass no_64bit_msi with new msi64 parameter Content-Type: text/plain Content-Transfer-Encoding: 7bit On Sat, Dec 20, 2025, at 17:33, Han Gao wrote: > diff --git a/drivers/gpu/drm/radeon/radeon_drv.c > b/drivers/gpu/drm/radeon/radeon_drv.c > index 87fd6255c114..53af28494c03 100644 > --- a/drivers/gpu/drm/radeon/radeon_drv.c > +++ b/drivers/gpu/drm/radeon/radeon_drv.c > @@ -249,6 +249,10 @@ int radeon_cik_support = -1; > MODULE_PARM_DESC(cik_support, "CIK support (1 = enabled, 0 = disabled, > -1 = default)"); > module_param_named(cik_support, radeon_cik_support, int, 0444); > > +int radeon_msi64; > +MODULE_PARM_DESC(msi64, "MSI64 support (1 = enabled, 0 = disabled)"); > +module_param_named(msi64, radeon_msi64, int, 0444); > + As with the hda-intel patch, this should not be a module argument, but we should have the kernel figure out what to do itself. > diff --git a/drivers/gpu/drm/radeon/radeon_irq_kms.c > b/drivers/gpu/drm/radeon/radeon_irq_kms.c > index 9961251b44ba..62eb5a6968ff 100644 > --- a/drivers/gpu/drm/radeon/radeon_irq_kms.c > +++ b/drivers/gpu/drm/radeon/radeon_irq_kms.c > @@ -250,7 +250,7 @@ static bool radeon_msi_ok(struct radeon_device > *rdev) > * of address for "64-bit" MSIs which breaks on some platforms, > notably > * IBM POWER servers, so we limit them > */ > - if (rdev->family < CHIP_BONAIRE) { > + if (rdev->family < CHIP_BONAIRE && !radeon_msi64) { > dev_info(rdev->dev, "radeon: MSI limited to 32-bit\n"); > rdev->pdev->no_64bit_msi = 1; According to the comment above it, the device can apparently do 40-bit addressing but not use the entire 64-bit space. I assume the SG2042 chip has the irqchip somewhere above the 32-bit line but below the 40-bit line, so it ends up working. I wonder if the msi_verify_entries() function should check against dev->coherent_dma_mask instead of checking the upper 32 bits for being nonzero, that probably gives you the desired behavior. Arnd