From patchwork Mon Jul 30 22:30:30 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Rivshin X-Patchwork-Id: 10549663 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 032A013B8 for ; Mon, 30 Jul 2018 22:34:40 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F38252A84B for ; Mon, 30 Jul 2018 22:34:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E52B02A858; Mon, 30 Jul 2018 22:34:39 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 136992A84B for ; Mon, 30 Jul 2018 22:34:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727063AbeGaALp (ORCPT ); Mon, 30 Jul 2018 20:11:45 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:45167 "EHLO out1-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726966AbeGaALp (ORCPT ); Mon, 30 Jul 2018 20:11:45 -0400 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id D4AA321F69; Mon, 30 Jul 2018 18:34:36 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Mon, 30 Jul 2018 18:34:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=awxrd.com; h=cc :date:from:message-id:subject:to:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=LraaoKNseF1g6iaVKsGupfmjYDn3CSFp6YwtJE1ig gs=; b=HFoX4UyHB9J29QjncNJpD6P8xt+rsGUo3lUtjJmDxklhH0T8dg8AOkkbS LI711zId6uCbCDzlF2sPNj+iOifxgXRhrvCAJBv0iTn6fxcI3mF4PbakqNdsdJqA iihyAf0wjmt1EiyJMPP9+DUF8kAS6nW6c3ZP6/rRX4z15cpTKqAOHsJlMF4PjIO6 7RH/p4SCcmga/IvzEodJx3o1ucEwAj+/CJ+z1H510VkuPhUcFRzEMZgNXzARMkt0 stq8No6i9FNzgnVTqc0548n8cu3lPikl4ST7klHVupawzlcrqtOSUrKoE33BegGV xTBqy+QFZ+v0tZULqXXP4ccTP0VXA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:date:from:message-id:subject:to :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=LraaoKNseF1g6iaVK sGupfmjYDn3CSFp6YwtJE1iggs=; b=UR+OkYrcGlq1YjQGbU0z0da4eZBEfVyYt ghP1zG0WKsRwayaM1pGiutHEFr6HYJDNts/6os0Ja/3sE+JlBjNWjDESZnMzP//B 3IWNF+xYTYsKhaXsV5MS9Md1t+Un56YjDXFMbCcoXhTuS7VLGjsg0v53OOdP4J6p e/t8xD0A+zHVas3k0GxPAYDf4HrehXCoYKgPFSWK4Py0vI039U8QMtnUvCuAtYho Ssr4DltCCpQ9epOlN8b8sLIKTjoeyBcLzCprJPZROIugn82kFKGl1UYH0O739lQl qwltTCpj4VytVFA5Om4uIkr0vooq86/vomTnIhhRcbNicyeJnikJg== X-ME-Proxy: X-ME-Sender: Received: from drivshin-linux.inscitek.com (unknown [24.213.148.66]) by mail.messagingengine.com (Postfix) with ESMTPA id C4DC210276; Mon, 30 Jul 2018 18:34:34 -0400 (EDT) From: David Rivshin To: Thierry Reding , Keerthy , Ladislav Michl , Neil Armstrong Cc: linux-pwm@vger.kernel.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Tony Lindgren , Thomas Gleixner , Pavel Machek , Andreas Kemnade , "H. Nikolaus Schaller" Subject: [PATCH v3] pwm: pwm-omap-dmtimer: return -EPROBE_DEFER if no dmtimer platform data Date: Mon, 30 Jul 2018 18:30:30 -0400 Message-Id: <20180730223030.10628-1-drivshin@awxrd.com> X-Mailer: git-send-email 2.17.1 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: David Rivshin If a pwm-omap-dmtimer is probed before the dmtimer it uses, the platform data won't be set yet. Fixes: ac30751df953 ("ARM: OMAP: pdata-quirks: Remove unused timer pdata") Cc: # 4.17+ Signed-off-by: David Rivshin Acked-by: Pavel Machek Tested-by: Pavel Machek --- Changes in v3: * Changed dev_info to dev_dbg Changes in v2: * Added Pavel's Acked-by/Tested-by [1] [1] https://lkml.org/lkml/2018/7/16/346 drivers/pwm/pwm-omap-dmtimer.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) base-commit: acb1872577b346bd15ab3a3f8dff780d6cca4b70 diff --git a/drivers/pwm/pwm-omap-dmtimer.c b/drivers/pwm/pwm-omap-dmtimer.c index 665da3c8fbceb..f45798679e3c0 100644 --- a/drivers/pwm/pwm-omap-dmtimer.c +++ b/drivers/pwm/pwm-omap-dmtimer.c @@ -264,8 +264,9 @@ static int pwm_omap_dmtimer_probe(struct platform_device *pdev) timer_pdata = dev_get_platdata(&timer_pdev->dev); if (!timer_pdata) { - dev_err(&pdev->dev, "dmtimer pdata structure NULL\n"); - ret = -EINVAL; + dev_dbg(&pdev->dev, + "dmtimer pdata structure NULL, deferring probe\n"); + ret = -EPROBE_DEFER; goto put; }