From nobody Sun Feb 8 13:38:44 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 99D012D94B4; Mon, 20 Oct 2025 17:54:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760982850; cv=none; b=mXUDMoBSMsf0xBTsu6AQAZVCoQwCZGBrm2/gIGUCwYm/FreDX7gt6MCkR8obOdhcbtTIcdJSRzOFzo6SlnoPu4PNKAlYXNHt+hGGFj9BYWvsMgtzH1ZMaknTPzBk6xlm/zu+tIYYJVywG8TRHe/AXBCkzkuxrsmYcBHnasZhOeI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760982850; c=relaxed/simple; bh=W9Q/9dwn0h86HXDHG358xCGj+ZGwS3vc5Ixmi2iD/rk=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=gRigte3XqfEZh/gGoYAbzW3piL6uymkutOCrDoqMx7iGXKiTwxAn9mMiYbJv3EORnIvZYhCKShWHCtMm99nEpY9sKRYdorWOYh9KVbUsYt+rgqcFX+MKXgl3GG3B6iWLX3uMrb7dWBWlQwAdqxhQnXaQ7ss3Ncbivog9WGMNIes= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=o9GSvqsr; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="o9GSvqsr" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6E212C4CEFE; Mon, 20 Oct 2025 17:54:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760982850; bh=W9Q/9dwn0h86HXDHG358xCGj+ZGwS3vc5Ixmi2iD/rk=; h=From:To:Cc:Subject:Date:From; b=o9GSvqsrrkBYtGFIQS7hjCb4B3q8prvkuUHnqv0Ei1X8WgjTgcxI5PrUIby/HhzyH 7VyXj1z8YJbjJe5LW0bejXCibBAZoZQgR7kBWOmBXjkCpLi4k0INLU3rbyg+8C9lNJ Ig8WPyQH9k0OHcyGuOzAOAbyTRUuHidqJpddzTr90ET02+6Gwpefa6WkOykTo76Ta7 tFuCAjqOy0cM5Tvsy9wXMqGTWYtqQybIf3rFqGiihFhV1JgLXsY9z1AVrmkL6l2y38 OZTB4oOm/JQsySlpugWgDZDJ/I+h+lYrcyn5tN9L2dfiEPml5nIapok7mLsaN6qfsR ofa568azqcp3A== From: Josh Poimboeuf To: x86@kernel.org Cc: linux-kernel@vger.kernel.org, Petr Mladek , Miroslav Benes , Joe Lawrence , live-patching@vger.kernel.org, Song Liu , laokz , Jiri Kosina , Marcos Paulo de Souza , Weinan Liu , Fazla Mehrab , Chen Zhongjin , Puranjay Mohan , Dylan Hatch , Peter Zijlstra , Alexander Stein , Marek Szyprowski , Mark Brown , Cosmin Tanislav Subject: [PATCH] module: Fix device table module aliases Date: Mon, 20 Oct 2025 10:53:40 -0700 Message-ID: X-Mailer: git-send-email 2.51.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Commit 6717e8f91db7 ("kbuild: Remove 'kmod_' prefix from __KBUILD_MODNAME") inadvertently broke module alias generation for modules which rely on MODULE_DEVICE_TABLE(). It removed the "kmod_" prefix from __KBUILD_MODNAME, which caused MODULE_DEVICE_TABLE() to generate a symbol name which no longer matched the format expected by handle_moddevtable() in scripts/mod/file2alias.c. As a result, modpost failed to find the device tables, leading to missing module aliases. Fix this by explicitly adding the "kmod_" string within the MODULE_DEVICE_TABLE() macro itself, restoring the symbol name to the format expected by file2alias.c. Fixes: 6717e8f91db7 ("kbuild: Remove 'kmod_' prefix from __KBUILD_MODNAME") Reported-by: Alexander Stein Reported-by: Marek Szyprowski Reported-by: Mark Brown Reported-by: Cosmin Tanislav Signed-off-by: Josh Poimboeuf Reported-by: Venkat Rao Bagalkote Tested-by: Chen-Yu Tsai Tested-by: Cosmin Tanislav Tested-by: Marek Szyprowski Tested-by: Mark Brown Tested-by: Venkat Rao Bagalkote --- include/linux/module.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/linux/module.h b/include/linux/module.h index e135cc79aceea..d80c3ea574726 100644 --- a/include/linux/module.h +++ b/include/linux/module.h @@ -251,10 +251,11 @@ struct module_kobject *lookup_or_create_module_kobjec= t(const char *name); */ #define __mod_device_table(type, name) \ __PASTE(__mod_device_table__, \ + __PASTE(kmod_, \ __PASTE(__KBUILD_MODNAME, \ __PASTE(__, \ __PASTE(type, \ - __PASTE(__, name))))) + __PASTE(__, name)))))) =20 /* Creates an alias so file2alias.c can find device table. */ #define MODULE_DEVICE_TABLE(type, name) \ --=20 2.51.0