Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757856Ab2FQSEu (ORCPT ); Sun, 17 Jun 2012 14:04:50 -0400 Received: from mail-qa0-f50.google.com ([209.85.216.50]:58093 "EHLO mail-qa0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757795Ab2FQSEs (ORCPT ); Sun, 17 Jun 2012 14:04:48 -0400 MIME-Version: 1.0 In-Reply-To: <1339927893-8842-1-git-send-email-stigge@antcom.de> References: <1339927893-8842-1-git-send-email-stigge@antcom.de> Date: Sun, 17 Jun 2012 20:04:47 +0200 Message-ID: Subject: Re: [PATCH] gpio: of_get_named_gpio_flags() return -EPROBE_DEFER if GPIO not yet available From: Linus Walleij To: Roland Stigge Cc: cjb@laptop.org, grant.likely@secretlab.ca, rob.herring@calxeda.com, rmk+kernel@arm.linux.org.uk, ulf.hansson@stericsson.com, linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org, aletes.xgr@gmail.com, linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 927 Lines: 23 On Sun, Jun 17, 2012 at 12:11 PM, Roland Stigge wrote: > of_get_named_gpio_flags() and of_get_named_gpio() return -EPROBE_DEFER if the > respective GPIO is not (yet) available. This is useful if driver's probe() > functions try to get a GPIO whose controller isn't probed yet. Thus, the driver > can be probed again later on. > > The function still returns -EINVAL on other errors (parse error or node doesn't > exist). This way, the case of an optional/intentionally missing GPIO is handled > appropriately. > > Signed-off-by: Roland Stigge Acked-by: Linus Walleij This will work, good work! Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/