Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751846AbdIUVyW (ORCPT ); Thu, 21 Sep 2017 17:54:22 -0400 Received: from mail-bl2nam02on0055.outbound.protection.outlook.com ([104.47.38.55]:48069 "EHLO NAM02-BL2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751763AbdIUVyT (ORCPT ); Thu, 21 Sep 2017 17:54:19 -0400 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=David.Daney@cavium.com; Subject: Re: [PATCH] gpio: thunderx: remove unused .map() hook from irq_domain_ops To: Masahiro Yamada , linux-gpio@vger.kernel.org, Linus Walleij , David Daney Cc: Thomas Gleixner , Jason Cooper , Marc Zyngier , linux-kernel@vger.kernel.org References: <1505356645-19765-1-git-send-email-yamada.masahiro@socionext.com> From: David Daney Message-ID: <26ac3165-c512-0b79-da17-0232634a5aba@caviumnetworks.com> Date: Thu, 21 Sep 2017 14:54:14 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <1505356645-19765-1-git-send-email-yamada.masahiro@socionext.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [50.233.148.156] X-ClientProxiedBy: BY2PR07CA0028.namprd07.prod.outlook.com (10.166.107.23) To CY4PR07MB3493.namprd07.prod.outlook.com (10.171.252.150) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 91d6ebb1-8a54-4b5c-755e-08d5013b4e52 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(2017052603199)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095);SRVR:CY4PR07MB3493; X-Microsoft-Exchange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rw1LGOk5/ZeMNa4EwIoyt0v4CSjnf7j6JQEqrOLCpQk/PS2Tgq1sk6epaBkRdjXhOkr4VwJKX5eaREj+/mm2r7mialw7dS+Njr+OdXSDl8anUkt0MEsdilI7Ni1uJgTMwEIziD1aAW7ELtyLmCzSTWupmjHjSlZFbizPXbnebCrk2rSfB/DI/WKtwzvsDzne9z7RDr0fT7pKnpUxcOFFf6KjKphA7SJEJwMcdavMtrqlS6EEn6ohDLkte9iBxSusF10n0ff/SYhLI4fuLo5KlEbN4Ft8C/eVXqhis1SJWUuoEdlViv4X73LkiY/l2Qh+oaqUEDQbBy77OPakLU/uwPMiRQkxFWHRG9IbdxyIRJrqpS6jbvgRYxEXiisjuTvrTm8L7V1jd3z9MtvVhiMehGlG9fPtVWIt1KoF+DvIqmej7bk3EP7dljHpMUULoEqHZmIhU2MohwLR0qcXQL2Ctp82k/VfCW0T4D3VYE=;4:k0nNQfWhIOH1TLNCVLeFVfqy21MmvfEdXz/oelpoYozY7VjHNQdpeO1ARV9rdediZlkZYq+GuBABBCBhYJFlvPhoYbnzkflnkQ4IQ3AGYNKNwiymCoLANqDt3b4bsHT4G3omB6rHdRMtgsjGoKDWighh5xJR7pVCg2WiaBfUOiXp78lJMbjyIlsI1eBH1/YlkI1RnbYiKCkdT3xWFV88mykcZS/Y9dCBApQIKM4Pqj+4UFGyhwf6wOFcpQmvzLkL X-Exchange-Antispam-Report-Test: UriScan:; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(5005006)(8121501046)(93006095)(100000703101)(100105400095)(3002001)(10201501046)(6041248)(20161123564025)(20161123562025)(20161123555025)(20161123560025)(20161123558100)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095);SRVR:CY4PR07MB3493;BCL:0;PCL:0;RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);SRVR:CY4PR07MB3493; X-Forefront-PRVS: 04371797A5 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(6009001)(376002)(346002)(377454003)(199003)(189002)(24454002)(5660300001)(4326008)(230700001)(58126008)(53546010)(6246003)(69596002)(81166006)(81156014)(8936002)(189998001)(23676002)(6486002)(83506001)(54906003)(50466002)(16526017)(65806001)(97736004)(66066001)(47776003)(110136005)(6512007)(229853002)(6506006)(31696002)(31686004)(316002)(2950100002)(3846002)(42882006)(25786009)(76176999)(50986999)(54356999)(36756003)(64126003)(2906002)(101416001)(65956001)(53936002)(6116002)(72206003)(106356001)(305945005)(33646002)(8676002)(478600001)(105586002)(65826007)(7736002)(68736007)(53416004)(142923001);DIR:OUT;SFP:1101;SCL:1;SRVR:CY4PR07MB3493;H:ddl.caveonetworks.com;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtDWTRQUjA3TUIzNDkzOzIzOkMzY2hHUm5yN25NaGRndDIwcjJ4Zlp0eUlR?= =?utf-8?B?ZGlKbnpCcXliTDZyNUlRdmdFTCtGQUNIWFVkUkhKQzNHYmFwdW1GOHFDQWEx?= =?utf-8?B?VHRnRXZDVHRkTG9kUGVYQ0VFZVRvNFdjaGp3bEZVUTlqYy9vMDhoZXVwVjRL?= =?utf-8?B?aDMwY2ZXdDZaYkpFRDU0bDRUbW93MnZZcDJFOVJwMnQxQ0V0RisrTThVWFNO?= =?utf-8?B?NCtlNURaR1Z4WVlUSHpuN3B0TDdGMWtBL0NSbVNGM2YvSjFPeTdlWTQ4Kzdt?= =?utf-8?B?U05pVGo0cStDZEZ3RFFTUDdZb0dBd0Q1d012aFBoSXhYbnp4bTR6SjVLdnF4?= =?utf-8?B?N1lydk43NklQY0I5aE13bXpUTmNXYjYwRDhmR0pYZ1pOdWpU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JF8QxLTnjfMs9iqIVI36YxOiCv9Vg==;5:1NSAlaCy5QPPSX9f2FgZXp8G/EB/bBljXFCSZANeB/WZ3hDWatX8urZf+CsUbSocrfkAh/KHXHnG8sjy9XHJ4V+oir31hnYN+8YNuW4PIWILVa3Xv0r4uRtNEUH0zV98pE2R0GHIvvuleQs/6lU6yA==;24:70mENblRuwBh19HnqjkqZ4A/BVLpcsrD9lLOI9zcZbH4ZXD4tLyUgP3IHp/E5FqPZ2X74AbGdROQ3/NqxowzWmwakHkuT946Fl0HVIWs2vg=;7:kaC1x2rjncPr495OtNHkRyD4IjQo/oo8kRTTEMFFmbLAzOmW+hKDxrxbEbDD/SjIcqxKInTwUUil4eI38+sYVf2tASkvLjEKmJjMBssUmT6UliDMdoIWSeBNBmvT4Fco9QliZfXDX8wNxrvNGwXbzOoFpSNDMsFSLZ3fn3eO0QyrwbrBI7iymwk5oZOGHQEVqWJ7bvug6ZZXkSwrxR3h/fPF2u9efhwEQaaQT/HdeYA= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Sep 2017 21:54:16.4818 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR07MB3493 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1523 Lines: 49 On 09/13/2017 07:37 PM, Masahiro Yamada wrote: > This driver implements .alloc() hook, so .map() is not used. Although this comment is true for this driver, it is unclear to me if the statement is true in the general case. > > Signed-off-by: Masahiro Yamada Tested-by: David Daney > --- > > drivers/gpio/gpio-thunderx.c | 13 ------------- > 1 file changed, 13 deletions(-) > > diff --git a/drivers/gpio/gpio-thunderx.c b/drivers/gpio/gpio-thunderx.c > index 57efb25..b5adb79 100644 > --- a/drivers/gpio/gpio-thunderx.c > +++ b/drivers/gpio/gpio-thunderx.c > @@ -417,18 +417,6 @@ static struct irq_chip thunderx_gpio_irq_chip = { > .flags = IRQCHIP_SET_TYPE_MASKED > }; > > -static int thunderx_gpio_irq_map(struct irq_domain *d, unsigned int irq, > - irq_hw_number_t hwirq) > -{ > - struct thunderx_gpio *txgpio = d->host_data; > - > - if (hwirq >= txgpio->chip.ngpio) > - return -EINVAL; > - if (!thunderx_gpio_is_gpio_nowarn(txgpio, hwirq)) > - return -EPERM; > - return 0; > -} > - > static int thunderx_gpio_irq_translate(struct irq_domain *d, > struct irq_fwspec *fwspec, > irq_hw_number_t *hwirq, > @@ -455,7 +443,6 @@ static int thunderx_gpio_irq_alloc(struct irq_domain *d, unsigned int virq, > } > > static const struct irq_domain_ops thunderx_gpio_irqd_ops = { > - .map = thunderx_gpio_irq_map, > .alloc = thunderx_gpio_irq_alloc, > .translate = thunderx_gpio_irq_translate > }; >