From patchwork Thu Mar 9 07:46:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 66626 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp154672wrd; Wed, 8 Mar 2023 23:49:35 -0800 (PST) X-Google-Smtp-Source: AK7set9xJmOeOIP7kmKn0yRkc1QDNGCAjQkOxHKGHs8XlGM7TwWHUOMyZWhT4hzsE+LMSWZCQKnn X-Received: by 2002:a05:6a20:6615:b0:cc:5c57:7a0d with SMTP id n21-20020a056a20661500b000cc5c577a0dmr23507045pzh.40.1678348174951; Wed, 08 Mar 2023 23:49:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1678348174; cv=none; d=google.com; s=arc-20160816; b=KJMQbMXdEzKuITb9aBd5gPxbS83w5w0gbipJwt20Dn9dYm5JpuKbm1rLWEQlR3A0S/ ru8p0scuLdgaPn1CCd0f650hIhbM9fe3dwNldsZgQc4xIMWSpgv9W6mXtYGpqwCthi5J aPBIr2LS/xYwXvP10to7a3zkEwCzWix7Nt/fOyRtAigxqpQ+VgkYqQparVwhbqQmgbM6 tJesri/9wSmjqbKa/QS1eVhb8VHqV/eeY/homYNDpl8QOw9ZP6afd8ckfPjiWDSf/Baw /KOaynoevqSbroPQ7XPyF4sjzvchUuKe1hF/cobkeLoSgfJcR+dWMpLORLYfCZGIXw72 /0Pw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=p1r1zyYA9t+QO+JcvGnUo/RuruD1eWdYkbb9TESedm0=; b=qxNsraQMqI/aPNLVSuYRFTFSOIJMuNfIWkLDxB8MI1lcbnbL5BjcrLzocU2/qjuQ4F HyjegpDgy1/B788AepqSvrGCbZyklP3igtaf+7AjuvnnukpTR/9b8d3PX2gNSj2HL3sP DffplJIsZYrRSUpDbagHVrhjp5Bn7K5s9+z2kr9n0F/nd8Xa4TARxjD8JQKitR2Vzmmf QszVWH6W7myVrAa/EO2LPRpuV1gK1zzW89zXAxNvJnTlYZFWTwnb3Yqy5c2Gq+GkrpIP 9csQLmo+WT9D5/Sb6aT3T9j0c2q8ZRCdyBfnp0Eec7RDnyy1K25F7kzJXkN/sJdbgE6Y 7VeQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Tn0kT9pG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d10-20020a630e0a000000b004ce5301edd5si16460592pgl.711.2023.03.08.23.49.21; Wed, 08 Mar 2023 23:49:34 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Tn0kT9pG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230190AbjCIHrf (ORCPT + 99 others); Thu, 9 Mar 2023 02:47:35 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46384 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230050AbjCIHqn (ORCPT ); Thu, 9 Mar 2023 02:46:43 -0500 Received: from mail-lf1-x134.google.com (mail-lf1-x134.google.com [IPv6:2a00:1450:4864:20::134]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 456EDDDF17 for ; Wed, 8 Mar 2023 23:46:12 -0800 (PST) Received: by mail-lf1-x134.google.com with SMTP id j11so1118135lfg.13 for ; Wed, 08 Mar 2023 23:46:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1678347970; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=p1r1zyYA9t+QO+JcvGnUo/RuruD1eWdYkbb9TESedm0=; b=Tn0kT9pG+OpUApaG8znHQ+ekGoIVakiLzD95tkVlpHddMSmj9vog6WG1rG3HUDZpgC BuaWUky0NZEFG3ZjPUEXCHe4cjuJR4SB0LLxYr/6BEwlPalYqJ6aOkj73iU3gVyGurYv dgBNUTKW/8M2EvU3Wvmzljdpz+fwneQxO6uQOe1kVLLE7T8m6XX3o8gLdJAbG+wZy4zM JYyqjcm1V+q7sf8tnlK/k2TEUIIRKSJM4OF3CUv3TDMnLRdu342Hsyf6/PmXD1hTlhiV bPOKa03FmOGd6MT+j+We7hC3UCMI3wCQXCQKuU11VOTZ204ZYL8/1oLy8hOm4JNjrCJM m4pw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678347970; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=p1r1zyYA9t+QO+JcvGnUo/RuruD1eWdYkbb9TESedm0=; b=qL+iWGnPtHSB3LwK2IvMDkfsMUjx+8IfhkgRPHJO0faQLa9aImACi0i0jfexuJjxAP PXPi1wvxVgB4O4+Yl0/Ecm7gZDC/k9Qv4kJgittXPn2VJPiWEmBC870yOIjJJcDRpmnb shJFDU0ifypqZC9ctXoUBEFwKgBUFxgTZZ0O0tsCPhZXGrC4reb1yyydEzQv9JFYyeuy jotza8MIml1yyDAX8QTpjGg5aZeWOBW7Ca9xVq5jIWXaHFGYjwP+nprc34uC5BJ/O3pr 0LVUm2dIaPONWBhejwIgkJVCV1EV4D2nsHjvSoUd56Ew3pW4rY5joxM/8AohW9zBERm8 sSsw== X-Gm-Message-State: AO0yUKUjPBPyl/aDmCFajnHVux3mTBA64ZDo8OSwo6ONc4vE10TwpM9F cQeBPI6bPEh01MhzBUUN7FFZEg== X-Received: by 2002:ac2:54a5:0:b0:4dc:4b92:dbc4 with SMTP id w5-20020ac254a5000000b004dc4b92dbc4mr5293556lfk.14.1678347970521; Wed, 08 Mar 2023 23:46:10 -0800 (PST) Received: from [127.0.1.1] ([85.235.12.219]) by smtp.gmail.com with ESMTPSA id a6-20020a056512020600b004bb766e01a4sm2568972lfo.245.2023.03.08.23.46.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 Mar 2023 23:46:10 -0800 (PST) From: Linus Walleij Date: Thu, 09 Mar 2023 08:46:02 +0100 Subject: [PATCH v3 14/17] gpio: omap: Drop irq_base MIME-Version: 1.0 Message-Id: <20230215-immutable-chips-v3-14-972542092a77@linaro.org> References: <20230215-immutable-chips-v3-0-972542092a77@linaro.org> In-Reply-To: <20230215-immutable-chips-v3-0-972542092a77@linaro.org> To: Mun Yew Tham , Bartosz Golaszewski , Joel Stanley , Andrew Jeffery , Alban Bedel , Orson Zhai , Baolin Wang , Chunyan Zhang , Jay Fang , Daniel Palmer , Romain Perier , Santosh Shilimkar , Kevin Hilman , William Breathitt Gray Cc: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-aspeed@lists.ozlabs.org, linux-omap@vger.kernel.org, Linus Walleij , Janusz Krzysztofik , Tony Lindgren , Arnd Bergmann , Marc Zyngier X-Mailer: b4 0.12.1 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1759875616321419463?= X-GMAIL-MSGID: =?utf-8?q?1759875616321419463?= The OMAP1 at one point was using static irqs but that time is gone, OMAP1 uses sparse irqs like all other multiplatform targets so this static allocation of descriptors should just go. Cc: Janusz Krzysztofik Cc: Tony Lindgren Acked-by: Arnd Bergmann Acked-by: Marc Zyngier Reviewed-by: Tony Lindgren Signed-off-by: Linus Walleij --- drivers/gpio/gpio-omap.c | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c index f5f3d4b22452..1cbd040cf796 100644 --- a/drivers/gpio/gpio-omap.c +++ b/drivers/gpio/gpio-omap.c @@ -992,7 +992,6 @@ static int omap_gpio_chip_init(struct gpio_bank *bank, struct irq_chip *irqc, struct gpio_irq_chip *irq; static int gpio; const char *label; - int irq_base = 0; int ret; /* @@ -1024,19 +1023,6 @@ static int omap_gpio_chip_init(struct gpio_bank *bank, struct irq_chip *irqc, } bank->chip.ngpio = bank->width; -#ifdef CONFIG_ARCH_OMAP1 - /* - * REVISIT: Once we have OMAP1 supporting SPARSE_IRQ, we can drop - * irq_alloc_descs() since a base IRQ offset will no longer be needed. - */ - irq_base = devm_irq_alloc_descs(bank->chip.parent, - -1, 0, bank->width, 0); - if (irq_base < 0) { - dev_err(bank->chip.parent, "Couldn't allocate IRQ numbers\n"); - return -ENODEV; - } -#endif - /* MPUIO is a bit different, reading IRQ status clears it */ if (bank->is_mpuio && !bank->regs->wkup_en) irqc->irq_set_wake = NULL; @@ -1047,7 +1033,6 @@ static int omap_gpio_chip_init(struct gpio_bank *bank, struct irq_chip *irqc, irq->default_type = IRQ_TYPE_NONE; irq->num_parents = 1; irq->parents = &bank->irq; - irq->first = irq_base; ret = gpiochip_add_data(&bank->chip, bank); if (ret)