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 A34D8C54EBD for ; Thu, 12 Jan 2023 16:46:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240998AbjALQqp (ORCPT ); Thu, 12 Jan 2023 11:46:45 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48128 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241305AbjALQoo (ORCPT ); Thu, 12 Jan 2023 11:44:44 -0500 Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2026DBE14; Thu, 12 Jan 2023 08:38:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1673541513; x=1705077513; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=4BOtLkvp4AVdkK2zPygGM6fUB1lerPp5K/6FblR5a3Q=; b=R5vyJ2Bagf28KdcLpfMWEKK5BjBZkusDsNjni2ghCRQUqfVKwfjpxcrs TXkCSRImEkmjOPXH5Yp9jW+F+y6U1od1pg3zAns3M7aRI8Ef3F11TmAXF aYLg5QnZvFTTrAeCqQn672iYh9ccv9tTe6+n8KaiRWlAntvdW1D8vNiwP eXVrVtYyVIBc19iZKZRSEVORw7nZ18sNdco5+2ZUr8Az8cK4haiLTVQBq 6Sn1OB+ZIh5g9ovU8p+r2z2MptqvQyVp35o2SgUOUiQt2xxPGd0sEbeAi D22IRZrUzrggCcKD9Pnn0MBjOTyEcqjOOsx6WaXaW+gzxjnXxe8g7htZx Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10588"; a="304132472" X-IronPort-AV: E=Sophos;i="5.97,211,1669104000"; d="scan'208";a="304132472" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Jan 2023 08:38:04 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10588"; a="635446946" X-IronPort-AV: E=Sophos;i="5.97,211,1669104000"; d="scan'208";a="635446946" Received: from black.fi.intel.com ([10.237.72.28]) by orsmga006.jf.intel.com with ESMTP; 12 Jan 2023 08:37:59 -0800 Received: by black.fi.intel.com (Postfix, from userid 1003) id B8AE0130; Thu, 12 Jan 2023 18:38:33 +0200 (EET) From: Andy Shevchenko To: Bartosz Golaszewski , Dmitry Torokhov , Linus Walleij , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org Cc: Bartosz Golaszewski , Florian Fainelli , Ray Jui , Scott Branden , Broadcom internal kernel review list , Andy Shevchenko Subject: [PATCH v1 2/2] gpiolib: of: Remove no more used ->of_gpio_ranges_fallback() Date: Thu, 12 Jan 2023 18:38:25 +0200 Message-Id: <20230112163825.72983-2-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230112163825.72983-1-andriy.shevchenko@linux.intel.com> References: <20230112163825.72983-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Since the only one and last user of the ->of_gpio_ranges_fallback() gone, remove the callback completely. New platforms must use the gpio-ranges property. Signed-off-by: Andy Shevchenko --- drivers/gpio/gpiolib-of.c | 5 ----- include/linux/gpio/driver.h | 11 ----------- 2 files changed, 16 deletions(-) diff --git a/drivers/gpio/gpiolib-of.c b/drivers/gpio/gpiolib-of.c index 72d8a3da31e3..266352b1a966 100644 --- a/drivers/gpio/gpiolib-of.c +++ b/drivers/gpio/gpiolib-of.c @@ -980,11 +980,6 @@ static int of_gpiochip_add_pin_range(struct gpio_chip *chip) if (!np) return 0; - if (!of_property_read_bool(np, "gpio-ranges") && - chip->of_gpio_ranges_fallback) { - return chip->of_gpio_ranges_fallback(chip, np); - } - group_names = of_find_property(np, group_names_propname, NULL); for (;; index++) { diff --git a/include/linux/gpio/driver.h b/include/linux/gpio/driver.h index ddc7a14a274f..29c283919f8a 100644 --- a/include/linux/gpio/driver.h +++ b/include/linux/gpio/driver.h @@ -522,17 +522,6 @@ struct gpio_chip { int (*of_xlate)(struct gpio_chip *gc, const struct of_phandle_args *gpiospec, u32 *flags); - /** - * @of_gpio_ranges_fallback: - * - * Optional hook for the case that no gpio-ranges property is defined - * within the device tree node "np" (usually DT before introduction - * of gpio-ranges). So this callback is helpful to provide the - * necessary backward compatibility for the pin ranges. - */ - int (*of_gpio_ranges_fallback)(struct gpio_chip *gc, - struct device_node *np); - #endif /* CONFIG_OF_GPIO */ }; -- 2.39.0 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 652B8C54EBD for ; Thu, 12 Jan 2023 16:39:49 +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:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Ky/JB9RHChCe4K+Cy9gcunOY2Ug3shX3FDvWmJE3lbM=; b=p58juhL0/zoAaB qNQt/PLxaBPIme9HZQGQ3EQEg50OE7muRs/+I2SA6Jo1RKcD3o/y10qZg9nuqp4Q27R9zXb/KOq7U IyQEtzynPxJwN7tdlqaMEfpcwy3WQINorB7GNhIaeJHfy+qZB1f8zYNLQuQvIGbJav03SG8WdpH0e mTGyfqwBk9qr5dIZ00E+Tfxzg3Jr/Ky0jOIuH2iSQoOCOz8AsUU/kX3o7QOpj2U/q7sb4oeWQYK/H 4AF2zk71vtyHKN6+HsHC2HFsnZ7phfpX32NGwELt5Vm2wHLSZx1RTIav2bA+KHIxcoyo5Lm072Spi 5Fb4g8jqVnGMYfGMqxzA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pG0b8-00Fsg5-BG; Thu, 12 Jan 2023 16:38:38 +0000 Received: from mga17.intel.com ([192.55.52.151]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pG0at-00FsYD-KN; Thu, 12 Jan 2023 16:38:24 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1673541503; x=1705077503; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=4BOtLkvp4AVdkK2zPygGM6fUB1lerPp5K/6FblR5a3Q=; b=YdkWKIiM/9ViNRQCcLyI45OqfSDm3Ykchn0pMD18AyKEMMM/oMHUyCDT JOnh7GImVufNcNDBx/+793dkZx/u4Z24CphbzCHr5EXtAXJShTeslotpr URf4xeeUTmmksHjVcUoc8MeN3IBjHFCeIDkK9thJEqlLmptBA01IEX6+w SP37ILGXelDHriI2BKWIKLtiSYGTecHOSP1fao+92vYiHsn2s3n9A0qaE 5wcJtnRELGBUal1oXgm7pD1huveV2cIf7mJnSHsDgwJRM1RLuq4vQamWI d5Gh5shbKPNknt7VCwlvCjcCFN/WFJFEnJi3TvopBZv0qevISij0yvSIW w==; X-IronPort-AV: E=McAfee;i="6500,9779,10588"; a="304132464" X-IronPort-AV: E=Sophos;i="5.97,211,1669104000"; d="scan'208";a="304132464" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Jan 2023 08:38:03 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10588"; a="635446946" X-IronPort-AV: E=Sophos;i="5.97,211,1669104000"; d="scan'208";a="635446946" Received: from black.fi.intel.com ([10.237.72.28]) by orsmga006.jf.intel.com with ESMTP; 12 Jan 2023 08:37:59 -0800 Received: by black.fi.intel.com (Postfix, from userid 1003) id B8AE0130; Thu, 12 Jan 2023 18:38:33 +0200 (EET) From: Andy Shevchenko To: Bartosz Golaszewski , Dmitry Torokhov , Linus Walleij , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org Cc: Bartosz Golaszewski , Florian Fainelli , Ray Jui , Scott Branden , Broadcom internal kernel review list , Andy Shevchenko Subject: [PATCH v1 2/2] gpiolib: of: Remove no more used ->of_gpio_ranges_fallback() Date: Thu, 12 Jan 2023 18:38:25 +0200 Message-Id: <20230112163825.72983-2-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230112163825.72983-1-andriy.shevchenko@linux.intel.com> References: <20230112163825.72983-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230112_083823_708031_F7A26731 X-CRM114-Status: GOOD ( 11.72 ) 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 Since the only one and last user of the ->of_gpio_ranges_fallback() gone, remove the callback completely. New platforms must use the gpio-ranges property. Signed-off-by: Andy Shevchenko --- drivers/gpio/gpiolib-of.c | 5 ----- include/linux/gpio/driver.h | 11 ----------- 2 files changed, 16 deletions(-) diff --git a/drivers/gpio/gpiolib-of.c b/drivers/gpio/gpiolib-of.c index 72d8a3da31e3..266352b1a966 100644 --- a/drivers/gpio/gpiolib-of.c +++ b/drivers/gpio/gpiolib-of.c @@ -980,11 +980,6 @@ static int of_gpiochip_add_pin_range(struct gpio_chip *chip) if (!np) return 0; - if (!of_property_read_bool(np, "gpio-ranges") && - chip->of_gpio_ranges_fallback) { - return chip->of_gpio_ranges_fallback(chip, np); - } - group_names = of_find_property(np, group_names_propname, NULL); for (;; index++) { diff --git a/include/linux/gpio/driver.h b/include/linux/gpio/driver.h index ddc7a14a274f..29c283919f8a 100644 --- a/include/linux/gpio/driver.h +++ b/include/linux/gpio/driver.h @@ -522,17 +522,6 @@ struct gpio_chip { int (*of_xlate)(struct gpio_chip *gc, const struct of_phandle_args *gpiospec, u32 *flags); - /** - * @of_gpio_ranges_fallback: - * - * Optional hook for the case that no gpio-ranges property is defined - * within the device tree node "np" (usually DT before introduction - * of gpio-ranges). So this callback is helpful to provide the - * necessary backward compatibility for the pin ranges. - */ - int (*of_gpio_ranges_fallback)(struct gpio_chip *gc, - struct device_node *np); - #endif /* CONFIG_OF_GPIO */ }; -- 2.39.0 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel