Received: by 2002:ab2:5d18:0:b0:1ef:7a0f:c32d with SMTP id j24csp301214lqk; Sat, 9 Mar 2024 10:34:04 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVdQpQPp04skpTDuX4+V049AQfcL1fC1xbtzJhU608Wo0mmNDI7mWNdXQTZPe4UnyOtkQQ7PE9UPnHgJ/ionRhS2v+6tRLlO9dh1HUqCw== X-Google-Smtp-Source: AGHT+IGCPz1u+FyGFjjMziPqXj1WZijixARsbeEGlU+mz2hF/E/TGiv0g+dqwHNdlK0f/L1xQCWm X-Received: by 2002:a05:620a:5625:b0:788:cf7:63ad with SMTP id vv5-20020a05620a562500b007880cf763admr3184193qkn.78.1710009244401; Sat, 09 Mar 2024 10:34:04 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1710009244; cv=pass; d=google.com; s=arc-20160816; b=W64KDUX7LdF20Dz03pSKjTZE0eaAXkHKSScME/a7/RIpCIBVS1QguyhvZKEGYBRjjO s5DHB1Sm47THhBTam4BpPvJDnlodct7fsK8sO/l0XiFPTaX3akOOUWJDGIlohu8Zkl5U jGXGpA//gJbVPrrPWUqb3Q+iAJ08qxCL4jPuXRiq75+z+GIkfU+ERXnywUglDDVV7N3B xMvHXGTaXkN6p3P4T+BNmXvhKwRcyo8Ax7SrQybDw3MEJq0V1ZN6/J2wcZsehG2gi6jt hIOxfTtydLfhFKEVJqfRji50u3h5nx7Pca87FgJTAbS8fnMGKdjJ7I7fyTxXkiKgjBuY qBGg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=ZyH3H30Gm3W60msRgB2vEPLiOlWCnO0fNWxNKTDIo2Y=; fh=M0hpgjz6RxB33TXTAdxqP8hL9Z2CYZv9WmTBai5p6NY=; b=spumiiPMUo1r56QFpahUn4idbccWZ2T7k2ELPYFckx8lu3tyi9LEaTr2dpGPk0vHb+ ea3u5DyEkRlKEXrrR6sLO1UFraMOYosmmOdr24GljO1Ji8tuWGNPl8FHYeoKmPSol0wP qeH5N6brG/KGultXa6xOUtN4ydyiAu5IPdZzx7Wi56VTCvKlspKsv1/FbTwJJItnR8Bj zLjIPRgVgzaORc0hqoijMEdw/IIn9pF7p3Mg5+Snzmt+xxMyuNcqXOYJ7Rl7HyPQ7t+f b3zAgpQP2RPiPjodimQjNyyP2LXHleYWiZvvf2dy8QaTKeI9mNWvyDqhDJZhcyyAWcRw bIYQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=GMmGgB5Z; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-98009-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-98009-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id j1-20020a05620a288100b007883231ca49si2057740qkp.130.2024.03.09.10.34.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 09 Mar 2024 10:34:04 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-98009-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=GMmGgB5Z; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-98009-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-98009-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org 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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 2450B1C20BFB for ; Sat, 9 Mar 2024 18:34:04 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 58C1645037; Sat, 9 Mar 2024 18:33:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="GMmGgB5Z" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 8197F16FF22; Sat, 9 Mar 2024 18:33:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710009236; cv=none; b=PZvx3mxnDnK4UIORREf/klwYireqihfwI6G6xevqF7CXXG6WLhPQ4K3zY9ke+2RGyQNbJGaoNIPicHI9BNhpdS83eVZQvwZw6b+0my66ravRrvvY1unKcS7LBSIhhx/ex5gLZSKKzGBSQOXf0Xs2I2+KG3fuZecMNbzTxiHgnCI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710009236; c=relaxed/simple; bh=V4BVn+p29jgKIEBrnrJ3faIeVM+yxyyl+7AFMGtnH0Y=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=XBoh8RotpC1CyxmxQN1NIvedGL58KgzJZ/yTtRR5OlCBMBHTPyX+U60Whr2HO1COmafx5QKGlUFBae7WDb4/Zg71fqk3msVonhCj9PpeMJmJwF5udf9HuLIKQQ+/fzByBgWfO/iX83xfG6V01ZUGK520pS1obghKZXd6TEfDmYI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=GMmGgB5Z; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id BCC3DC433C7; Sat, 9 Mar 2024 18:33:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1710009236; bh=V4BVn+p29jgKIEBrnrJ3faIeVM+yxyyl+7AFMGtnH0Y=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=GMmGgB5ZGTU0byoloLB3ufSybDONQ/KEUnQHiWLD5fCXkYiMa6L+mSgxdKo5EtfBK cI9K9DFxV+tv9JFybeSCZwCyPFPqbcbY8UOS5JPHveV3N7gRJzG6WMMdY62vD25L+2 R1j0iCmrCsnte5JNnawVZkqwhzMHJTgh/g8abZT7vUg074sosXG50YmWXbS16/5nTH mjLBYnFpBj5UNsEDzctHruT9XCzNR4CRLkelIwuRoTCXxvt/hK5exeys9TJ+iN4CyG h0FC344So3IiUKdBwQw2Hlnw3mTb77GKMhYWtAIIDTPAaV2Y+At/aI4PmVF3D50qoj M4xMOdWiaUFaQ== Date: Sat, 9 Mar 2024 18:33:42 +0000 From: Jonathan Cameron To: Javier Carrasco Cc: Arnd Bergmann , Greg Kroah-Hartman , Michal Simek , Lars-Peter Clausen , Lorenzo Bianconi , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org Subject: Re: [PATCH 0/4] Drop casting to void in dev_set_drvdata Message-ID: <20240309183342.578161e7@jic23-huawei> In-Reply-To: <20240303-void_in_dev_set_drvdata-v1-0-ae39027d740b@gmail.com> References: <20240303-void_in_dev_set_drvdata-v1-0-ae39027d740b@gmail.com> X-Mailer: Claws Mail 4.2.0 (GTK 3.24.41; x86_64-pc-linux-gnu) 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=US-ASCII Content-Transfer-Encoding: 7bit On Sun, 03 Mar 2024 23:34:38 +0100 Javier Carrasco wrote: > The C standard specifies that there is no need to cast from a pointer to > void [1]. > > The vast majority of the users of dev_set_drvdata do not cast their > pointers to void, and the few that do so should be fixed before it > spreads by following bad examples (which I was about to do here [2]). > > The very specific cases where the cast avoids warnings (e.g. droping > const) have been kept as they are. > > [1] C Standard Committee: https://c0x.shape-of-code.com/6.3.2.3.html > [2] https://lore.kernel.org/linux-iio/20240226-hdc3020-pm-v2-0-cec6766086e8@gmail.com/T/#t > > Signed-off-by: Javier Carrasco > --- > Javier Carrasco (4): > char: xilinx_hwicap: drop casting to void in dev_set_drvdata > io: light: st_uvis25: drop casting to void in dev_set_drvdata > iio: humidity: hts211: drop casting to void in dev_set_drvdata > iio: imu: st_lsm6dsx: drop casting to void in dev_set_drvdata > > drivers/char/xilinx_hwicap/xilinx_hwicap.c | 2 +- > drivers/iio/humidity/hts221_core.c | 2 +- > drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c | 2 +- > drivers/iio/light/st_uvis25_core.c | 2 +- > 4 files changed, 4 insertions(+), 4 deletions(-) > --- > base-commit: 90d35da658da8cff0d4ecbb5113f5fac9d00eb72 > change-id: 20240303-void_in_dev_set_drvdata-2d8cae908e49 > > Best regards, Thanks for tidying these up. Applied to the togreg-normal branch of iio.git. This will get rebase on rc1 once available and become togreg. Jonathan