{"id":2197479,"url":"http://patchwork.ozlabs.org/api/1.0/patches/2197479/?format=json","project":{"id":9,"url":"http://patchwork.ozlabs.org/api/1.0/projects/9/?format=json","name":"Linux RTC development","link_name":"rtc-linux","list_id":"linux-rtc.vger.kernel.org","list_email":"linux-rtc@vger.kernel.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<f1e7f5d0-88cd-4d52-bc23-062f9f506844@kernel.org>","date":"2026-02-17T22:30:58","name":"[RFC,08/10] driver core: make struct class groups members constant arrays","commit_ref":null,"pull_url":null,"state":"handled-elsewhere","archived":false,"hash":"2e32437dd945b6f1ef4076b6a4140510884f1d0c","submitter":{"id":88130,"url":"http://patchwork.ozlabs.org/api/1.0/people/88130/?format=json","name":"Heiner Kallweit","email":"hkall@kernel.org"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/rtc-linux/patch/f1e7f5d0-88cd-4d52-bc23-062f9f506844@kernel.org/mbox/","series":[{"id":492492,"url":"http://patchwork.ozlabs.org/api/1.0/series/492492/?format=json","date":"2026-02-17T22:24:26","name":"driver core: constify groups arrays in several structs","version":1,"mbox":"http://patchwork.ozlabs.org/series/492492/mbox/"}],"check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2197479/checks/","tags":{},"headers":{"Return-Path":"\n <linux-rtc+bounces-5976-incoming=patchwork.ozlabs.org@vger.kernel.org>","X-Original-To":["incoming@patchwork.ozlabs.org","linux-rtc@vger.kernel.org"],"Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256\n header.s=k20201202 header.b=fj/SQQTO;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c0a:e001:db::12fc:5321; helo=sea.lore.kernel.org;\n envelope-from=linux-rtc+bounces-5976-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)","smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org\n header.b=\"fj/SQQTO\"","smtp.subspace.kernel.org;\n arc=none smtp.client-ip=10.30.226.201"],"Received":["from sea.lore.kernel.org (sea.lore.kernel.org\n [IPv6:2600:3c0a:e001:db::12fc:5321])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fFvW45VVLz1xvq\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 18 Feb 2026 09:31:12 +1100 (AEDT)","from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby sea.lore.kernel.org (Postfix) with ESMTP id 2DBF23016C85\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 17 Feb 2026 22:31:03 +0000 (UTC)","from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id A8CA22D0C99;\n\tTue, 17 Feb 2026 22:31:02 +0000 (UTC)","from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org\n [10.30.226.201])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id 843E213AA2F;\n\tTue, 17 Feb 2026 22:31:02 +0000 (UTC)","by smtp.kernel.org (Postfix) with ESMTPSA id BF351C4CEF7;\n\tTue, 17 Feb 2026 22:30:59 +0000 (UTC)"],"ARC-Seal":"i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1771367462; cv=none;\n b=LEIsHI3YQeWfmJLiMafOYORWfGCryoBvMbTkfn1G77qQMCDqTBSKNHF2JBA/WUk9M5Y2m/JM8Lr4QvXSPMcCZ3n37VFt6JsXcvYgH4UOlj4SmGzL4aZqGh7N0vhczfyv6Hlz9v9i9IEkWMyYz2lHC7Fqm4x60yNHEtQay5byrnc=","ARC-Message-Signature":"i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1771367462; c=relaxed/simple;\n\tbh=SaaFcH6Oc3jCFSVMmx10cF8ncRdwRf8Ta+7Tz1QJAk4=;\n\th=Message-ID:Date:MIME-Version:Subject:From:To:Cc:References:\n\t In-Reply-To:Content-Type;\n b=oGUD3e9iuP1MBcOCZOqxS62mfUH5f0MYHb0RuHuubItHY7Lg5TVDyllcVtup9EhyHr8qbnAP2q4RJTQzvck74g0syT4IxeYOUMK6kR9apNFOT4Wt8M9L4KQEEHh82FYM091V8f4YxtS70H/mJUAy2N2nz/VHn8ypZcP4wnoYY3k=","ARC-Authentication-Results":"i=1; smtp.subspace.kernel.org;\n dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org\n header.b=fj/SQQTO; arc=none smtp.client-ip=10.30.226.201","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org;\n\ts=k20201202; t=1771367462;\n\tbh=SaaFcH6Oc3jCFSVMmx10cF8ncRdwRf8Ta+7Tz1QJAk4=;\n\th=Date:Subject:From:To:Cc:References:In-Reply-To:From;\n\tb=fj/SQQTOupipFBHak4x5z7L7flqm0zVy+U5fU1vEOY5RRLtwEct8yWTlitXXqmbs+\n\t YHeKKT3UprB8u+vKjGyJLaSu4F4SxH3FyBl453fEcfHkI2dU0eebWwPJu/cuIWLhzh\n\t D0lqVOxFF+uVb8X4HQwhH/TUkyrG6VauKQPgKZ81o54nu047R2pn0qF6hUNAxt1whk\n\t c0IHDAPfcIH6r5IH+j6LnYAKmHsCMTxbmPpv8mQCpK8gvlgluP6P9kwykHIQtvkEEF\n\t JCn099FPpmSGBu8bL3RFWj/Vrspg6sn5akQ7x6BoHNh7YG3c0iE67j6F9NtfvMIkES\n\t Brp7oIXxiianw==","Message-ID":"<f1e7f5d0-88cd-4d52-bc23-062f9f506844@kernel.org>","Date":"Tue, 17 Feb 2026 23:30:58 +0100","Precedence":"bulk","X-Mailing-List":"linux-rtc@vger.kernel.org","List-Id":"<linux-rtc.vger.kernel.org>","List-Subscribe":"<mailto:linux-rtc+subscribe@vger.kernel.org>","List-Unsubscribe":"<mailto:linux-rtc+unsubscribe@vger.kernel.org>","MIME-Version":"1.0","User-Agent":"Mozilla Thunderbird","Subject":"[PATCH RFC 08/10] driver core: make struct class groups members\n constant arrays","From":"Heiner Kallweit <hkall@kernel.org>","To":"=?utf-8?q?Thomas_Wei=C3=9Fschuh?= <linux@weissschuh.net>,\n Greg Kroah-Hartman <gregkh@linuxfoundation.org>,\n \"Rafael J. Wysocki\" <rafael@kernel.org>, Danilo Krummrich <dakr@kernel.org>,\n Jason Gunthorpe <jgg@ziepe.ca>, Leon Romanovsky <leon@kernel.org>,\n Alexandre Belloni <alexandre.belloni@bootlin.com>","Cc":"driver-core@lists.linux.dev,\n Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,\n linux-rdma@vger.kernel.org, linux-rtc@vger.kernel.org","References":"<5d0951ec-42c9-453f-9966-ecca593c4153@kernel.org>","Content-Language":"en-US","In-Reply-To":"<5d0951ec-42c9-453f-9966-ecca593c4153@kernel.org>","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"7bit"},"content":"Constify the groups arrays, allowing to assign constant arrays.\n\nSigned-off-by: Heiner Kallweit <hkallweit1@gmail.com>\n---\n include/linux/device/class.h | 4 ++--\n 1 file changed, 2 insertions(+), 2 deletions(-)","diff":"diff --git a/include/linux/device/class.h b/include/linux/device/class.h\nindex 65880e60c72..2079239a5aa 100644\n--- a/include/linux/device/class.h\n+++ b/include/linux/device/class.h\n@@ -50,8 +50,8 @@ struct fwnode_handle;\n struct class {\n \tconst char\t\t*name;\n \n-\tconst struct attribute_group\t**class_groups;\n-\tconst struct attribute_group\t**dev_groups;\n+\tconst struct attribute_group\t*const *class_groups;\n+\tconst struct attribute_group\t*const *dev_groups;\n \n \tint (*dev_uevent)(const struct device *dev, struct kobj_uevent_env *env);\n \tchar *(*devnode)(const struct device *dev, umode_t *mode);\n","prefixes":["RFC","08/10"]}