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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0AE7DC433FE for ; Tue, 19 Apr 2022 23:55:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1358534AbiDSX6i (ORCPT ); Tue, 19 Apr 2022 19:58:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45306 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1352109AbiDSX6g (ORCPT ); Tue, 19 Apr 2022 19:58:36 -0400 Received: from esa2.hgst.iphmx.com (esa2.hgst.iphmx.com [68.232.143.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9E01F1D323 for ; Tue, 19 Apr 2022 16:55:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1650412551; x=1681948551; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI7ADXChcU=; b=eOMVQ+cwwE9HVMUlo81oXXO+V1nQybzYC1RFCZc6mBeUffMXJ8OlvKTl nrA+YfPvnnhByF4WnE76sfstBwtTR9dlT3ZbNxAMDkwhjrqdYajUtnzkC Tt8Kh6bo2y3zBHPx13m5dVniC8h1uX2LpAVR+d3R8znKwUYsorhDTM+pR 5hindj1ewvWFGpHAkluWJhwhD3o6kAYLsL+edOvdKsdPNZY4Sf/TW1XPQ WlxpsMrxgA5anvgSF25/LGa4dezSV0Wuc+Hj6wWzhGnEros5ha/gvg4ou RYzsWu/MjXqj/YAE6pXTNKOquupZIfV/MOwduBMf0E2WPxMuVs/OIgfpf Q==; X-IronPort-AV: E=Sophos;i="5.90,274,1643644800"; d="scan'208";a="302502775" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 20 Apr 2022 07:55:49 +0800 IronPort-SDR: jbl4hWlDNzVH110RtMbpB1ex/benQBpTFhL3H4LVuZM9JhtktNJgQXsYBfJtxcExsMt0nRev1l 4kcTmpDF7mtTYiMT9fiGT7oDOgHZ7O9UviQOyHlQM2wdm9j1uOu4EalGyg4o9QwTggm+vASdhR yvM++eGjSrHyKXOsK6Pd8aaoE+ZtLe1e/Qw89737VuId4KHzqUdfnn1Bbe2fjiGTETjXfXoOhM 5R9xTJhAlBZ8mKJoMe36DgDhgEiH61kWkQRQgwXZhVeUmSp9HuZfAYAr9sPCkMBupMZc44xU8d h4rflb+bBSQDkS0wumfhi1SC Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:26:53 -0700 IronPort-SDR: 8FimgaXHderyeFoGiLiLEoILykqrQQV44LtS4hbjfcR7KM4v/YjIgjVTK0sOeEXW8V2x1yw1mV Tcn1dlt4y1nmJ80TV3xZZAiaFN7WmZAHzgJ5pYeyPgj1aLRvvZ8a+7A7un4AntKGAXIWUTaMUw EWiQqH4mvslLrhHhsQq+mlXwEliZMej2P6OloyjGmy5/NQDlK158ORKkp9rjy2HNzz7TGRyXL8 gck64J4GYc38GNiy55itbxh+DpI7QuK5+Cs2ATdubpyjb+4Ow9hn+MT/P4+3b3TfcYHu/DHXsG bRU= WDCIronportException: Internal Received: from usg-ed-osssrv.wdc.com ([10.3.10.180]) by uls-op-cesaip02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:55:49 -0700 Received: from usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTP id 4Kjgfr0B3nz1SVnx for ; Tue, 19 Apr 2022 16:55:47 -0700 (PDT) Authentication-Results: usg-ed-osssrv.wdc.com (amavisd-new); dkim=pass reason="pass (just generated, assumed good)" header.d=opensource.wdc.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d= opensource.wdc.com; h=content-transfer-encoding:content-type :in-reply-to:organization:from:references:to:content-language :subject:user-agent:mime-version:date:message-id; s=dkim; t= 1650412546; x=1653004547; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI 7ADXChcU=; b=LCqvtKdjRzDf5W/dOuU4+TSqtj4jJ6smpVH8RFQjhPvD0oWKSgK VNbKgZqe7cD95Wa4oWwwzQwFfFjHRTAt35h60/w1of/oOG9jfbrw4iqvuZS7dtTe aZtfiNytQfRTWGOEMs2tAcmlOzwo+vE0kys3+zkyflfi5RxJfbaxotJUsG4D0jJy WojFgUn199a5v964YoPbv5FCMw8NXqS+6upFcwqh5wpiQQtGpdju9BDzMHfoMB6A m60tmCvI2wmQoTXA6bLHrqCEivcB876f24T7gNJPXqdWy6pTqCQua5gzTqx0/f/H kRzjX0Tbt6TjZYydknqyZIUM109PRCFtLhg== X-Virus-Scanned: amavisd-new at usg-ed-osssrv.wdc.com Received: from usg-ed-osssrv.wdc.com ([127.0.0.1]) by usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id NOFLSg_ohRVc for ; Tue, 19 Apr 2022 16:55:46 -0700 (PDT) Received: from [10.225.163.14] (unknown [10.225.163.14]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTPSA id 4Kjgff0k5zz1Rvlx; Tue, 19 Apr 2022 16:55:37 -0700 (PDT) Message-ID: <56f889d7-2305-ba7a-42af-9580d8f7df93@opensource.wdc.com> Date: Wed, 20 Apr 2022 08:55:36 +0900 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH 13/48] ARM: pxa: use pdev resource for palmld mmio Content-Language: en-US To: Arnd Bergmann , robert.jarzmik@free.fr, linux-arm-kernel@lists.infradead.org Cc: Arnd Bergmann , Daniel Mack , Haojian Zhuang , Marek Vasut , Philipp Zabel , Lubomir Rintel , Paul Parsons , Tomas Cech , Sergey Lapin , Thomas Bogendoerfer , Michael Turquette , Stephen Boyd , "Rafael J. Wysocki" , Viresh Kumar , Dmitry Torokhov , Ulf Hansson , Dominik Brodowski , Helge Deller , Mark Brown , Linus Walleij , linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-ide@vger.kernel.org, linux-clk@vger.kernel.org, linux-pm@vger.kernel.org, linux-input@vger.kernel.org, patches@opensource.cirrus.com, linux-leds@vger.kernel.org, linux-mmc@vger.kernel.org, linux-mtd@lists.infradead.org, linux-rtc@vger.kernel.org, linux-usb@vger.kernel.org, linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, alsa-devel@alsa-project.org, Jens Axboe , Bartlomiej Zolnierkiewicz References: <20220419163810.2118169-1-arnd@kernel.org> <20220419163810.2118169-14-arnd@kernel.org> From: Damien Le Moal Organization: Western Digital Research In-Reply-To: <20220419163810.2118169-14-arnd@kernel.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-leds@vger.kernel.org On 4/20/22 01:37, Arnd Bergmann wrote: > From: Arnd Bergmann > > The palmld header is almost unused in drivers, the only > remaining thing now is the PATA device address, which should > really be passed as a resource. > > Cc: Jens Axboe > Cc: linux-ide@vger.kernel.org > Acked-by: Robert Jarzmik > Acked-by: Bartlomiej Zolnierkiewicz > Signed-off-by: Arnd Bergmann > --- > arch/arm/mach-pxa/palmld-pcmcia.c | 3 ++- > arch/arm/mach-pxa/palmld.c | 12 +++++++++--- > arch/arm/mach-pxa/{include/mach => }/palmld.h | 2 +- > drivers/ata/pata_palmld.c | 3 +-- > 4 files changed, 13 insertions(+), 7 deletions(-) > rename arch/arm/mach-pxa/{include/mach => }/palmld.h (98%) > > diff --git a/arch/arm/mach-pxa/palmld-pcmcia.c b/arch/arm/mach-pxa/palmld-pcmcia.c > index 07e0f7438db1..720294a50864 100644 > --- a/arch/arm/mach-pxa/palmld-pcmcia.c > +++ b/arch/arm/mach-pxa/palmld-pcmcia.c > @@ -13,9 +13,10 @@ > #include > > #include > -#include > #include > > +#include "palmld.h" > + > static struct gpio palmld_pcmcia_gpios[] = { > { GPIO_NR_PALMLD_PCMCIA_POWER, GPIOF_INIT_LOW, "PCMCIA Power" }, > { GPIO_NR_PALMLD_PCMCIA_RESET, GPIOF_INIT_HIGH,"PCMCIA Reset" }, > diff --git a/arch/arm/mach-pxa/palmld.c b/arch/arm/mach-pxa/palmld.c > index d85146957004..d821606ce0b5 100644 > --- a/arch/arm/mach-pxa/palmld.c > +++ b/arch/arm/mach-pxa/palmld.c > @@ -29,8 +29,8 @@ > #include > > #include "pxa27x.h" > +#include "palmld.h" > #include > -#include > #include > #include > #include > @@ -279,9 +279,15 @@ static inline void palmld_leds_init(void) {} > * HDD > ******************************************************************************/ > #if defined(CONFIG_PATA_PALMLD) || defined(CONFIG_PATA_PALMLD_MODULE) > +static struct resource palmld_ide_resources[] = { > + DEFINE_RES_MEM(PALMLD_IDE_PHYS, 0x1000), > +}; > + > static struct platform_device palmld_ide_device = { > - .name = "pata_palmld", > - .id = -1, > + .name = "pata_palmld", > + .id = -1, > + .resource = palmld_ide_resources, > + .num_resources = ARRAY_SIZE(palmld_ide_resources), > }; > > static struct gpiod_lookup_table palmld_ide_gpio_table = { > diff --git a/arch/arm/mach-pxa/include/mach/palmld.h b/arch/arm/mach-pxa/palmld.h > similarity index 98% > rename from arch/arm/mach-pxa/include/mach/palmld.h > rename to arch/arm/mach-pxa/palmld.h > index 99a6d8b3a1e3..ee3bc15b71a2 100644 > --- a/arch/arm/mach-pxa/include/mach/palmld.h > +++ b/arch/arm/mach-pxa/palmld.h > @@ -9,7 +9,7 @@ > #ifndef _INCLUDE_PALMLD_H_ > #define _INCLUDE_PALMLD_H_ > > -#include "irqs.h" /* PXA_GPIO_TO_IRQ */ > +#include /* PXA_GPIO_TO_IRQ */ > > /** HERE ARE GPIOs **/ > > diff --git a/drivers/ata/pata_palmld.c b/drivers/ata/pata_palmld.c > index 2448441571ed..400e65190904 100644 > --- a/drivers/ata/pata_palmld.c > +++ b/drivers/ata/pata_palmld.c > @@ -25,7 +25,6 @@ > #include > > #include > -#include > > #define DRV_NAME "pata_palmld" > > @@ -63,7 +62,7 @@ static int palmld_pata_probe(struct platform_device *pdev) > return -ENOMEM; > > /* remap drive's physical memory address */ > - mem = devm_ioremap(dev, PALMLD_IDE_PHYS, 0x1000); > + mem = devm_platform_ioremap_resource(pdev, 0); > if (!mem) > return -ENOMEM; > Acked-by: Damien Le Moal -- Damien Le Moal Western Digital Research 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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E76D8C433F5 for ; Tue, 19 Apr 2022 23:56:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:From:References:Cc:To: Subject:MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=rfVjdscLW8d6G3otC31+1GmNZ4zEO/93Z2CR/Bl3/jw=; b=TvWvrIcAIU4W30 R7BT9X2DgiwBcaPeh0pmE11gw/8LGSZxKv6az9aE4T/PD555jSjc3/R3BlupYx5VzEeqyMUMbKyyn F7/zrnZgoqFhmCDV6pDKgNCzO2/Z2n1wdruVVyMrutjpL0HoB4syvKq4yDwmxOtaT/kXDn0tLqVQJ FConTouLokr+7f7BQGtWDQBkb9IW2zDW0e7wGbND2gH8FA/gryR23MkQZKBwfOrA3fpyEJm8dKzk6 z+wisGBZwekoiKri0wQuq6y4unK8Jx/dC4oUHmrIHXBr81dDQFrOWg0EOus4qgKN89RLDeF9ZkKuK 1HHyk7MmhEH5rXZUh2pA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1ngxhW-006exM-Ex; Tue, 19 Apr 2022 23:56:06 +0000 Received: from esa4.hgst.iphmx.com ([216.71.154.42]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1ngxhK-006et6-Uw for linux-mtd@lists.infradead.org; Tue, 19 Apr 2022 23:55:56 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1650412554; x=1681948554; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI7ADXChcU=; b=nlP8evUJleG86JiixxmY1iosw5NyuHWWJQfr53LuNAM+m/pvBJCw2Y2/ 1e9B3rCcF8ZorQcJqWXq0CcTA/e7mwSH9lyuTHomNvPTvcq1LaLHaRnyJ aVxyYvs42TFm5+Hs+VCjO50el+J9IaRVoyrS4RKMJwaL75w6hhz6l9UCJ 4sL4HOOBBp7v7H/WXAuaitiKnLFWcgpO/VoGgE6Fw0uDFmg5LfdOS7P3t 1fnO+errga+1+PzOAKKDlh5ptp3C0z3psDlI1te/20E3ziKlowbApyPiG jvxRlfQrcz8LOa2sAuQPYkoyN0b14NVHd5761IPIV3MZejbhuG8OBQ3s6 Q==; X-IronPort-AV: E=Sophos;i="5.90,274,1643644800"; d="scan'208";a="197165484" Received: from h199-255-45-15.hgst.com (HELO uls-op-cesaep02.wdc.com) ([199.255.45.15]) by ob1.hgst.iphmx.com with ESMTP; 20 Apr 2022 07:55:50 +0800 IronPort-SDR: yiDpN8+bfxWzyKseLSkD4m9Y1KgeL+YdcBMtLLrzh2LbGcxIMogpX1GRBw/yKggPasT4yxjOa6 hti8PnGl16z85zpKcfsjBrRunQlPPkl3V6iNSHZEdGeJo+D3ab2Vt/sasT+Zi/XZieuMfnicBZ IgG3mvo9bvor7VcQMqHUn+qZDQm/KEQzrJc9fz1ODRNHFXa9gOoFWYqYjULyia+EHvMFF6dtmI b6fPQ4Bm3ctgvzBE1NkcTydj4dUWp/vDMqrDp3C8zsnO5bS0NkrV9Y6DRimAVnnWYd86O5Om2c z7n5Vua+41yF19TgjTqJtFCz Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:26:08 -0700 IronPort-SDR: TWqIinv/hAnOsQ0QJ1nzcNhdQ0bLz6z3lxl3KsrnLabZcmmmad5qneefooQy2wty8KZqg6xDjK +edB65gfetur174ytw3ZEzfzfPzn+CR216iFuQvWZ+q4okFzs7rzX1d2i5UdO/WZlE+MemCuX1 dvyF4kb5D0ayZVu4hrZMrf4JAiXWjARnDFNWuYxgD4EPk3xipt5ygjXRfs/4GhEucQph9P3oud er4wgwfvw2AGbURbtV3Ue+qFMvYYK1pJ8ET+RFqJcFeB4UphR301FxdcVWwbNflFVIozSyZOyM MVM= WDCIronportException: Internal Received: from usg-ed-osssrv.wdc.com ([10.3.10.180]) by uls-op-cesaip02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:55:50 -0700 Received: from usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTP id 4Kjgfs0yWSz1SVp0 for ; Tue, 19 Apr 2022 16:55:48 -0700 (PDT) Authentication-Results: usg-ed-osssrv.wdc.com (amavisd-new); dkim=pass reason="pass (just generated, assumed good)" header.d=opensource.wdc.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d= opensource.wdc.com; h=content-transfer-encoding:content-type :in-reply-to:organization:from:references:to:content-language :subject:user-agent:mime-version:date:message-id; s=dkim; t= 1650412547; x=1653004548; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI 7ADXChcU=; b=pFEW/uKhXn3SfKmBfD64EaWuvMe7q26hm0k6TE+sEECnehlEu2k JZAKUTdSLIdvQPzDDwtNqieDCFKd2/3AA3HEfr3lw+Tt7zTtPlgqTH805PaZ9XLD n2opLUpjSgtWeer+jG8ad83PPxpRHyOjx3VND3Khq7b+4tkh4xQ3tsW5cXs4Bj1u UKso+W9DyS/Uj+2QDbToc8oCKHbH/6ajijlj8CjOmKZM6k/TNCLhlNGRgLgQk8pd uNG6OCX78fB8zacum/KgbiC3Fm+jyvMirDIzk6aJ6Kmcj1OyXgl+Baraf9/cqoR6 86SqXEgXg9GFmxkX6LSna5otrW2oTbdEDwQ== X-Virus-Scanned: amavisd-new at usg-ed-osssrv.wdc.com Received: from usg-ed-osssrv.wdc.com ([127.0.0.1]) by usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id F5XGdKmRInct for ; Tue, 19 Apr 2022 16:55:47 -0700 (PDT) Received: from [10.225.163.14] (unknown [10.225.163.14]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTPSA id 4Kjgff0k5zz1Rvlx; Tue, 19 Apr 2022 16:55:37 -0700 (PDT) Message-ID: <56f889d7-2305-ba7a-42af-9580d8f7df93@opensource.wdc.com> Date: Wed, 20 Apr 2022 08:55:36 +0900 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH 13/48] ARM: pxa: use pdev resource for palmld mmio Content-Language: en-US To: Arnd Bergmann , robert.jarzmik@free.fr, linux-arm-kernel@lists.infradead.org Cc: Arnd Bergmann , Daniel Mack , Haojian Zhuang , Marek Vasut , Philipp Zabel , Lubomir Rintel , Paul Parsons , Tomas Cech , Sergey Lapin , Thomas Bogendoerfer , Michael Turquette , Stephen Boyd , "Rafael J. Wysocki" , Viresh Kumar , Dmitry Torokhov , Ulf Hansson , Dominik Brodowski , Helge Deller , Mark Brown , Linus Walleij , linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-ide@vger.kernel.org, linux-clk@vger.kernel.org, linux-pm@vger.kernel.org, linux-input@vger.kernel.org, patches@opensource.cirrus.com, linux-leds@vger.kernel.org, linux-mmc@vger.kernel.org, linux-mtd@lists.infradead.org, linux-rtc@vger.kernel.org, linux-usb@vger.kernel.org, linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, alsa-devel@alsa-project.org, Jens Axboe , Bartlomiej Zolnierkiewicz References: <20220419163810.2118169-1-arnd@kernel.org> <20220419163810.2118169-14-arnd@kernel.org> From: Damien Le Moal Organization: Western Digital Research In-Reply-To: <20220419163810.2118169-14-arnd@kernel.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220419_165555_068986_B93FEF48 X-CRM114-Status: GOOD ( 27.80 ) X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-mtd" Errors-To: linux-mtd-bounces+linux-mtd=archiver.kernel.org@lists.infradead.org On 4/20/22 01:37, Arnd Bergmann wrote: > From: Arnd Bergmann > > The palmld header is almost unused in drivers, the only > remaining thing now is the PATA device address, which should > really be passed as a resource. > > Cc: Jens Axboe > Cc: linux-ide@vger.kernel.org > Acked-by: Robert Jarzmik > Acked-by: Bartlomiej Zolnierkiewicz > Signed-off-by: Arnd Bergmann > --- > arch/arm/mach-pxa/palmld-pcmcia.c | 3 ++- > arch/arm/mach-pxa/palmld.c | 12 +++++++++--- > arch/arm/mach-pxa/{include/mach => }/palmld.h | 2 +- > drivers/ata/pata_palmld.c | 3 +-- > 4 files changed, 13 insertions(+), 7 deletions(-) > rename arch/arm/mach-pxa/{include/mach => }/palmld.h (98%) > > diff --git a/arch/arm/mach-pxa/palmld-pcmcia.c b/arch/arm/mach-pxa/palmld-pcmcia.c > index 07e0f7438db1..720294a50864 100644 > --- a/arch/arm/mach-pxa/palmld-pcmcia.c > +++ b/arch/arm/mach-pxa/palmld-pcmcia.c > @@ -13,9 +13,10 @@ > #include > > #include > -#include > #include > > +#include "palmld.h" > + > static struct gpio palmld_pcmcia_gpios[] = { > { GPIO_NR_PALMLD_PCMCIA_POWER, GPIOF_INIT_LOW, "PCMCIA Power" }, > { GPIO_NR_PALMLD_PCMCIA_RESET, GPIOF_INIT_HIGH,"PCMCIA Reset" }, > diff --git a/arch/arm/mach-pxa/palmld.c b/arch/arm/mach-pxa/palmld.c > index d85146957004..d821606ce0b5 100644 > --- a/arch/arm/mach-pxa/palmld.c > +++ b/arch/arm/mach-pxa/palmld.c > @@ -29,8 +29,8 @@ > #include > > #include "pxa27x.h" > +#include "palmld.h" > #include > -#include > #include > #include > #include > @@ -279,9 +279,15 @@ static inline void palmld_leds_init(void) {} > * HDD > ******************************************************************************/ > #if defined(CONFIG_PATA_PALMLD) || defined(CONFIG_PATA_PALMLD_MODULE) > +static struct resource palmld_ide_resources[] = { > + DEFINE_RES_MEM(PALMLD_IDE_PHYS, 0x1000), > +}; > + > static struct platform_device palmld_ide_device = { > - .name = "pata_palmld", > - .id = -1, > + .name = "pata_palmld", > + .id = -1, > + .resource = palmld_ide_resources, > + .num_resources = ARRAY_SIZE(palmld_ide_resources), > }; > > static struct gpiod_lookup_table palmld_ide_gpio_table = { > diff --git a/arch/arm/mach-pxa/include/mach/palmld.h b/arch/arm/mach-pxa/palmld.h > similarity index 98% > rename from arch/arm/mach-pxa/include/mach/palmld.h > rename to arch/arm/mach-pxa/palmld.h > index 99a6d8b3a1e3..ee3bc15b71a2 100644 > --- a/arch/arm/mach-pxa/include/mach/palmld.h > +++ b/arch/arm/mach-pxa/palmld.h > @@ -9,7 +9,7 @@ > #ifndef _INCLUDE_PALMLD_H_ > #define _INCLUDE_PALMLD_H_ > > -#include "irqs.h" /* PXA_GPIO_TO_IRQ */ > +#include /* PXA_GPIO_TO_IRQ */ > > /** HERE ARE GPIOs **/ > > diff --git a/drivers/ata/pata_palmld.c b/drivers/ata/pata_palmld.c > index 2448441571ed..400e65190904 100644 > --- a/drivers/ata/pata_palmld.c > +++ b/drivers/ata/pata_palmld.c > @@ -25,7 +25,6 @@ > #include > > #include > -#include > > #define DRV_NAME "pata_palmld" > > @@ -63,7 +62,7 @@ static int palmld_pata_probe(struct platform_device *pdev) > return -ENOMEM; > > /* remap drive's physical memory address */ > - mem = devm_ioremap(dev, PALMLD_IDE_PHYS, 0x1000); > + mem = devm_platform_ioremap_resource(pdev, 0); > if (!mem) > return -ENOMEM; > Acked-by: Damien Le Moal -- Damien Le Moal Western Digital Research ______________________________________________________ Linux MTD discussion mailing list http://lists.infradead.org/mailman/listinfo/linux-mtd/ 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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B0BC6C433EF for ; Tue, 19 Apr 2022 23:57:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:From:References:Cc:To: Subject:MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=0LFVfxkdSH0EgD1nq0omsQGFTjiCrdZsXy0+snOfIOU=; b=lMnm7NsmeVkZcA qbuXZkuzkeFNeT5ZDwh574VHBcQo3KHBqm3y+vcu6O82rKZVOqg/g4Wp+bM3oW93XQyzW3wUEVam0 hn4hiSuvMopv4awBa4M+u4KLfldkxyYkkkbC2MtnQm8UHRmUB3OBEedP4qJuO790TMehCZJWQb1I/ KyE/R1B4cgF0G5kYVTy1gT+7wJdQ6q5SivF5j+tWCCFaxry2bxQ06LgckAS+pYfTV7AMlzOOxuYZf pj4mXxpqhKVkAWY9jhBF+jyJTTq8adaxylQczpivcWZhOc2TgvlAvuP/mvJLWBLDru0byc74vABu7 m0D2rg5BAZVT90jnoKBg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1ngxhM-006euD-Qw; Tue, 19 Apr 2022 23:55:57 +0000 Received: from esa4.hgst.iphmx.com ([216.71.154.42]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1ngxhI-006et6-8q for linux-arm-kernel@lists.infradead.org; Tue, 19 Apr 2022 23:55:54 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1650412552; x=1681948552; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI7ADXChcU=; b=nWTqx1ztrGlNWIrpiha6K8WdQyClz2j3o2OetN2CN/x1ItqXjRoiINYc +8H7OMKxRHHsKLnaHO8hiZGlSt6M76RdI3BZn8/Tuj6EyYomKlvcszW4v Ny+iXg7IDiZcRhvURjvQejo7jttQSeoqxTuheqmF5QdolSW8ayXjUFfAU l0P8lKJGR2vh3ZJ/++km8tUEx75j7XiSC81EhI9+Je7SRRYMrJBcYnGSg UFcWOe4Q/H7NsgDIOSF6XoURETG11ficKHx9hT1VxEitn3s+XMqA5KudO tg9fHp64TwgQBcj9NCD+Wp9Gbx23sOZ8JnZASv+KghQl8vBBCkcBwtAJg w==; X-IronPort-AV: E=Sophos;i="5.90,274,1643644800"; d="scan'208";a="197165481" Received: from h199-255-45-15.hgst.com (HELO uls-op-cesaep02.wdc.com) ([199.255.45.15]) by ob1.hgst.iphmx.com with ESMTP; 20 Apr 2022 07:55:48 +0800 IronPort-SDR: JAALlVAnbnEHVzadAP1ErjSylHahFt/go5WAoA82df7U1vg8ti4D8Q4dbnzmaLBibfr2TP9OiN iJOPX7gyr0uhruXpHP523Irls4eUIaXQxLW+pVHtmIsm4cdU/X4SOL6LWURZ0Rxe7QGOnLe7HF 5urvcmaM/9wzGfQMPFqqNJ3j2kaJsO27NeFJs9obZI8ZluuokJVMIoVzJchSAIsgZtz1scCmaw JjWytdlS0tERRBgxMNe/gZf1AD0FMmiZanNk0btaZlgVgnYmkj1tHRXEE9858389hUlPGUC/XL hVq+a79j3eMw4oJFbMRKW1u9 Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:26:06 -0700 IronPort-SDR: BbeErqSdUW/C0ylBJjYld+O31BFN/EdYattgRqVQEz1izGzjByIzPsoEPhbtM6mOzkn3/mCmQN 5+3W0XD1aOy1vlTAId2rUCzSu4ZhiMe1cNqkP2BnFXbFkMKzlRLjuP1Gk6MSkxdRxAZTyR2cSi KY1cXMjud+iJA9QSRevNnwO5ze+avOa7q/GG7fpv+HZCUMMSAlGKANYQBmPYhtJi+8ds/H7E9h AdjsAcolhAutE2O2RctUs+Nonv75gipEmU0ZM1zkYO+Mlz4bvd5JmJ44wpT4j8jJngqjdhzKel QVc= WDCIronportException: Internal Received: from usg-ed-osssrv.wdc.com ([10.3.10.180]) by uls-op-cesaip02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:55:49 -0700 Received: from usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTP id 4Kjgfq32YCz1SVp6 for ; Tue, 19 Apr 2022 16:55:47 -0700 (PDT) Authentication-Results: usg-ed-osssrv.wdc.com (amavisd-new); dkim=pass reason="pass (just generated, assumed good)" header.d=opensource.wdc.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d= opensource.wdc.com; h=content-transfer-encoding:content-type :in-reply-to:organization:from:references:to:content-language :subject:user-agent:mime-version:date:message-id; s=dkim; t= 1650412545; x=1653004546; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI 7ADXChcU=; b=Gje5dk49/9BmoXlrB11e2kUHh41ueudCSVCsAiP2b9/ibtju/LW 8VFyO6z1D/5qzGU4UZXVjYhZf+2uSdKIbBRvgr9vWs8kSiRiKRrWDP6gES1QIax4 bcOW6uZrv7RJwpXEGJdssZeqKsmHPDoe5MPUfstlMpI/WQMf+ltBYbC9l/7EVs6/ f+3crzqxV7ZKaxrV8JvLhAJmTSb9mwA7/jJ7IdY3UxKPCi9HzLo7uroW3Glowg2q zxcAlBpUnI4UyUYWfV01j4KY7jJz5nLqqnZVkYzfyl9WzxKDGlBY4mWxyUQhqzxV yfOq6tFWSw4gK7RPMjKHdp0RYdLBYbBmI7A== X-Virus-Scanned: amavisd-new at usg-ed-osssrv.wdc.com Received: from usg-ed-osssrv.wdc.com ([127.0.0.1]) by usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id bvEbm1bV49ri for ; Tue, 19 Apr 2022 16:55:45 -0700 (PDT) Received: from [10.225.163.14] (unknown [10.225.163.14]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTPSA id 4Kjgff0k5zz1Rvlx; Tue, 19 Apr 2022 16:55:37 -0700 (PDT) Message-ID: <56f889d7-2305-ba7a-42af-9580d8f7df93@opensource.wdc.com> Date: Wed, 20 Apr 2022 08:55:36 +0900 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH 13/48] ARM: pxa: use pdev resource for palmld mmio Content-Language: en-US To: Arnd Bergmann , robert.jarzmik@free.fr, linux-arm-kernel@lists.infradead.org Cc: Arnd Bergmann , Daniel Mack , Haojian Zhuang , Marek Vasut , Philipp Zabel , Lubomir Rintel , Paul Parsons , Tomas Cech , Sergey Lapin , Thomas Bogendoerfer , Michael Turquette , Stephen Boyd , "Rafael J. Wysocki" , Viresh Kumar , Dmitry Torokhov , Ulf Hansson , Dominik Brodowski , Helge Deller , Mark Brown , Linus Walleij , linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-ide@vger.kernel.org, linux-clk@vger.kernel.org, linux-pm@vger.kernel.org, linux-input@vger.kernel.org, patches@opensource.cirrus.com, linux-leds@vger.kernel.org, linux-mmc@vger.kernel.org, linux-mtd@lists.infradead.org, linux-rtc@vger.kernel.org, linux-usb@vger.kernel.org, linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, alsa-devel@alsa-project.org, Jens Axboe , Bartlomiej Zolnierkiewicz References: <20220419163810.2118169-1-arnd@kernel.org> <20220419163810.2118169-14-arnd@kernel.org> From: Damien Le Moal Organization: Western Digital Research In-Reply-To: <20220419163810.2118169-14-arnd@kernel.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220419_165552_610872_0609320A X-CRM114-Status: GOOD ( 28.39 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , 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 4/20/22 01:37, Arnd Bergmann wrote: > From: Arnd Bergmann > > The palmld header is almost unused in drivers, the only > remaining thing now is the PATA device address, which should > really be passed as a resource. > > Cc: Jens Axboe > Cc: linux-ide@vger.kernel.org > Acked-by: Robert Jarzmik > Acked-by: Bartlomiej Zolnierkiewicz > Signed-off-by: Arnd Bergmann > --- > arch/arm/mach-pxa/palmld-pcmcia.c | 3 ++- > arch/arm/mach-pxa/palmld.c | 12 +++++++++--- > arch/arm/mach-pxa/{include/mach => }/palmld.h | 2 +- > drivers/ata/pata_palmld.c | 3 +-- > 4 files changed, 13 insertions(+), 7 deletions(-) > rename arch/arm/mach-pxa/{include/mach => }/palmld.h (98%) > > diff --git a/arch/arm/mach-pxa/palmld-pcmcia.c b/arch/arm/mach-pxa/palmld-pcmcia.c > index 07e0f7438db1..720294a50864 100644 > --- a/arch/arm/mach-pxa/palmld-pcmcia.c > +++ b/arch/arm/mach-pxa/palmld-pcmcia.c > @@ -13,9 +13,10 @@ > #include > > #include > -#include > #include > > +#include "palmld.h" > + > static struct gpio palmld_pcmcia_gpios[] = { > { GPIO_NR_PALMLD_PCMCIA_POWER, GPIOF_INIT_LOW, "PCMCIA Power" }, > { GPIO_NR_PALMLD_PCMCIA_RESET, GPIOF_INIT_HIGH,"PCMCIA Reset" }, > diff --git a/arch/arm/mach-pxa/palmld.c b/arch/arm/mach-pxa/palmld.c > index d85146957004..d821606ce0b5 100644 > --- a/arch/arm/mach-pxa/palmld.c > +++ b/arch/arm/mach-pxa/palmld.c > @@ -29,8 +29,8 @@ > #include > > #include "pxa27x.h" > +#include "palmld.h" > #include > -#include > #include > #include > #include > @@ -279,9 +279,15 @@ static inline void palmld_leds_init(void) {} > * HDD > ******************************************************************************/ > #if defined(CONFIG_PATA_PALMLD) || defined(CONFIG_PATA_PALMLD_MODULE) > +static struct resource palmld_ide_resources[] = { > + DEFINE_RES_MEM(PALMLD_IDE_PHYS, 0x1000), > +}; > + > static struct platform_device palmld_ide_device = { > - .name = "pata_palmld", > - .id = -1, > + .name = "pata_palmld", > + .id = -1, > + .resource = palmld_ide_resources, > + .num_resources = ARRAY_SIZE(palmld_ide_resources), > }; > > static struct gpiod_lookup_table palmld_ide_gpio_table = { > diff --git a/arch/arm/mach-pxa/include/mach/palmld.h b/arch/arm/mach-pxa/palmld.h > similarity index 98% > rename from arch/arm/mach-pxa/include/mach/palmld.h > rename to arch/arm/mach-pxa/palmld.h > index 99a6d8b3a1e3..ee3bc15b71a2 100644 > --- a/arch/arm/mach-pxa/include/mach/palmld.h > +++ b/arch/arm/mach-pxa/palmld.h > @@ -9,7 +9,7 @@ > #ifndef _INCLUDE_PALMLD_H_ > #define _INCLUDE_PALMLD_H_ > > -#include "irqs.h" /* PXA_GPIO_TO_IRQ */ > +#include /* PXA_GPIO_TO_IRQ */ > > /** HERE ARE GPIOs **/ > > diff --git a/drivers/ata/pata_palmld.c b/drivers/ata/pata_palmld.c > index 2448441571ed..400e65190904 100644 > --- a/drivers/ata/pata_palmld.c > +++ b/drivers/ata/pata_palmld.c > @@ -25,7 +25,6 @@ > #include > > #include > -#include > > #define DRV_NAME "pata_palmld" > > @@ -63,7 +62,7 @@ static int palmld_pata_probe(struct platform_device *pdev) > return -ENOMEM; > > /* remap drive's physical memory address */ > - mem = devm_ioremap(dev, PALMLD_IDE_PHYS, 0x1000); > + mem = devm_platform_ioremap_resource(pdev, 0); > if (!mem) > return -ENOMEM; > Acked-by: Damien Le Moal -- Damien Le Moal Western Digital Research _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel 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 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 644F0C433F5 for ; Wed, 20 Apr 2022 07:42:05 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7FBF510F08A; Wed, 20 Apr 2022 07:42:01 +0000 (UTC) X-Greylist: delayed 426 seconds by postgrey-1.36 at gabe; Wed, 20 Apr 2022 00:02:55 UTC Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1C99810E133 for ; Wed, 20 Apr 2022 00:02:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1650412973; x=1681948973; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI7ADXChcU=; b=NQm964W6ua3XM+2gFiNAtndVGJ94N3vO62HTZ5t9hFxzQpnqcf+R/lup O1ZX/ERPsswDTJtggTr0WQY9iMETquF9V+jhC2dhH37Ek0VK1X3JYlkST 2w9GEWX+QTC5k09ptlqf1KhDb0QNZGPefckaS/10ekh48pF7X3e0Mbq+h BgupWtvofgjnqprllCTuYIifkaJzp0+R4Xe71W0kXkDRDFrTVcU+tfOeN /KOQYJS17ahCANSgAH2dhSikLNR9+gauFJXeIIVfBH/fBxxN+KOtdqn7w Vs+nqJqlyS8eOo61el0dpvEvQ0AyFomlwK1QlvJls7N9UDKjYOqTuTY6d A==; X-IronPort-AV: E=Sophos;i="5.90,274,1643644800"; d="scan'208";a="203172683" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 20 Apr 2022 07:55:47 +0800 IronPort-SDR: 4OoCYQrEHQJlXRdR19KWOOzWw6QJQwr7YxPduyT1kNxNQ00WYUxtuN1kB6nfxh7KxVB3qSPcIv 3JpsbKmoTGAkCYaqyPUc9kbpK3YYGa1tkd3X5fhAMBZUgH3MlMdnCN5EGW0BtT8/oaLyym0XRw We6H3V8a1kToIspOCQ7o8TRv+P2ocKm2guYvp7iv/t8c84GkH1ehsNuqw4/ZaOEAvv4bnYWdXT qIDmZtI6jQ7AatJTITITqhYSO2Y7UZ5pcsQhhVgGQAcRX6Egjm9yrEQOzwzfOwXlbXRVjxebXY sGC43U09FBtAZTIwV2RK3OMU Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:26:53 -0700 IronPort-SDR: NPAqJBV15sf9LAkapTJlHLL8YL7v7e3hEZxmPJNZpxwxeMORWe4Y2yuQdZnXj4SgU8uiGC8I/X sjiyYCsevaCv6oOYQnMixICpyEOtWaWhpwo8CsxAFG5YpiMfKEHw0e3gSLwli4ZzZAEXLug9OI t4Cf+NiVWkWNdyFTGXZ6p5qLfQDTKH2ccf/7kZ7aIYPKMunNgZzUAgjqebAduzYKTUonCZdOkn bfUNqGkJ8kVb4EB5tvlHJHuivkf46AsYJMXFMpVZ3w02lioNDWmq4Ejs3ek0raFyTWMg46gweN pkw= WDCIronportException: Internal Received: from usg-ed-osssrv.wdc.com ([10.3.10.180]) by uls-op-cesaip02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:55:49 -0700 Received: from usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTP id 4Kjgfq353cz1SVp7 for ; Tue, 19 Apr 2022 16:55:46 -0700 (PDT) Authentication-Results: usg-ed-osssrv.wdc.com (amavisd-new); dkim=pass reason="pass (just generated, assumed good)" header.d=opensource.wdc.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d= opensource.wdc.com; h=content-transfer-encoding:content-type :in-reply-to:organization:from:references:to:content-language :subject:user-agent:mime-version:date:message-id; s=dkim; t= 1650412545; x=1653004546; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI 7ADXChcU=; b=Gje5dk49/9BmoXlrB11e2kUHh41ueudCSVCsAiP2b9/ibtju/LW 8VFyO6z1D/5qzGU4UZXVjYhZf+2uSdKIbBRvgr9vWs8kSiRiKRrWDP6gES1QIax4 bcOW6uZrv7RJwpXEGJdssZeqKsmHPDoe5MPUfstlMpI/WQMf+ltBYbC9l/7EVs6/ f+3crzqxV7ZKaxrV8JvLhAJmTSb9mwA7/jJ7IdY3UxKPCi9HzLo7uroW3Glowg2q zxcAlBpUnI4UyUYWfV01j4KY7jJz5nLqqnZVkYzfyl9WzxKDGlBY4mWxyUQhqzxV yfOq6tFWSw4gK7RPMjKHdp0RYdLBYbBmI7A== X-Virus-Scanned: amavisd-new at usg-ed-osssrv.wdc.com Received: from usg-ed-osssrv.wdc.com ([127.0.0.1]) by usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id iK2osX7lOgjD for ; Tue, 19 Apr 2022 16:55:45 -0700 (PDT) Received: from [10.225.163.14] (unknown [10.225.163.14]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTPSA id 4Kjgff0k5zz1Rvlx; Tue, 19 Apr 2022 16:55:37 -0700 (PDT) Message-ID: <56f889d7-2305-ba7a-42af-9580d8f7df93@opensource.wdc.com> Date: Wed, 20 Apr 2022 08:55:36 +0900 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH 13/48] ARM: pxa: use pdev resource for palmld mmio Content-Language: en-US To: Arnd Bergmann , robert.jarzmik@free.fr, linux-arm-kernel@lists.infradead.org References: <20220419163810.2118169-1-arnd@kernel.org> <20220419163810.2118169-14-arnd@kernel.org> From: Damien Le Moal Organization: Western Digital Research In-Reply-To: <20220419163810.2118169-14-arnd@kernel.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Wed, 20 Apr 2022 07:42:00 +0000 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ulf Hansson , linux-usb@vger.kernel.org, "Rafael J. Wysocki" , Viresh Kumar , linux-fbdev@vger.kernel.org, Dominik Brodowski , linux-mips@vger.kernel.org, linux-ide@vger.kernel.org, linux-mtd@lists.infradead.org, Tomas Cech , linux-clk@vger.kernel.org, linux-leds@vger.kernel.org, linux-rtc@vger.kernel.org, Helge Deller , Bartlomiej Zolnierkiewicz , Marek Vasut , Paul Parsons , Sergey Lapin , Arnd Bergmann , linux-pm@vger.kernel.org, linux-input@vger.kernel.org, Haojian Zhuang , Lubomir Rintel , Mark Brown , dri-devel@lists.freedesktop.org, Jens Axboe , Thomas Bogendoerfer , Stephen Boyd , patches@opensource.cirrus.com, Dmitry Torokhov , linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org, Michael Turquette , alsa-devel@alsa-project.org, Daniel Mack Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" On 4/20/22 01:37, Arnd Bergmann wrote: > From: Arnd Bergmann > > The palmld header is almost unused in drivers, the only > remaining thing now is the PATA device address, which should > really be passed as a resource. > > Cc: Jens Axboe > Cc: linux-ide@vger.kernel.org > Acked-by: Robert Jarzmik > Acked-by: Bartlomiej Zolnierkiewicz > Signed-off-by: Arnd Bergmann > --- > arch/arm/mach-pxa/palmld-pcmcia.c | 3 ++- > arch/arm/mach-pxa/palmld.c | 12 +++++++++--- > arch/arm/mach-pxa/{include/mach => }/palmld.h | 2 +- > drivers/ata/pata_palmld.c | 3 +-- > 4 files changed, 13 insertions(+), 7 deletions(-) > rename arch/arm/mach-pxa/{include/mach => }/palmld.h (98%) > > diff --git a/arch/arm/mach-pxa/palmld-pcmcia.c b/arch/arm/mach-pxa/palmld-pcmcia.c > index 07e0f7438db1..720294a50864 100644 > --- a/arch/arm/mach-pxa/palmld-pcmcia.c > +++ b/arch/arm/mach-pxa/palmld-pcmcia.c > @@ -13,9 +13,10 @@ > #include > > #include > -#include > #include > > +#include "palmld.h" > + > static struct gpio palmld_pcmcia_gpios[] = { > { GPIO_NR_PALMLD_PCMCIA_POWER, GPIOF_INIT_LOW, "PCMCIA Power" }, > { GPIO_NR_PALMLD_PCMCIA_RESET, GPIOF_INIT_HIGH,"PCMCIA Reset" }, > diff --git a/arch/arm/mach-pxa/palmld.c b/arch/arm/mach-pxa/palmld.c > index d85146957004..d821606ce0b5 100644 > --- a/arch/arm/mach-pxa/palmld.c > +++ b/arch/arm/mach-pxa/palmld.c > @@ -29,8 +29,8 @@ > #include > > #include "pxa27x.h" > +#include "palmld.h" > #include > -#include > #include > #include > #include > @@ -279,9 +279,15 @@ static inline void palmld_leds_init(void) {} > * HDD > ******************************************************************************/ > #if defined(CONFIG_PATA_PALMLD) || defined(CONFIG_PATA_PALMLD_MODULE) > +static struct resource palmld_ide_resources[] = { > + DEFINE_RES_MEM(PALMLD_IDE_PHYS, 0x1000), > +}; > + > static struct platform_device palmld_ide_device = { > - .name = "pata_palmld", > - .id = -1, > + .name = "pata_palmld", > + .id = -1, > + .resource = palmld_ide_resources, > + .num_resources = ARRAY_SIZE(palmld_ide_resources), > }; > > static struct gpiod_lookup_table palmld_ide_gpio_table = { > diff --git a/arch/arm/mach-pxa/include/mach/palmld.h b/arch/arm/mach-pxa/palmld.h > similarity index 98% > rename from arch/arm/mach-pxa/include/mach/palmld.h > rename to arch/arm/mach-pxa/palmld.h > index 99a6d8b3a1e3..ee3bc15b71a2 100644 > --- a/arch/arm/mach-pxa/include/mach/palmld.h > +++ b/arch/arm/mach-pxa/palmld.h > @@ -9,7 +9,7 @@ > #ifndef _INCLUDE_PALMLD_H_ > #define _INCLUDE_PALMLD_H_ > > -#include "irqs.h" /* PXA_GPIO_TO_IRQ */ > +#include /* PXA_GPIO_TO_IRQ */ > > /** HERE ARE GPIOs **/ > > diff --git a/drivers/ata/pata_palmld.c b/drivers/ata/pata_palmld.c > index 2448441571ed..400e65190904 100644 > --- a/drivers/ata/pata_palmld.c > +++ b/drivers/ata/pata_palmld.c > @@ -25,7 +25,6 @@ > #include > > #include > -#include > > #define DRV_NAME "pata_palmld" > > @@ -63,7 +62,7 @@ static int palmld_pata_probe(struct platform_device *pdev) > return -ENOMEM; > > /* remap drive's physical memory address */ > - mem = devm_ioremap(dev, PALMLD_IDE_PHYS, 0x1000); > + mem = devm_platform_ioremap_resource(pdev, 0); > if (!mem) > return -ENOMEM; > Acked-by: Damien Le Moal -- Damien Le Moal Western Digital Research 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 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 010F4C433F5 for ; Fri, 22 Apr 2022 13:50:16 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 783ED1654; Fri, 22 Apr 2022 15:49:25 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 783ED1654 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1650635415; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI7ADXChcU=; h=Date:Subject:To:References:From:In-Reply-To:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=upiOGfnkj4yT0Z4cqUEvwCP9sew3G/dTqqr4hKVtz5j4vvt0poMEDRX0E3AjrvbMi DfYHZoqwYHRM25uKcZluQSOGEzEB460EH3PdonyndEjhCjsvrzHdfw/NF8bNVHhEzJ Tzo0/vH021yrAEoFRo78vlidoO3vPzCrBEu2HkUU= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id EDBD5F80806; Fri, 22 Apr 2022 15:32:35 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 904D5F8025D; Wed, 20 Apr 2022 01:55:57 +0200 (CEST) Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 5B7DEF800C1 for ; Wed, 20 Apr 2022 01:55:49 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 5B7DEF800C1 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="eOMVQ+cw"; dkim=pass (2048-bit key) header.d=opensource.wdc.com header.i=@opensource.wdc.com header.b="nblcqlKO" DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1650412551; x=1681948551; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI7ADXChcU=; b=eOMVQ+cwwE9HVMUlo81oXXO+V1nQybzYC1RFCZc6mBeUffMXJ8OlvKTl nrA+YfPvnnhByF4WnE76sfstBwtTR9dlT3ZbNxAMDkwhjrqdYajUtnzkC Tt8Kh6bo2y3zBHPx13m5dVniC8h1uX2LpAVR+d3R8znKwUYsorhDTM+pR 5hindj1ewvWFGpHAkluWJhwhD3o6kAYLsL+edOvdKsdPNZY4Sf/TW1XPQ WlxpsMrxgA5anvgSF25/LGa4dezSV0Wuc+Hj6wWzhGnEros5ha/gvg4ou RYzsWu/MjXqj/YAE6pXTNKOquupZIfV/MOwduBMf0E2WPxMuVs/OIgfpf Q==; X-IronPort-AV: E=Sophos;i="5.90,274,1643644800"; d="scan'208";a="203172679" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 20 Apr 2022 07:55:46 +0800 IronPort-SDR: CRKsPpWO1KMcpIDlEp3ybxn0eINP2wyHcgLeMq2fZ2gHhmdjpb3EcbdWolSXys0DUQuYy/g+Fv PS0ByAdvp9jwcw4JqRRgI5igELTRW4YjGisxJkKmtYTr65pDt31d5NQDJ2lSzZh/RkRKdjm0Gc F9KWym6pUWdJLX+YGCumyUifjJx/ENRbpbAjs9W/srH8MByVWJ89xKpdcO9vl0Oey+rHjezTQm oEkYjDgAY26C/AVD/4uCwyQTvJet+p7kGNigleGO0bPkx0jpHdf/GWiObrq9pnhYyP+xwugGu6 3gVEJ1AkF1bVCGWOORNhPKei Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:26:51 -0700 IronPort-SDR: wHbFnT8BqxoH51NFqQiAjwWfniqliuANOWnPBT8i6QiPfQcbNnSEPEmtBYLglpCNl8ahVjLP4k PjD6tF0pu6CDAJIbNaqpLa+rqwT4w7Mbj7oNE2f3Foe2vRf1Rq1uI3VmuLakCzNfhcyxybfrgL nNU6ZN/AnbesbW+CmFMi20ktHdUx+2QfjPGwWXLklqmPs06llSRXaXUwxIGoKOidT5rGJtH1o7 qcgw3JJF1PI1FA2itKemFwm8Fx6DkztyZAfP2m6xT+gXeJw+8vBQA5Ynifmw1hDhelDU1Mys5V MrM= WDCIronportException: Internal Received: from usg-ed-osssrv.wdc.com ([10.3.10.180]) by uls-op-cesaip02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 19 Apr 2022 16:55:47 -0700 Received: from usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTP id 4Kjgfn4cRKz1Rwrw for ; Tue, 19 Apr 2022 16:55:45 -0700 (PDT) Authentication-Results: usg-ed-osssrv.wdc.com (amavisd-new); dkim=pass reason="pass (just generated, assumed good)" header.d=opensource.wdc.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d= opensource.wdc.com; h=content-transfer-encoding:content-type :in-reply-to:organization:from:references:to:content-language :subject:user-agent:mime-version:date:message-id; s=dkim; t= 1650412544; x=1653004545; bh=KKbVILJHDOZ2N6m0wCdUFAHCkLkQrMH0aZI 7ADXChcU=; b=nblcqlKOmUB0qKCRf+Y7ExFS8tU5pu91ghv6T/1gWDqRbLaf42j Nsz1XmPlU/TXyOPOeTaOtzefrHHX24uvIISUzkQoWqfKdSenWQ3fCV50hBLnE6Ne JbJS7gQHG1DsYyIBXpQqZItnSVC+tl95ovAphhPBRIYqrIYDjL8glWm4tmrYDgMF h0XG3wmiE1ZWskFqTtMZReJahvWPp38V9Y9AFgYrUQHGoDoPftATuWqtvxPTxJ+d SGqaF/b7GFT3NU1+AWk+ZS9ff28EWUr91AkNyJv3eh4duVo8YcfOwtAlmkXmbpDa uHXkBf6lCpt/JPj2u0te17PgHUZGADAE/Rw== X-Virus-Scanned: amavisd-new at usg-ed-osssrv.wdc.com Received: from usg-ed-osssrv.wdc.com ([127.0.0.1]) by usg-ed-osssrv.wdc.com (usg-ed-osssrv.wdc.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id MXMgSegGmmbF for ; Tue, 19 Apr 2022 16:55:44 -0700 (PDT) Received: from [10.225.163.14] (unknown [10.225.163.14]) by usg-ed-osssrv.wdc.com (Postfix) with ESMTPSA id 4Kjgff0k5zz1Rvlx; Tue, 19 Apr 2022 16:55:37 -0700 (PDT) Message-ID: <56f889d7-2305-ba7a-42af-9580d8f7df93@opensource.wdc.com> Date: Wed, 20 Apr 2022 08:55:36 +0900 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH 13/48] ARM: pxa: use pdev resource for palmld mmio Content-Language: en-US To: Arnd Bergmann , robert.jarzmik@free.fr, linux-arm-kernel@lists.infradead.org References: <20220419163810.2118169-1-arnd@kernel.org> <20220419163810.2118169-14-arnd@kernel.org> From: Damien Le Moal Organization: Western Digital Research In-Reply-To: <20220419163810.2118169-14-arnd@kernel.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Fri, 22 Apr 2022 15:31:40 +0200 Cc: Ulf Hansson , linux-usb@vger.kernel.org, Philipp Zabel , "Rafael J. Wysocki" , Viresh Kumar , Sergey Lapin , linux-fbdev@vger.kernel.org, Dominik Brodowski , linux-kernel@vger.kernel.org, linux-ide@vger.kernel.org, linux-mtd@lists.infradead.org, Tomas Cech , linux-clk@vger.kernel.org, linux-leds@vger.kernel.org, linux-rtc@vger.kernel.org, Helge Deller , Bartlomiej Zolnierkiewicz , Marek Vasut , Paul Parsons , Linus Walleij , Arnd Bergmann , linux-pm@vger.kernel.org, linux-input@vger.kernel.org, Haojian Zhuang , Lubomir Rintel , Mark Brown , dri-devel@lists.freedesktop.org, Jens Axboe , Thomas Bogendoerfer , Stephen Boyd , patches@opensource.cirrus.com, Dmitry Torokhov , linux-mmc@vger.kernel.org, linux-mips@vger.kernel.org, Michael Turquette , alsa-devel@alsa-project.org, Daniel Mack X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" On 4/20/22 01:37, Arnd Bergmann wrote: > From: Arnd Bergmann > > The palmld header is almost unused in drivers, the only > remaining thing now is the PATA device address, which should > really be passed as a resource. > > Cc: Jens Axboe > Cc: linux-ide@vger.kernel.org > Acked-by: Robert Jarzmik > Acked-by: Bartlomiej Zolnierkiewicz > Signed-off-by: Arnd Bergmann > --- > arch/arm/mach-pxa/palmld-pcmcia.c | 3 ++- > arch/arm/mach-pxa/palmld.c | 12 +++++++++--- > arch/arm/mach-pxa/{include/mach => }/palmld.h | 2 +- > drivers/ata/pata_palmld.c | 3 +-- > 4 files changed, 13 insertions(+), 7 deletions(-) > rename arch/arm/mach-pxa/{include/mach => }/palmld.h (98%) > > diff --git a/arch/arm/mach-pxa/palmld-pcmcia.c b/arch/arm/mach-pxa/palmld-pcmcia.c > index 07e0f7438db1..720294a50864 100644 > --- a/arch/arm/mach-pxa/palmld-pcmcia.c > +++ b/arch/arm/mach-pxa/palmld-pcmcia.c > @@ -13,9 +13,10 @@ > #include > > #include > -#include > #include > > +#include "palmld.h" > + > static struct gpio palmld_pcmcia_gpios[] = { > { GPIO_NR_PALMLD_PCMCIA_POWER, GPIOF_INIT_LOW, "PCMCIA Power" }, > { GPIO_NR_PALMLD_PCMCIA_RESET, GPIOF_INIT_HIGH,"PCMCIA Reset" }, > diff --git a/arch/arm/mach-pxa/palmld.c b/arch/arm/mach-pxa/palmld.c > index d85146957004..d821606ce0b5 100644 > --- a/arch/arm/mach-pxa/palmld.c > +++ b/arch/arm/mach-pxa/palmld.c > @@ -29,8 +29,8 @@ > #include > > #include "pxa27x.h" > +#include "palmld.h" > #include > -#include > #include > #include > #include > @@ -279,9 +279,15 @@ static inline void palmld_leds_init(void) {} > * HDD > ******************************************************************************/ > #if defined(CONFIG_PATA_PALMLD) || defined(CONFIG_PATA_PALMLD_MODULE) > +static struct resource palmld_ide_resources[] = { > + DEFINE_RES_MEM(PALMLD_IDE_PHYS, 0x1000), > +}; > + > static struct platform_device palmld_ide_device = { > - .name = "pata_palmld", > - .id = -1, > + .name = "pata_palmld", > + .id = -1, > + .resource = palmld_ide_resources, > + .num_resources = ARRAY_SIZE(palmld_ide_resources), > }; > > static struct gpiod_lookup_table palmld_ide_gpio_table = { > diff --git a/arch/arm/mach-pxa/include/mach/palmld.h b/arch/arm/mach-pxa/palmld.h > similarity index 98% > rename from arch/arm/mach-pxa/include/mach/palmld.h > rename to arch/arm/mach-pxa/palmld.h > index 99a6d8b3a1e3..ee3bc15b71a2 100644 > --- a/arch/arm/mach-pxa/include/mach/palmld.h > +++ b/arch/arm/mach-pxa/palmld.h > @@ -9,7 +9,7 @@ > #ifndef _INCLUDE_PALMLD_H_ > #define _INCLUDE_PALMLD_H_ > > -#include "irqs.h" /* PXA_GPIO_TO_IRQ */ > +#include /* PXA_GPIO_TO_IRQ */ > > /** HERE ARE GPIOs **/ > > diff --git a/drivers/ata/pata_palmld.c b/drivers/ata/pata_palmld.c > index 2448441571ed..400e65190904 100644 > --- a/drivers/ata/pata_palmld.c > +++ b/drivers/ata/pata_palmld.c > @@ -25,7 +25,6 @@ > #include > > #include > -#include > > #define DRV_NAME "pata_palmld" > > @@ -63,7 +62,7 @@ static int palmld_pata_probe(struct platform_device *pdev) > return -ENOMEM; > > /* remap drive's physical memory address */ > - mem = devm_ioremap(dev, PALMLD_IDE_PHYS, 0x1000); > + mem = devm_platform_ioremap_resource(pdev, 0); > if (!mem) > return -ENOMEM; > Acked-by: Damien Le Moal -- Damien Le Moal Western Digital Research