Received: by 2002:ab2:68c1:0:b0:1fd:9a81:d0e4 with SMTP id e1csp390833lqp; Sun, 9 Jun 2024 00:27:39 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWw2Wr0Gwq+WOPAjd1AYtihCLHY8FiFZ41aG02oYvEO+VpQ2z1akZ+fChYcGsh5Aee6Xc32evmgwsONElWWArOeUNhKkScDPp1cUo+JcA== X-Google-Smtp-Source: AGHT+IH8+zfioK1ODBtR8/729Y6tzmUPc7R5u9gj7BgASwaOdLocF/tr4g5Ut4aHsEeOH7FOvE34 X-Received: by 2002:a17:90a:a110:b0:2bf:9981:e0ae with SMTP id 98e67ed59e1d1-2c2bcc6cfe0mr5784701a91.39.1717918059326; Sun, 09 Jun 2024 00:27:39 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717918059; cv=pass; d=google.com; s=arc-20160816; b=yte9idfLK7bB9+np3LLvbKMRu6Q+yOdGBA1UdbF8OFU7dj2J37uPvsq1wwnd4RTy8U WnG/QDWUvccGlX7dBrJTKbK1WxpySi+f3x5NvqQ558GdyG0AjxbMnxO6tFL201V+U8ar JWkV4zBbjSxOPiTlMBfsId1Bd5RzZYIavT4pdL+496EqG5lmg4gbCLLTjTGWkDNchYXd QHUyuw0iIGPsQMKHQhRT/NO7q2Rfs0jS/z1Hht4wa8XfH6pOOxZjd7QWafVxEMFr5tvM 58ZBVoyTrsI5TOWw9J3uLsNT+SV7N4ys8tNzSVSXwRLnE0eKDZLGp+3OFNuflnKxYbbx 8TaQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=+PZhb9Pa3Uka1vD2pj/r4T9WFjgM1ldf1N6BhgmfYA8=; fh=3fJWFrtiiPD+viya4NwE6ZvCPdMm1SLkJQEHzoJ8YWk=; b=E6353CePAYdjUBKUhn9V76CruAmMccCIr+zPikXosPc5JJDmzIC8DTQA1wI0wul55c 3yQARANYlEbOfKp949Hayo4rOMRkxUPVGPWvLn/MCNoCnSeffqiLcNh+Avrwj5PMyGIj up2h/a38wJzGTf1bIkaNVZs/rUs2K4YNUz07Z6Bv6B3f/M+Nw/Z5Y2aotR30FjzMTKXo S6pTQDWzdPsgtQtw0de0WAw5Jbjy09cMTiRyUUqiK+33m7oiNFRmuY0wVRxzDhZLrinB QtbrvM8OC42E4VpkI94y8ZLSZlmwwCltGgjKKnh7ozzRg9/2L7y2Dnt0gYOiw5i5WQmc /diw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@weissschuh.net header.s=mail header.b=PwavMIqt; arc=pass (i=1 spf=pass spfdomain=weissschuh.net dkim=pass dkdomain=weissschuh.net dmarc=pass fromdomain=weissschuh.net); spf=pass (google.com: domain of linux-kernel+bounces-207263-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-207263-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=weissschuh.net Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id 41be03b00d2f7-6e43ea935ffsi1949677a12.738.2024.06.09.00.27.39 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 09 Jun 2024 00:27:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-207263-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@weissschuh.net header.s=mail header.b=PwavMIqt; arc=pass (i=1 spf=pass spfdomain=weissschuh.net dkim=pass dkdomain=weissschuh.net dmarc=pass fromdomain=weissschuh.net); spf=pass (google.com: domain of linux-kernel+bounces-207263-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-207263-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=weissschuh.net Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id EB471281D6E for ; Sun, 9 Jun 2024 07:27:38 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 04E081CD24; Sun, 9 Jun 2024 07:27:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=weissschuh.net header.i=@weissschuh.net header.b="PwavMIqt" Received: from todd.t-8ch.de (todd.t-8ch.de [159.69.126.157]) (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 2300118C3D; Sun, 9 Jun 2024 07:27:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=159.69.126.157 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717918041; cv=none; b=OE1aybK3b68RLPw6+sKmRmHUwGInIAC+ZrCbGO+NL5VLSaRZwcnDd7zOIdPP9pL2EHr2+dKnfRxmMoDeqn+Y62xsEKJEXuV+WzSDrVECWl4yLDs+QfFjgOmMUlN6wakTFkMRxhyIjCHchlGJNKsbIVmIMGtxqeNlsAoIk5o0BzE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717918041; c=relaxed/simple; bh=9X9E0iPzjMX5HXPIZVXXhzNHMsBF2nq1d13kKi6GrZo=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=GLocO8qIsM0Ke1H85LZwOdGYCTXEuXRBUavt+UdYV2kbi4rZRPkwBJkc9Ssernbkc0MUHG7oALc55IhH1EA+Pwrzyi7RX5bm8pstEUj2t7ZoKq8OvQvPefWDmXl0rfp/nLA0S9AxT45QQlAslxMcrROX3iFqCiiBgvSK96CnPRA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=weissschuh.net; spf=pass smtp.mailfrom=weissschuh.net; dkim=pass (1024-bit key) header.d=weissschuh.net header.i=@weissschuh.net header.b=PwavMIqt; arc=none smtp.client-ip=159.69.126.157 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=weissschuh.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=weissschuh.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=weissschuh.net; s=mail; t=1717918035; bh=9X9E0iPzjMX5HXPIZVXXhzNHMsBF2nq1d13kKi6GrZo=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=PwavMIqtPyB328UWGLX7Ga2bMGPkKqkD/DHR8DeYW1128Dzohc9JHLvw+2ErmBAZ5 LNPLzVq+d1qaI6HN3rCqIWKi//STYTKvPZDqOQwg5Ib/MxXrsvDbnUJ6R4niOdU2Ln 2igEvZGX2DhQnPc4a91784vjDSg5V5ySEdpPxvTw= From: =?utf-8?q?Thomas_Wei=C3=9Fschuh?= Date: Sun, 09 Jun 2024 09:27:13 +0200 Subject: [PATCH 2/5] ACPI: SBS: constify powersupply properties Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Message-Id: <20240609-acpi-battery-cleanup-v1-2-344517bdca73@weissschuh.net> References: <20240609-acpi-battery-cleanup-v1-0-344517bdca73@weissschuh.net> In-Reply-To: <20240609-acpi-battery-cleanup-v1-0-344517bdca73@weissschuh.net> To: "Rafael J. Wysocki" , Len Brown Cc: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, =?utf-8?q?Thomas_Wei=C3=9Fschuh?= X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1717918035; l=1215; i=linux@weissschuh.net; s=20221212; h=from:subject:message-id; bh=9X9E0iPzjMX5HXPIZVXXhzNHMsBF2nq1d13kKi6GrZo=; b=3EAwR4Ckbm989qU4jNHQMG4Ws6kMJaRPp23/innoYxEMDXJv2YffoDLEUFAvV5OiGZjlokp7U zVI+WwB+Rd2BZ8h4VxwXZXb5ontQ2KusUlp21aUNC7sw2EOj3by+3AR X-Developer-Key: i=linux@weissschuh.net; a=ed25519; pk=KcycQgFPX2wGR5azS7RhpBqedglOZVgRPfdFSPB1LNw= The arrays are never modified, make them const. Signed-off-by: Thomas Weißschuh --- drivers/acpi/sbs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/acpi/sbs.c b/drivers/acpi/sbs.c index dc8164b182dc..3d81ce3103c6 100644 --- a/drivers/acpi/sbs.c +++ b/drivers/acpi/sbs.c @@ -241,11 +241,11 @@ static int acpi_sbs_battery_get_property(struct power_supply *psy, return 0; } -static enum power_supply_property sbs_ac_props[] = { +static const enum power_supply_property sbs_ac_props[] = { POWER_SUPPLY_PROP_ONLINE, }; -static enum power_supply_property sbs_charge_battery_props[] = { +static const enum power_supply_property sbs_charge_battery_props[] = { POWER_SUPPLY_PROP_STATUS, POWER_SUPPLY_PROP_PRESENT, POWER_SUPPLY_PROP_TECHNOLOGY, @@ -263,7 +263,7 @@ static enum power_supply_property sbs_charge_battery_props[] = { POWER_SUPPLY_PROP_MANUFACTURER, }; -static enum power_supply_property sbs_energy_battery_props[] = { +static const enum power_supply_property sbs_energy_battery_props[] = { POWER_SUPPLY_PROP_STATUS, POWER_SUPPLY_PROP_PRESENT, POWER_SUPPLY_PROP_TECHNOLOGY, -- 2.45.2