Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp5141773pxj; Wed, 9 Jun 2021 10:04:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwGwB3KTqqlEi/lAkSKrD+Z5weIAfqSLZRjCW2hQYEbtLNj7AKMF56qnvyouAsMY9L125h0 X-Received: by 2002:a17:906:a293:: with SMTP id i19mr768920ejz.311.1623258248296; Wed, 09 Jun 2021 10:04:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623258248; cv=none; d=google.com; s=arc-20160816; b=rHd+r0R3D4rE6vnX9A+NxoVunPHs1PVDOUHbxEkP60WgPXqVPdCKJHKBFgVwhu8Bz2 4Q+1ToR98eY5J0jpdblxy0DAGbS2q/xeCB235eGXn4RwXxSYUzGnkSlUpXPNUyT2guxM xxaYA33kTCVfDTbqB+ZMQDdkwm8rQULMERUUMUIdxl/Vnjg5ymGo/Ow2i6R8h2BzrE1Q FzHXQp2P/yAYhDV4UUZFUbEXnMSH+xnNIUo6xIs7Cw8FxtN4LpKP3Vp/R4vPDzm5WYH1 iWtBC5MOB4cZdL2FmyQgQbc4R/P2+1gYScD1XD6d2kl57FFd+4hcOQOUtWvg8Xk1ot11 twkA== 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=rzSSFM9eA7D/nASKgieKIKXoM9U+od0SIxRVo0RKwbs=; b=yxOGurZFPpe8syWrIHqeZwlVpzoBEFCDjEKiMXhO2f0ohCE/x6uQjKoYo4grXkd4n/ HlKgNOx7jWit5JTtF6uhnmqIXs5BQbncvHL/ftzIwqjh9hHCgbLFkLfNWAofQbY9nBCA KIwhl5GAjcOvdcZD3pGDpp8KPMzqMGG+C1s+bZHPmZnOxBwOIikZI7iBSso89dEx/DQt 4DTXbbQ994rV0IYN5tVfvoirI98UDcWoVF7UPLqsbiez2fxskrfQ3eh6+hlcs996i+0r 7v3d4BZp/86bPTpcHXEg4XNNtzc8utU5DIPpAowB7HTOdYJIyax+mJDebly4G7sEUDeH bSbg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=T37gis28; 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 r18si190276edd.158.2021.06.09.10.03.37; Wed, 09 Jun 2021 10:04:08 -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=T37gis28; 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 S235470AbhFIBeX (ORCPT + 99 others); Tue, 8 Jun 2021 21:34:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36502 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235458AbhFIBeX (ORCPT ); Tue, 8 Jun 2021 21:34:23 -0400 Received: from mail-pl1-x629.google.com (mail-pl1-x629.google.com [IPv6:2607:f8b0:4864:20::629]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5E8AAC061574; Tue, 8 Jun 2021 18:32:20 -0700 (PDT) Received: by mail-pl1-x629.google.com with SMTP id x10so11682864plg.3; Tue, 08 Jun 2021 18:32:20 -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=rzSSFM9eA7D/nASKgieKIKXoM9U+od0SIxRVo0RKwbs=; b=T37gis28MP075rqTyRhAlrTWtsa3kDZQh1r47qcKH0NNEVSompkKpN5d7z8GDHGHqz VlzszmEKm7FtBv5XEJH6XDp+8+BIkZl9JCTA/fGHu1WoypHkO74bmkZTclWCEZBtW9yZ RTN3tIBQXoILSRugZw5mxdymx8R0xy0U4naAciR4tfkPoTv3MC07yhkHoM9ISpDKs1Zj b79JYllFGL0YAt8EiQHH8IrZSiVflGpAvEUehWNlEgSu8pP0tkSDXz5LGr5kHL9L3cqf j9195/L44+nURGJQoYjms3Rp9Uiqd1IVCETmsf/WEUSFnzOYR5HQOXmnHvoexyiSpXPF QHUQ== 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=rzSSFM9eA7D/nASKgieKIKXoM9U+od0SIxRVo0RKwbs=; b=EhWSj0lSPLPmbRNOrQPPuSXYZtiua3u/mLs9E0Go/4xJYVVhRg0BPOFOZAq6F90wYx gNeitqloMx7hcqFwvWgFF0gRofZhxjy8gyvpWjPF9eenHdq1PNLCcuamJRwNKk6wnITF h9Pt8mBO0/xck6JXzwuG7hQyusPY7hBU6HgytTl9SZuP4mqR8c9/mv0Q9oP96bGEJ835 HHdBmTWr/Vn/qp0fhBFf5rN8iRIgrOPbCKM4v3YY8dG5MRhE0D40HMHUngRRYgvZdWWG 20thKhhwGuBtdAwqzsAjCz4KUYdpITdF7l42Jx2e4DiBZhM9MGhXRPPAxLkANjh+FBqe rBRQ== X-Gm-Message-State: AOAM5325bhlCl90JQNnerHJ/mwT4YaseIVngH7rYSodHXNHuEHCvGRnf M/djmCX3bI+DtGhyZkWGN7g= X-Received: by 2002:a17:90a:e541:: with SMTP id ei1mr28850129pjb.189.1623202339993; Tue, 08 Jun 2021 18:32:19 -0700 (PDT) Received: from localhost.localdomain ([156.146.35.76]) by smtp.gmail.com with ESMTPSA id v14sm12659815pgl.86.2021.06.08.18.32.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Jun 2021 18:32:19 -0700 (PDT) From: William Breathitt Gray To: jic23@kernel.org Cc: linux-stm32@st-md-mailman.stormreply.com, kernel@pengutronix.de, a.fatoum@pengutronix.de, kamel.bouhara@bootlin.com, gwendal@chromium.org, alexandre.belloni@bootlin.com, david@lechnology.com, linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, syednwaris@gmail.com, patrick.havelange@essensium.com, fabrice.gasnier@st.com, mcoquelin.stm32@gmail.com, alexandre.torgue@st.com, o.rempel@pengutronix.de, jarkko.nikula@linux.intel.com, William Breathitt Gray Subject: [PATCH v11 06/33] counter: 104-quad-8: Add const qualifiers for quad8_preset_register_set Date: Wed, 9 Jun 2021 10:31:09 +0900 Message-Id: <050f1b518eeae8e3683f7d6d11f3219a137adf48.1623201081.git.vilhelm.gray@gmail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add some safety by qualifying the quad8_preset_register_set() function parameters as const. Acked-by: Syed Nayyar Waris Signed-off-by: William Breathitt Gray --- drivers/counter/104-quad-8.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/counter/104-quad-8.c b/drivers/counter/104-quad-8.c index 0fd61cc82d30..51fba8cf9c2a 100644 --- a/drivers/counter/104-quad-8.c +++ b/drivers/counter/104-quad-8.c @@ -632,8 +632,8 @@ static ssize_t quad8_count_preset_read(struct counter_device *counter, return sprintf(buf, "%u\n", priv->preset[count->id]); } -static void quad8_preset_register_set(struct quad8 *priv, int id, - unsigned int preset) +static void quad8_preset_register_set(struct quad8 *const priv, const int id, + const unsigned int preset) { const unsigned int base_offset = priv->base + 2 * id; int i; -- 2.32.0