Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp2802626pxb; Tue, 13 Apr 2021 10:28:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJycpasRg/Zm9tGLQeutL2BxO8PFCipgArrq9T0ftTyXTiy3sVwMOEJpVvccovpZ79qR6sZ8 X-Received: by 2002:a17:906:bd2:: with SMTP id y18mr33614078ejg.482.1618334884098; Tue, 13 Apr 2021 10:28:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618334884; cv=none; d=google.com; s=arc-20160816; b=kbKjcTxLrhker4OUTNn9dxA1Jdq4pt+gWx4E3hdSh21G+UFZW8O4RdCcFgR3LpsaLZ aEgo40K7JQW2ZHl/ruIKDPxhXR5RkmfYDXFSSxiUE1cceWwzXJir6cVb1/FGFCyKE12f BsONBFQ38nJNiLi2RF+J4Qp43SGr30TF5AgJw86RsB8coH4GBw/XsFaWxKhRELtyi1W8 qNNkdx+QunietXXdX92btvq3CgVSVcdHEnfWWrWOmgIUMKDBARcoKjxpGU3NU/MyvraM 66sIxiqtEggSJjLWtZYDmV/qbZ5UUrXTOoYXiuzTaEAaRYsO+4kNy5N15JmOz0iNLVgr 4fOw== 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=ofMEg8rv+pKPXoMYWJfZuMSoaHQfPurW7rv78Elym1g=; b=c/e0GF9nT1IGXLfy/XVI28GKNx7QY7giDCt5puXLA6peikCQIqr72eodjjPEIdRw8F uL1p3RiAvdNkQzBN7yo1g5fgUxUH9kqWqTx+7TUfpXlYK0VXapw6KJESbc7DjBtZ/0uE xEH6miVVSazea6MhwDgFrCKRYLVlPvbw6a4xzeqZ9YX281CXy4bDpJ9I29mzVQWyhArp PyUgOLR4VMsS1nm9GcECeCi8zNFZ7kyopBIM66hP1Hh26C/MK4JNm+bvZkR7yvaRIzOD olqeLVRxA2tDmkL8FDqYxitkKdf/6Dd6ncuW1Shj+qog3wyR9+T8wCS6IliJzW/3Bh13 O5Xw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=T4ehIf9E; 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 k13si2489988ejg.416.2021.04.13.10.27.40; Tue, 13 Apr 2021 10:28:04 -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=T4ehIf9E; 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 S1343616AbhDMKoV (ORCPT + 99 others); Tue, 13 Apr 2021 06:44:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37502 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343609AbhDMKoS (ORCPT ); Tue, 13 Apr 2021 06:44:18 -0400 Received: from mail-yb1-xb2e.google.com (mail-yb1-xb2e.google.com [IPv6:2607:f8b0:4864:20::b2e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7A83EC061756 for ; Tue, 13 Apr 2021 03:43:59 -0700 (PDT) Received: by mail-yb1-xb2e.google.com with SMTP id c195so17599351ybf.9 for ; Tue, 13 Apr 2021 03:43:59 -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=ofMEg8rv+pKPXoMYWJfZuMSoaHQfPurW7rv78Elym1g=; b=T4ehIf9EYTEgcw6LNW7hIhfOrIYn21tK4+JDzP8gY0zjqewX2yID8aWTpK6Fw+gsIK YgpWOAdmzlajJxemylLiZaHR+eUGjC5DUvFFn2pHTAInVlUVBMl/Q0YaOcUc/ku4Jwtf 8ikiLmqHVecKPhTDqJXsD0VntQXoQyJUFdL6iMK7i2i8YxavNj1hjyA2ra/hCI6IeLOI BiLLbvTnQuGOXDvTyf6VrSlZtON6DhL5GifvpOZc4mi68htOtc4nKk2byBO0W11OuP4t kX7D2IomWQoOg1D9aIUWK96L1lg1BwXA6Nv01GnltBy8wNorb8HZApmwP3P9EErPVksQ Lr4g== 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=ofMEg8rv+pKPXoMYWJfZuMSoaHQfPurW7rv78Elym1g=; b=i++ZChZnKoQHFT21Z2nNel81R8z5uL+TImBbWhTTWAaTEvKpE3IlGisGYQYuCU+Ro4 ZxwktCSFECz0vfj+uajl2OjxtMMpFILeqTQxryo6F1zlYC6ZxhZYa/2QMwh759rRhFC+ PORaQF0p16YKqFxtgeqa8cNpwFdb8UaCHP5IBEcucGkX/Rg2f20pqdvq0/XSvn9j7tfz 9M+0eJOxuJk6RKSzSZjxvkLONQUVcw10f8bYvTUl2P0ZP1iPagIV+hUTpa/GlfTKrkQD Cm8Z3G+/g+yT+Kvlmylm7shmOY4R2s1SwP85CRGSqtgIDg8U01hkkh3boVBItEFd8R5k IRMg== X-Gm-Message-State: AOAM531DpezpA9rp2lOs2/dwVlQN7MVMEKzGBy2aZk5B8/mcvQEcwGG8 PstbOcdkvDKCA5TY41hsgomvJhnZCn+qOdq5/FQD5g== X-Received: by 2002:a25:ac52:: with SMTP id r18mr41442127ybd.25.1618310638808; Tue, 13 Apr 2021 03:43:58 -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: Tue, 13 Apr 2021 12:43:48 +0200 Message-ID: Subject: Re: [PATCH 1/3] gpio: zynq: use module_platform_driver to simplify the code To: Andy Shevchenko Cc: Srinivas Neeli , "linus.walleij@linaro.org" , "michal.simek@xilinx.com" , "shubhrajyoti.datta@xilinx.com" , "sgoud@xilinx.com" , "linux-gpio@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , "git@xilinx.com" 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 Sat, Apr 10, 2021 at 12:08 AM Andy Shevchenko wrote: > > > > On Friday, April 9, 2021, Srinivas Neeli wrot= e: >> >> 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_driver = =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? If no= , there is no go for this change. > Yep, this has been like this since the initial introduction of this driver. Unfortunately there's no documented reason so unless we can test it, it has to stay this way. Bartosz