Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp4185664pxk; Tue, 22 Sep 2020 12:31:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJykfhxAhCpI72qxFw3eeuHBl8DNTm8gu/w/07+SjJG1Md1y32NJ/J2Ey/ZbwvzEu7gxASZl X-Received: by 2002:a17:906:b88e:: with SMTP id hb14mr6472188ejb.543.1600803064036; Tue, 22 Sep 2020 12:31:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600803064; cv=none; d=google.com; s=arc-20160816; b=FI2HYeXsO1nyo/kN2GjYSDAW2/Aeao4Kro2ThY7IYFOyjYBNHm8jS1vkNoZfccbK+h 2U9SsuEb7GYWjH42JllM5JNso6sJN439Y5pC2W34MRiHAZldzcIolEriXfq3dbO4RYmJ EY3Ix6kh+0LbZZNJa7W0J4PV5wjQI3rLr5ie5CHlFqL38nZU92rjb4NFpEF2jhCzwXkB 1ktuL3MEpvJaZleDLd/lVLmaOmVVORWEXfmk41ZoWz2NO7jybGn1MN8EXfrLVW5jHO10 XYChzjlajjY4OxoFAAbCK6nnFrc2X0IfaQMFLYTow78Eii2218LmJjUJz+blGEdzJyba JelQ== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=nYcqdmFs1PmE8Rv5grjsTkZpEbMvl8+RIYQHgKvNpbA=; b=jzVdXFyB0XOd1+6BeX/Z/ohjJe+4SsKPzj28djyxZ/yhO5vNP5ZL5IZVJchaHVUSfG KjZUge7KziYS+D3k5Ir6SLysajnnP80hLvYLRicfhJmCG/trwqwKOQ3CrISAgGKNvFgV +rc7myyEuJuNAYO6Vap/fbASuxn0kazTfj7yhwvZA/OcjAxyVvtQ5mXH4BoDeSIeN1Eu MA/Rt/KKixJleZR7AlB9EnPjZ3BVdz0mK08TEzPj70b0XNnfY92MADoQPRYu2w8AUzBm zEkorBjLL2BxKe86jva0XDFU50EgwIP6yGpU1+BCqWHodQSJ81zrvMpRnylTWxX3wfpf 4SCQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=FcS8F4BQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bu14si10874846edb.128.2020.09.22.12.30.40; Tue, 22 Sep 2020 12:31:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=FcS8F4BQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726748AbgIVT13 (ORCPT + 99 others); Tue, 22 Sep 2020 15:27:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55258 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726703AbgIVT1T (ORCPT ); Tue, 22 Sep 2020 15:27:19 -0400 Received: from mail-lf1-x142.google.com (mail-lf1-x142.google.com [IPv6:2a00:1450:4864:20::142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A6D4BC061755 for ; Tue, 22 Sep 2020 12:27:18 -0700 (PDT) Received: by mail-lf1-x142.google.com with SMTP id y17so19311254lfa.8 for ; Tue, 22 Sep 2020 12:27:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=nYcqdmFs1PmE8Rv5grjsTkZpEbMvl8+RIYQHgKvNpbA=; b=FcS8F4BQ6OdTY7D13hGLupoqkrDNRBRA7PAdb5aftII63YWwwufoBJU2BwwYBESv1Y MywbEkMbiVbM4OHLMFgnUrmrwi9G850KZVUrFdnAgdlt3nAH/D/gQzNJ6L9P8z2Sqn1R 3DT+K6Vyxci/PiGJLFkV/jujxI30QaMKiWWQoGs5oNxqHB7kMusa3G+plK0JtQb3SQUv y9KxcLQRpgW6KjACtzkkGBdUkywzozNEBus2FF+WzBTwWrZzvDcTWWieZJSgFnejUqUz JjE2Lpaj7Zce0EzwMbmfaNGIMQq3euNsqmajt0xrsY+xtazDCUHm/rVsOtQM5K8/s+jq mo3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=nYcqdmFs1PmE8Rv5grjsTkZpEbMvl8+RIYQHgKvNpbA=; b=SLSTjI+SJdwrqZCgtfY9KTqbFFpAL/LjNrW9f9G2Ryy1OndlmTNM0RM8Zc/4qk5+Bi Q42ly4uj8oPM0aZQugLyeO7wybtbfzbqHdrY+lTUxs7IdrbDTqBg5SGYWHq12i+OPXwM 4DMqm/+Rz4slfFYO9L56d8iFqBETDyXIW5FbHQJaD31HdVrLaNa32FomWA5VjfOLlsW6 GudUQy03NVVKehH9U5mhKb0GnPH+IwT4aqvCTGocfCExHuiRyizAA7W7gKkyFRe5+Fl3 gxrZ+EPLbGUcsOeO1Kia4/BTAU4u9+eytbX1FGu4PEm07Z1M/JYqz+UbqjSxa5rVqCUU 2D4w== X-Gm-Message-State: AOAM5325onPFHgEPSyc3rdXBgMzEBc3T3M5BZvcns0zXgxBrDqP3qwO4 BCD6n18BarApnB/KoXQVZJA= X-Received: by 2002:a19:4319:: with SMTP id q25mr1868947lfa.505.1600802837129; Tue, 22 Sep 2020 12:27:17 -0700 (PDT) Received: from localhost.localdomain (h-82-196-111-59.NA.cust.bahnhof.se. [82.196.111.59]) by smtp.gmail.com with ESMTPSA id r132sm3770013lff.167.2020.09.22.12.27.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 22 Sep 2020 12:27:16 -0700 (PDT) From: Rikard Falkeborn To: Lee Jones Cc: linux-kernel@vger.kernel.org, Rikard Falkeborn , Maxime Ripard , Chen-Yu Tsai , linux-arm-kernel@lists.infradead.org Subject: [PATCH 7/8] mfd: sun4i-gpadc: Constify static struct resource Date: Tue, 22 Sep 2020 21:26:58 +0200 Message-Id: <20200922192659.14535-8-rikard.falkeborn@gmail.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200922192659.14535-1-rikard.falkeborn@gmail.com> References: <20200922192659.14535-1-rikard.falkeborn@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Constify adc_resources[]. The only usage is to assign its address to the resources field of the mfd_cell struct. This allows the compiler to put it in read-only memory. Done with the help of Coccinelle. Signed-off-by: Rikard Falkeborn --- drivers/mfd/sun4i-gpadc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mfd/sun4i-gpadc.c b/drivers/mfd/sun4i-gpadc.c index b346fbce3c01..aaa233d916b2 100644 --- a/drivers/mfd/sun4i-gpadc.c +++ b/drivers/mfd/sun4i-gpadc.c @@ -18,7 +18,7 @@ #define ARCH_SUN5I_A13 1 #define ARCH_SUN6I_A31 2 -static struct resource adc_resources[] = { +static const struct resource adc_resources[] = { DEFINE_RES_IRQ_NAMED(SUN4I_GPADC_IRQ_FIFO_DATA, "FIFO_DATA_PENDING"), DEFINE_RES_IRQ_NAMED(SUN4I_GPADC_IRQ_TEMP_DATA, "TEMP_DATA_PENDING"), }; -- 2.28.0