From patchwork Mon Mar 13 10:58:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geert Uytterhoeven X-Patchwork-Id: 13172211 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 DEFC2C7618D for ; Mon, 13 Mar 2023 10:58:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230206AbjCMK6u (ORCPT ); Mon, 13 Mar 2023 06:58:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56664 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229723AbjCMK6s (ORCPT ); Mon, 13 Mar 2023 06:58:48 -0400 Received: from baptiste.telenet-ops.be (baptiste.telenet-ops.be [IPv6:2a02:1800:120:4::f00:13]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EA21F28203 for ; Mon, 13 Mar 2023 03:58:42 -0700 (PDT) Received: from ramsan.of.borg ([IPv6:2a02:1810:ac12:ed50:7ed1:e2c6:b94:264a]) by baptiste.telenet-ops.be with bizsmtp id Xmyg2900401Vtj801mygze; Mon, 13 Mar 2023 11:58:40 +0100 Received: from rox.of.borg ([192.168.97.57]) by ramsan.of.borg with esmtp (Exim 4.95) (envelope-from ) id 1pbfsQ-00C3Hz-Ew; Mon, 13 Mar 2023 11:58:39 +0100 Received: from geert by rox.of.borg with local (Exim 4.95) (envelope-from ) id 1pbft1-008cWa-RO; Mon, 13 Mar 2023 11:58:39 +0100 From: Geert Uytterhoeven To: Mark Brown , Min Li , Lee Jones , Vladimir Oltean , Amit Kumar Mahapatra , Michal Simek Cc: linux-spi@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-kernel@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH 0/6] spi: struct spi_device constification Date: Mon, 13 Mar 2023 11:58:32 +0100 Message-Id: X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-spi@vger.kernel.org Hi all, After noticing new cases of casting away constness, I went over all spi_get_*() functions and their callers, and made the following changes: 1. Make all pointer parameters const where possible, 2. Remove unneeded casts, some not even related to constness. Patches 1-5 do not have any dependencies. Patch 6 depends on patch 5 (and current spi/for-next). Thanks for your comments! Geert Uytterhoeven (6): mfd: rsmu_spi: Remove unneeded casts of void * spi: fsl-dspi: Remove unneeded cast to same type spi: Constify spi_get_ctldata()'s spi parameter spi: Constify spi_get_drvdata()'s spi parameter spi: Constify spi parameters of chip select APIs spi: sh-msiof: Remove casts to drop constness drivers/mfd/rsmu_spi.c | 4 ++-- drivers/spi/spi-fsl-dspi.c | 2 +- drivers/spi/spi-sh-msiof.c | 4 ++-- include/linux/spi/spi.h | 8 ++++---- 4 files changed, 9 insertions(+), 9 deletions(-)