Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1374442pxb; Fri, 26 Feb 2021 09:09:07 -0800 (PST) X-Google-Smtp-Source: ABdhPJyt4gBlrtV5YrEG54cMItm2ks19qy8D04ziRjNSJfzyulBvbGR03FEJyc8aYxpun+8N6x9I X-Received: by 2002:a17:906:33d9:: with SMTP id w25mr3414654eja.413.1614359346847; Fri, 26 Feb 2021 09:09:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614359346; cv=none; d=google.com; s=arc-20160816; b=hGxDT6wblyKr8aSMfOh6vi8bloTuWWSotStsZk6Vt4Xaqb4oNxxX2qit2I9rhpb9U9 H1YnT5W5ZBgNCqd2SEgUk4F3B+qjLYxawERQp5jWcOLroeCXVy8Go/8waNZNPPhoj2Uw uuP/BkLzivXlqy2Bk2hu/trKgHDbx0/pLGAQ1f9vTQUfaVT8z5Q8CwLbgKLj1ikm4jgM GvNDm+mUZFjWwXxbUIMWUfxKGD7V2Wo2+OiKmAJc1FnwuOCy7MbATEJo5l5rjVzbRVLe D4qfDD67F9mJEoez9uPVGAAwPkDHZL/UaN42aqn4Gyw7ySCl+w66GuqfW8BwpwC2Wcpf PNJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:organization:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :ironport-sdr:ironport-sdr; bh=HBZ24fLKiNR9dtxyjpcOhEUaFxS7eT2k8gJHQriSHkU=; b=kk5b0tdL6NZgKdhy/1ZdZsrIiQtESdJEn9oNguz8isfcEPl/VvBX+AbeH+dUd3z0+Z j1M2ToeDG+ceRS7xcgqp5fu7uAnDprSOh1EENpdyoqYtN9CPTDzNnqNo6VNo7zzvFcgs 1zul3CzIai01gGPBq0ff+p9pidssmdyy1xL6kRqthijVO/QDP0SHpTx7MII9KWbEBgEs 7EIFNh1YVYdwgf+pdX/toBlYki+XDCGGn7a6gaNo1SUIqAoCmlMW02J5ni2MZIEOGqWc ObGcPFg9u7sgNUPZvrFeiik0clUvVaBi6kkXd3OauKvvjmqcyCO0CrhicacI8cDsSoUh 5SBg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d24si5880624edt.102.2021.02.26.09.08.39; Fri, 26 Feb 2021 09:09:06 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230014AbhBZRGy (ORCPT + 99 others); Fri, 26 Feb 2021 12:06:54 -0500 Received: from mga14.intel.com ([192.55.52.115]:65016 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230040AbhBZRFZ (ORCPT ); Fri, 26 Feb 2021 12:05:25 -0500 IronPort-SDR: OldlsLeSK1x3lAsir2KQ4z3RieaEKtyqvWwKX37qTYUxl9IQi+iS6GuyDzLs7eeXaqTXQcAC5N hq3KNnrOju/g== X-IronPort-AV: E=McAfee;i="6000,8403,9907"; a="185248072" X-IronPort-AV: E=Sophos;i="5.81,209,1610438400"; d="scan'208";a="185248072" Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Feb 2021 09:03:36 -0800 IronPort-SDR: H163A0v8r6xd8gSA5UP4M+NVoDU1cL2trpXdJug28WbJCR/gkcNAfn2cEw4c/QU9/egfMmYP/y osQ1jDe9ip+g== X-IronPort-AV: E=Sophos;i="5.81,209,1610438400"; d="scan'208";a="443137653" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by orsmga001-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Feb 2021 09:03:34 -0800 Received: from andy by smile with local (Exim 4.94) (envelope-from ) id 1lFgWa-008PHu-Fh; Fri, 26 Feb 2021 19:03:32 +0200 Date: Fri, 26 Feb 2021 19:03:32 +0200 From: Andy Shevchenko To: linux-kernel@vger.kernel.org Cc: Rodolfo Giometti , Ryan Govostes Subject: Re: [PATCH v1 1/7] pps: clients: gpio: Bail out on error when requesting GPIO echo line Message-ID: References: <20210216113154.70852-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210216113154.70852-1-andriy.shevchenko@linux.intel.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 16, 2021 at 01:31:48PM +0200, Andy Shevchenko wrote: > When requesting optional GPIO echo line, bail out on error, > so user will know that something wrong with the existing property. Guys, any comments on this series? > Signed-off-by: Andy Shevchenko > --- > drivers/pps/clients/pps-gpio.c | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/drivers/pps/clients/pps-gpio.c b/drivers/pps/clients/pps-gpio.c > index e0de1df2ede0..f89c31aa66f1 100644 > --- a/drivers/pps/clients/pps-gpio.c > +++ b/drivers/pps/clients/pps-gpio.c > @@ -119,12 +119,12 @@ static int pps_gpio_setup(struct platform_device *pdev) > data->echo_pin = devm_gpiod_get_optional(&pdev->dev, > "echo", > GPIOD_OUT_LOW); > - if (data->echo_pin) { > - if (IS_ERR(data->echo_pin)) { > - dev_err(&pdev->dev, "failed to request ECHO GPIO\n"); > - return PTR_ERR(data->echo_pin); > - } > + if (IS_ERR(data->echo_pin)) { > + dev_err(&pdev->dev, "failed to request ECHO GPIO\n"); > + return PTR_ERR(data->echo_pin); > + } > > + if (data->echo_pin) { > ret = of_property_read_u32(np, > "echo-active-ms", > &value); > -- > 2.30.0 > -- With Best Regards, Andy Shevchenko