Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp618241pxb; Fri, 16 Apr 2021 13:51:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz4NTfJsuAbtJd7Fam9MZirke81J97OlEcIUUzNIe3dlL6Fl7kLgJNBDgz6xKwWxOGZp78U X-Received: by 2002:a17:906:34da:: with SMTP id h26mr9954428ejb.496.1618606307362; Fri, 16 Apr 2021 13:51:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618606307; cv=none; d=google.com; s=arc-20160816; b=JmtTmu425jCqK121CHSOu/OV2lqk+nwvG4iMO6opDplEHFAduZ56GFZGC/Cm4bPBZb WslhkpOcVaFBWAsftNFxqZKV2HQ/dveceTb3DH16+MaKLIc9morHuVLPmoQ/7PMcb3id CyA/49zHZ9jpXxA6w9f4qwVjGuR8Adc4xRi6s9i9d3cnWmQZx37D+bONwySd0QLXImk8 5Qe/RlpngWkaWu3WFuP7AVbRY/MxUHOpEgqW+6LAw4LyE76JY/LL9hRlK0B0EfKqUNoM WqSfvTBYp50ECAL6SL21Pjl8Bhhy67s7CMK5BtUHP+2a+Sczrfqg1GR+yZd9QDlAjI2B A3GQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=qYdKrE1zIlOzfHp4IhnEDh/ZEjT1bfTnj4Cp18io3c8=; b=kyy5fYwthFnZncUlUEO5yUw+0QrX5BEDQMKO5EP5MyCb8eIFxrQpzCxjWoy8E0bOhZ cN81CoYd/40mpHdFXsC2jD+LStYyovxQuMVLc2ybdogFiwFtuQ2fBhc4oZilVV290ckK yQjGkDUajvyBe7WR2ikUaRl5yVJ+6ufCJd+Gjk3Y87j66OHoTiNAUiIDn+66KK816cz5 8xX8U5KMOZUS7hTpqRARvNBOxIGFLxvgxeLP+/NcSuB70yhebOM+CLDQMCZmtoqg4yVN oc0vRptxd8X9Ww8q2cij8L0Nw5Sf9PflaxwlRRrxgyJWCwitooxc+8qZEsbrHWr4XGRF fHag== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=M65GbMci; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j16si2531686edj.357.2021.04.16.13.51.18; Fri, 16 Apr 2021 13:51:47 -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=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=M65GbMci; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236387AbhDPS2a (ORCPT + 99 others); Fri, 16 Apr 2021 14:28:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40598 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236787AbhDPS23 (ORCPT ); Fri, 16 Apr 2021 14:28:29 -0400 Received: from mail-yb1-xb2a.google.com (mail-yb1-xb2a.google.com [IPv6:2607:f8b0:4864:20::b2a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4C366C061574 for ; Fri, 16 Apr 2021 11:28:04 -0700 (PDT) Received: by mail-yb1-xb2a.google.com with SMTP id k73so24845163ybf.3 for ; Fri, 16 Apr 2021 11:28:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=qYdKrE1zIlOzfHp4IhnEDh/ZEjT1bfTnj4Cp18io3c8=; b=M65GbMciF8c8P/jrTOmRILWpizSLmCME+Z4Bj8NWg6xvyStueQndmFwysQbWSPHrRI BjEkkH2TDS95ShyHY73w8d7AG1LO1fG4CgG/JrrQ4xzzltpjVsLdSnKwHzWgDqyNY/6H qB1xO8cKOMLw9eXd/cJfW4dI38SsJImq1sUGWSlJc7TZfn9OgwuVkvtOyHocxt/IbmuJ /mCKdTN+644aeLvacPlmYnrLPuJBtTxA04xmSPr7YoOjQNmHgKLbTUNO+Ohxw0qhNpNU QArIoFcYs5YdUluZSQVG+nYVLXbqUmBKSV+kgfDolZuuhzJa5cxpCWCDbuh6yUzUcQS0 CgQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=qYdKrE1zIlOzfHp4IhnEDh/ZEjT1bfTnj4Cp18io3c8=; b=IGP12O1pLRW+nuo2c8ciW9Ys6ui283OpcEEbMB7QTizgUa7qXLCd0q5s+p+tQuzNxG 1kjtw/Z4yH9dvZUyet0/kY8+n+T2ppijLS9lTX5okfBGR4ZiAAUJ8QcpfxZXse8K3grU TChrxizcRbmWF094CKmoe8TGo/0Zsjiwh4uafjJEs9UT+tHGZt3Ea7nw9rWYq15xBtR0 XpsMGAkeb01KHUVeFGUvLxwMyY239wqOcUyrtlc7Jpr27f+ejsyTjPumylUW9cxWEiYn Yez5xht4UowezfGKDyzRTkPp+fGjf5vCxVovlAilCvNnulfp/aFw4/vsR6sDhwJ5gkqB Goyw== X-Gm-Message-State: AOAM532sf68x0P8iEPr9kY+fPhTyckCixmBiGICyAI3qdvl0Tm/drhQw endPgd2hkKqxeAHFbO9U7hQ8eYjCVzPxCUJM7kdJoA== X-Received: by 2002:a25:7307:: with SMTP id o7mr581220ybc.469.1618597683618; Fri, 16 Apr 2021 11:28:03 -0700 (PDT) MIME-Version: 1.0 References: <20210409140806.31824-1-srinivas.neeli@xilinx.com> <20210409140806.31824-2-srinivas.neeli@xilinx.com> In-Reply-To: From: Bartosz Golaszewski Date: Fri, 16 Apr 2021 20:27:52 +0200 Message-ID: Subject: Re: [PATCH 1/3] gpio: zynq: use module_platform_driver to simplify the code To: Srinivas Neeli Cc: Andy Shevchenko , "linus.walleij@linaro.org" , Michal Simek , Shubhrajyoti Datta , Srinivas Goud , "linux-gpio@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , git Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 14, 2021 at 4:45 PM Srinivas Neeli wrote: > > HI baratosz and Andy, > It's Bartosz. You literally just need to copy & paste the name from my emai= l... > > -----Original Message----- > > From: Bartosz Golaszewski > > Sent: Tuesday, April 13, 2021 4:14 PM > > To: Andy Shevchenko > > Cc: Srinivas Neeli ; linus.walleij@linaro.org; Micha= l Simek > > ; Shubhrajyoti Datta ; Sriniva= s > > Goud ; linux-gpio@vger.kernel.org; linux-arm- > > kernel@lists.infradead.org; linux-kernel@vger.kernel.org; git > > > > Subject: Re: [PATCH 1/3] gpio: zynq: use module_platform_driver to simp= lify > > the code > > > > On Sat, Apr 10, 2021 at 12:08 AM Andy Shevchenko > > wrote: > > > > > > > > > > > > On Friday, April 9, 2021, Srinivas Neeli = wrote: > > >> > > >> module_platform_driver() makes the code simpler by eliminating > > >> boilerplate code. > > >> > > >> Signed-off-by: Srinivas Neeli > > >> --- > > >> drivers/gpio/gpio-zynq.c | 17 +---------------- > > >> 1 file changed, 1 insertion(+), 16 deletions(-) > > >> > > >> diff --git a/drivers/gpio/gpio-zynq.c b/drivers/gpio/gpio-zynq.c > > >> index 3521c1dc3ac0..bb1ac0c5cf26 100644 > > >> --- a/drivers/gpio/gpio-zynq.c > > >> +++ b/drivers/gpio/gpio-zynq.c > > >> @@ -1020,22 +1020,7 @@ static struct platform_driver zynq_gpio_drive= r > > =3D { > > >> .remove =3D zynq_gpio_remove, > > >> }; > > >> > > >> -/** > > >> - * zynq_gpio_init - Initial driver registration call > > >> - * > > >> - * Return: value from platform_driver_register > > >> - */ > > >> -static int __init zynq_gpio_init(void) -{ > > >> - return platform_driver_register(&zynq_gpio_driver); > > >> -} > > >> -postcore_initcall(zynq_gpio_init); > > > > > > > > > > > > It=E2=80=99s not an equivalent. Have you tested on actual hardware? I= f no, there is > > no go for this change. > > > > > > > Yep, this has been like this since the initial introduction of this dri= ver. > > Unfortunately there's no documented reason so unless we can test it, it= has > > to stay this way. > > > I tested driver, functionality wise everything working fine. > Based on below conversation, I moved driver to module driver. > https://lore.kernel.org/patchwork/patch/818202/ > Andy: How about we give it a try then? If anyone yells, we'll just revert i= t. > Thanks > Srinivas Neeli > > > Bartosz Bartosz