From nobody Fri Sep 12 18:11:25 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C2596C636CC for ; Wed, 8 Feb 2023 11:15:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231232AbjBHLPA (ORCPT ); Wed, 8 Feb 2023 06:15:00 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42102 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230390AbjBHLOV (ORCPT ); Wed, 8 Feb 2023 06:14:21 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 51926252A4 for ; Wed, 8 Feb 2023 03:14:20 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id E188F6162F for ; Wed, 8 Feb 2023 11:14:19 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id F118CC433EF; Wed, 8 Feb 2023 11:14:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1675854859; bh=PZzGpl+8CjvP6M9qzHvZdlUXDvUpv1J5wQBWhMe4CgI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=caOzQcyWJosdreqxaNtSA06wmmTsdMF77U1XH7pEEiTLGKSlMp4btkoYWP6Miw/xO Xgb9S9H+mw/+5aTQ2Dpb5beTtgP1YqU5AuvdhGJWL4gSNiwaZMZ3FBw3Bkb7ALJrE6 gM4zRGM4hyPRMQ1ZjhBs7DINoDd0HnQVsvzHsyUA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , "Rafael J. Wysocki" Subject: [PATCH 20/21] driver core: bus: constify some internal functions Date: Wed, 8 Feb 2023 12:13:29 +0100 Message-Id: <20230208111330.439504-21-gregkh@linuxfoundation.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230208111330.439504-1-gregkh@linuxfoundation.org> References: <20230208111330.439504-1-gregkh@linuxfoundation.org> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1255; i=gregkh@linuxfoundation.org; h=from:subject; bh=PZzGpl+8CjvP6M9qzHvZdlUXDvUpv1J5wQBWhMe4CgI=; b=owGbwMvMwCRo6H6F97bub03G02pJDMmPm2+yXvoj8fPTsbNlkyYm3l/H1rSI17c8cpdZrHgll7+/ 73mdjlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZjIG1mG+bGyfVm3Nux9sjHmVaPfu9 zPX93snjEsWPbs94Zr7oKTewKWKd+s35uR+/iWOwA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" The functions add_probe_files() and remove_probe_files() should be taking a const * to bus_type, not just a *, so fix that up. These functions should really be removed entirely and an attribute group used instead, but for now, make this change so that other const work can continue. Cc: "Rafael J. Wysocki" Signed-off-by: Greg Kroah-Hartman --- drivers/base/bus.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/base/bus.c b/drivers/base/bus.c index 815638bf63db..a7aada8817ce 100644 --- a/drivers/base/bus.c +++ b/drivers/base/bus.c @@ -603,7 +603,7 @@ static void remove_bind_files(struct device_driver *drv) static BUS_ATTR_WO(drivers_probe); static BUS_ATTR_RW(drivers_autoprobe); =20 -static int add_probe_files(struct bus_type *bus) +static int add_probe_files(const struct bus_type *bus) { int retval; =20 @@ -618,7 +618,7 @@ static int add_probe_files(struct bus_type *bus) return retval; } =20 -static void remove_probe_files(struct bus_type *bus) +static void remove_probe_files(const struct bus_type *bus) { bus_remove_file(bus, &bus_attr_drivers_autoprobe); bus_remove_file(bus, &bus_attr_drivers_probe); --=20 2.39.1