Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp972439rwl; Fri, 7 Apr 2023 08:06:02 -0700 (PDT) X-Google-Smtp-Source: AKy350YPPuMq4uoMh15jC9bgNR7RAsZBD6Fjnip9gf6HATV5P4dTvp+4l6j+aH9BCsAE6lUxQlTu X-Received: by 2002:a50:fc11:0:b0:502:7eeb:edb2 with SMTP id i17-20020a50fc11000000b005027eebedb2mr2780421edr.26.1680879962044; Fri, 07 Apr 2023 08:06:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680879962; cv=none; d=google.com; s=arc-20160816; b=awHgyWbZXBI7i+AU6gcQiOwSWU8ib3l9QcXFf9RWrg8XaGPk+yqRD7ej71i5toA0v2 eMgvD/zC80X39InX6+iTHmK4UNKlJjLM318dK4GoiVJAXvo6yDYd3u1ly59ctM7bDB4l KbZV3iWdqOuLuBOv7nbdU83Hb1WX/qE4UvgVdvfGv6hytBdk9Ne8hmkILPxkmT/xjqvK flB82eCJBcuZjPTr/PNPOiZWDIoNV4Y+XBT3B2HZ4QirMxKOKipE3vIB68+1VkLw8HVl Z/dwsB/9gRaYYspK+PeYigoOHOKNnCopBfXluOp6AInWIwkoSypM9kNH8Wq02c6AlLmx 5Ugg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=bmn1i2s+kRK6QEknyMTa0vqn570EJuJOWo71+kFnPZs=; b=vrgRxdPfFRfKRX3QRqPyVajpVJDUStFT4OVW15eRwzXS37npso1PeciaBUp3FRKBRj tev1vTwa+hcolgUAVQqSD1lpjQh2DrNx4WLFtpkXzmfQAHh3qXq7nKKMDeZCyFA+tXe2 R8xSX0NSl2B/zM8BflvN8LwrSNnIyiZq+2zGJDVpieahWfzHKjbkiVq15sCSMIjiLjbl jw1PZuwTcLh55m1+ubIAIqg7CCA0rJu0U2GfRexX1lKHJZ5X1EEhYWg+yi45nRPi2zKr ffdKcCMk4oo8G9OM1PUYeI5LelQwnSUBHkxcM4GvG3d43bGsOFH5prDZS6ELPqjWQ92u sCuQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w12-20020aa7da4c000000b00501d39f793esi2623564eds.157.2023.04.07.08.05.29; Fri, 07 Apr 2023 08:06:02 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240679AbjDGPFL (ORCPT + 99 others); Fri, 7 Apr 2023 11:05:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34452 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240855AbjDGPEy (ORCPT ); Fri, 7 Apr 2023 11:04:54 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3B2D8BBBE; Fri, 7 Apr 2023 08:03:57 -0700 (PDT) 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 E7AD064A2E; Fri, 7 Apr 2023 15:03:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7DFE6C433EF; Fri, 7 Apr 2023 15:03:43 +0000 (UTC) From: Krzysztof Kozlowski To: =?UTF-8?q?Thomas=20Wei=C3=9Fschuh?= , Hans de Goede , Mark Gross , Jeremy Soller , System76 Product Development , Azael Avalos , platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Krzysztof Kozlowski , Jean Delvare , Guenter Roeck , linux-hwmon@vger.kernel.org Subject: [PATCH 1/4] platform/x86: gigabyte: constify pointers to hwmon_channel_info Date: Fri, 7 Apr 2023 17:03:36 +0200 Message-Id: <20230407150339.80218-1-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.0 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Statically allocated array of pointed to hwmon_channel_info can be made const for safety. Signed-off-by: Krzysztof Kozlowski --- This depends on hwmon core patch: https://lore.kernel.org/all/20230406203103.3011503-2-krzysztof.kozlowski@linaro.org/ Therefore I propose this should also go via hwmon tree. Cc: Jean Delvare Cc: Guenter Roeck Cc: linux-hwmon@vger.kernel.org --- drivers/platform/x86/gigabyte-wmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/platform/x86/gigabyte-wmi.c b/drivers/platform/x86/gigabyte-wmi.c index 5e5b17c50eb6..7cc969fb1beb 100644 --- a/drivers/platform/x86/gigabyte-wmi.c +++ b/drivers/platform/x86/gigabyte-wmi.c @@ -99,7 +99,7 @@ static umode_t gigabyte_wmi_hwmon_is_visible(const void *data, enum hwmon_sensor return usable_sensors_mask & BIT(channel) ? 0444 : 0; } -static const struct hwmon_channel_info *gigabyte_wmi_hwmon_info[] = { +static const struct hwmon_channel_info * const gigabyte_wmi_hwmon_info[] = { HWMON_CHANNEL_INFO(temp, HWMON_T_INPUT, HWMON_T_INPUT, -- 2.34.1