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 X-Spam-Level: X-Spam-Status: No, score=-13.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B8A01C433E0 for ; Mon, 15 Mar 2021 12:35:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 921CC64E10 for ; Mon, 15 Mar 2021 12:35:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229774AbhCOMfK (ORCPT ); Mon, 15 Mar 2021 08:35:10 -0400 Received: from mga14.intel.com ([192.55.52.115]:57156 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229591AbhCOMfD (ORCPT ); Mon, 15 Mar 2021 08:35:03 -0400 IronPort-SDR: cW9U5hcq9HmL+T3sYj/E6FZZHErGhnWJHbKxOrRb20lgqQ6Tf+bvfX4sEyBXgVwDQ2V2EZgL0v wMqEi3VS7xdg== X-IronPort-AV: E=McAfee;i="6000,8403,9923"; a="188438200" X-IronPort-AV: E=Sophos;i="5.81,249,1610438400"; d="scan'208";a="188438200" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Mar 2021 05:35:02 -0700 IronPort-SDR: RJ6GDEBA3wPOFqp8VhbHNMrFjGOFCIsv4syef9hLQcHO2D6RKcrj7/S5ctRNM1dWttLAbmrwj3 AUVQ8UfOa64w== X-IronPort-AV: E=Sophos;i="5.81,249,1610438400"; d="scan'208";a="371613548" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by orsmga003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Mar 2021 05:35:01 -0700 Received: from andy by smile with local (Exim 4.94) (envelope-from ) id 1lLmR0-00Cfus-Kd; Mon, 15 Mar 2021 14:34:58 +0200 Date: Mon, 15 Mar 2021 14:34:58 +0200 From: Andy Shevchenko To: linux-kernel@vger.kernel.org Cc: Rodolfo Giometti , Ryan Govostes , Greg Kroah-Hartman Subject: Re: [PATCH resend v1 1/7] pps: clients: gpio: Bail out on error when requesting GPIO echo line Message-ID: References: <20210309112403.36633-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210309112403.36633-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, Mar 09, 2021 at 01:23:57PM +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. Greg, can you apply 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.1 > -- With Best Regards, Andy Shevchenko