From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E3EA3C433E6 for ; Thu, 4 Mar 2021 13:12:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B733D64F32 for ; Thu, 4 Mar 2021 13:12:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241139AbhCDNLr (ORCPT ); Thu, 4 Mar 2021 08:11:47 -0500 Received: from mail.pqgruber.com ([52.59.78.55]:39460 "EHLO mail.pqgruber.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241136AbhCDNLj (ORCPT ); Thu, 4 Mar 2021 08:11:39 -0500 Received: from workstation.tuxnet (213-47-165-233.cable.dynamic.surfer.at [213.47.165.233]) by mail.pqgruber.com (Postfix) with ESMTPSA id A3803C72819; Thu, 4 Mar 2021 14:10:57 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pqgruber.com; s=mail; t=1614863458; bh=zi1uK+zkf8Cgx3t0AT2qIAjy7nM1fwlN1EPUn/BXkj8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=n5LjpydTpkWqoXhs832+EtisbJ5GibaVksKmxZyFKAauph4aC8VxhiWOkd+DXvwWF dNDytUlNJOSPRVNWFfYGsKU6gyJAdW7WgM9vBQeC07c2PYOtzQ6QTgIs9Wcomx1OPY U9Gw9ypaJxPqabegMrGO/ZKrXAB7tgnwpDpcTc1o= Date: Thu, 4 Mar 2021 14:10:56 +0100 From: Clemens Gruber To: Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= Cc: Sven Van Asbroeck , linux-pwm@vger.kernel.org, Thierry Reding , Lee Jones , Linux Kernel Mailing List , Mika Westerberg , David Jander Subject: Re: [PATCH v5 1/7] pwm: pca9685: Switch to atomic API Message-ID: References: <20201215212228.185517-1-clemens.gruber@pqgruber.com> <20210301214115.xolncig676tgnxwn@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20210301214115.xolncig676tgnxwn@pengutronix.de> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Uwe, On Mon, Mar 01, 2021 at 10:41:15PM +0100, Uwe Kleine-König wrote: > On Thu, Dec 17, 2020 at 12:10:10PM -0500, Sven Van Asbroeck wrote: > > On Thu, Dec 17, 2020 at 11:48 AM Clemens Gruber > > wrote: > > > > > > I can initialize the values to 0 of course and check the file for other > > > places with missing initializations. > > > > > > Or would it be better to check the return codes of regmap_read/write in > > > such cases? I'm not sure. > > > > I think that checking the regmap_read/write return values is overkill > > in this driver. These functions can't realistically fail, except if the i2c > > bus is bad, i.e. h/w failure or intermittency. And that's an externality > > which I believe we can ignore. > > > > Maybe Thierry or Uwe have further insights here. > > I'm a fan of full checking, but I'm not sure what's Thierry's position > on that. > > My reasoning is: If the bus is bad and a request to modify the PWM fails > because of that, the PWM consumer probably wants to know. I see. Then I'd suggest that we postpone adding these checks until we get a response from Thierry and if he agrees with you, we could add these checks in a separate patch series? Thanks, Clemens