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=-3.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS 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 85BF4C61DD8 for ; Sat, 14 Nov 2020 19:19:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4AE2522265 for ; Sat, 14 Nov 2020 19:19:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726384AbgKNTTi (ORCPT ); Sat, 14 Nov 2020 14:19:38 -0500 Received: from relay8-d.mail.gandi.net ([217.70.183.201]:59045 "EHLO relay8-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726287AbgKNTTi (ORCPT ); Sat, 14 Nov 2020 14:19:38 -0500 X-Originating-IP: 86.194.74.19 Received: from localhost (lfbn-lyo-1-997-19.w86-194.abo.wanadoo.fr [86.194.74.19]) (Authenticated sender: alexandre.belloni@bootlin.com) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id E4F291BF205; Sat, 14 Nov 2020 19:19:34 +0000 (UTC) Date: Sat, 14 Nov 2020 20:19:34 +0100 From: Alexandre Belloni To: Jonathan Cameron Cc: Lars-Peter Clausen , Peter Meerwald-Stadler , Nicolas Ferre , Ludovic Desroches , linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 5/9] iio: adc: at91_adc: merge at91_adc_probe_dt back in at91_adc_probe Message-ID: <20201114191934.GB5272@piout.net> References: <20201113212650.507680-1-alexandre.belloni@bootlin.com> <20201113212650.507680-6-alexandre.belloni@bootlin.com> <20201114170804.4b51c84b@archlinux> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201114170804.4b51c84b@archlinux> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 14/11/2020 17:08:04+0000, Jonathan Cameron wrote: > > - ret = at91_adc_probe_dt(idev, pdev); > > - if (ret) > > - return ret; > > + st->caps = (struct at91_adc_caps *) > > + of_match_device(at91_adc_dt_ids, &pdev->dev)->data; > > of_device_get match_data - obviously an unrelated change but trivial enough > I'd just slip it in this patch (unless you have it a later one!) > > That returns a void * so no need for the cast. > I guess I will change the next patch to use of_device_get_match_data as Andy doesn't like it when the fo_ and device_ APIs are mixed. > > + st->registers = &st->caps->registers; > > + st->num_channels = st->caps->num_channels; > > + > > + /* Check if touchscreen is supported. */ > > + if (st->caps->has_ts) { > > + ret = at91_adc_probe_dt_ts(node, st, &idev->dev); > > + if (ret) > > + return ret; > > + } > > > > platform_set_drvdata(pdev, idev); > > > > @@ -1091,7 +1072,6 @@ static int at91_adc_probe(struct platform_device *pdev) > > if (IS_ERR(st->reg_base)) > > return PTR_ERR(st->reg_base); > > > > - > Stray change that shouldn't be in this patch ideally but not that important. > I know I sneaked this one in but I didn't want to have that as a separate patch ;). I'll drop it. 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=-3.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,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 1EE3BC61DD8 for ; Sat, 14 Nov 2020 19:20:08 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C2BD22225E for ; Sat, 14 Nov 2020 19:20:07 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="d9mL2MDR" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C2BD22225E Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=bootlin.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=TATJpGNPYDRzOyh6fIc5B0JZa3ZY/8QxTX+fcQFp7Do=; b=d9mL2MDR3Im7XAgeYcBORTuVy bQsDWNLdNQqHVGpe+anm0ZbmkuNAW/rPQiT2jaCXRU4yACpKlzGUuLUl42GcW5TJ2gc5rLYjDhiB4 PHyCmOfl1cpyU6wFuugtjUZdmjBEIuox5RuufFnmu3iU80Zqvk0ov0PndpAMhi0JdGO06/AidiL3u KXrgkU4/qe8anUm28ioygf9VON0TAQizx01KxrJm4+VhYOWjphirCHt3BqqgfBcsS5zUJGnhtReGd meSm9evoaW7EuEFlSK6Ft30gD/Dg6HwwHZG0xyOByQlcJlEPwyaWMvWTWLQCmMhlyZU0VKU5upeFv 5yX8E5fHw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1ke15K-00026T-08; Sat, 14 Nov 2020 19:19:42 +0000 Received: from relay8-d.mail.gandi.net ([217.70.183.201]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1ke15G-000263-EX for linux-arm-kernel@lists.infradead.org; Sat, 14 Nov 2020 19:19:39 +0000 X-Originating-IP: 86.194.74.19 Received: from localhost (lfbn-lyo-1-997-19.w86-194.abo.wanadoo.fr [86.194.74.19]) (Authenticated sender: alexandre.belloni@bootlin.com) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id E4F291BF205; Sat, 14 Nov 2020 19:19:34 +0000 (UTC) Date: Sat, 14 Nov 2020 20:19:34 +0100 From: Alexandre Belloni To: Jonathan Cameron Subject: Re: [PATCH 5/9] iio: adc: at91_adc: merge at91_adc_probe_dt back in at91_adc_probe Message-ID: <20201114191934.GB5272@piout.net> References: <20201113212650.507680-1-alexandre.belloni@bootlin.com> <20201113212650.507680-6-alexandre.belloni@bootlin.com> <20201114170804.4b51c84b@archlinux> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20201114170804.4b51c84b@archlinux> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201114_141938_602990_58919AFB X-CRM114-Status: GOOD ( 18.03 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Lars-Peter Clausen , linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, Ludovic Desroches , Peter Meerwald-Stadler , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 14/11/2020 17:08:04+0000, Jonathan Cameron wrote: > > - ret = at91_adc_probe_dt(idev, pdev); > > - if (ret) > > - return ret; > > + st->caps = (struct at91_adc_caps *) > > + of_match_device(at91_adc_dt_ids, &pdev->dev)->data; > > of_device_get match_data - obviously an unrelated change but trivial enough > I'd just slip it in this patch (unless you have it a later one!) > > That returns a void * so no need for the cast. > I guess I will change the next patch to use of_device_get_match_data as Andy doesn't like it when the fo_ and device_ APIs are mixed. > > + st->registers = &st->caps->registers; > > + st->num_channels = st->caps->num_channels; > > + > > + /* Check if touchscreen is supported. */ > > + if (st->caps->has_ts) { > > + ret = at91_adc_probe_dt_ts(node, st, &idev->dev); > > + if (ret) > > + return ret; > > + } > > > > platform_set_drvdata(pdev, idev); > > > > @@ -1091,7 +1072,6 @@ static int at91_adc_probe(struct platform_device *pdev) > > if (IS_ERR(st->reg_base)) > > return PTR_ERR(st->reg_base); > > > > - > Stray change that shouldn't be in this patch ideally but not that important. > I know I sneaked this one in but I didn't want to have that as a separate patch ;). I'll drop it. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel