From patchwork Thu Jul 26 13:36:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Rivshin X-Patchwork-Id: 10545905 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 5D1B814E0 for ; Thu, 26 Jul 2018 13:37:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 48BEF2B0D9 for ; Thu, 26 Jul 2018 13:37:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3AE1D2B0EE; Thu, 26 Jul 2018 13:37:51 +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 580562B0D9 for ; Thu, 26 Jul 2018 13:37:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730125AbeGZOyn (ORCPT ); Thu, 26 Jul 2018 10:54:43 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:57339 "EHLO out1-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729888AbeGZOym (ORCPT ); Thu, 26 Jul 2018 10:54:42 -0400 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id A4FD621687; Thu, 26 Jul 2018 09:37:47 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Thu, 26 Jul 2018 09:37:47 -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=8lxioAVA+9rEFTTU9DCrcocKZl5aG1LXwlY4YFUMr VI=; b=ZFDwxdJ9EhXuJ/55T5cSCNYNz3S9PVA5wDyUk7EdSxXcpe2TUKxJFmVRZ K6qOoj/bP9jjgrTiM1cegKbkcQZhZBEYou0W5DWmz3d2LPlR/wts9E2cUlLnnVUE PgytUuKN9/DVy2gxVxtmmJXGIGlluYv5slJfJJpF+oD6yfbyl23yiXaofhxdMCWs MbfMz5oWz7y576eygSlqTJd8cV4rN4nnjdUwDx/LVdNknL7OlU9+UwDsKICDT/7w NSr+nZmrLz4xV9qdBnfR5ttcYDMogGnYXCkT0NjJ+hX1LSCExv7Mg74ezNAE4V45 H88ZKvoWF5s8T0lKoojqvO3isvwUw== 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=8lxioAVA+9rEFTTU9 DCrcocKZl5aG1LXwlY4YFUMrVI=; b=UQVj8ZA5ljxhOy/Jfu6MJNPy7I3p9753C lRIup555Pu92SfA24sij2fcIYWGuxl7ldlt4ym73oEEwQmEj+9DGZqTroQHzqyOF Y2RsXNW8zufGgkDAfV1yQ+3SsGDtgNoZnZHA93weeuA5x/ryJo6H2QElDmlGLCAV wxvH/cCCMK+c3cyn0aJWKJ+3p0BgleZpacSJ0XkIes36xfcnhIMAE4VoKGsEQ8Jn Rlfa8DhkLxMWUDCvEKk0epXbB4VoJQF+eI+qh5tm8kJXyYiyNVgrUFAfxDsyPKY3 RU3pbaEXqgCjVjh5NU9DLR+wfRubs9IxrfvZo+yUlEZQxWtBPGXMQ== 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 271BF10268; Thu, 26 Jul 2018 09:37:45 -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 Subject: [PATCH v2] pwm: pwm-omap-dmtimer: return -EPROBE_DEFER if no dmtimer platform data Date: Thu, 26 Jul 2018 09:36:58 -0400 Message-Id: <20180726133658.23902-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 Acked-by: Ladislav Michl --- 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: d72e90f33aa4709ebecc5005562f52335e106a60 diff --git a/drivers/pwm/pwm-omap-dmtimer.c b/drivers/pwm/pwm-omap-dmtimer.c index 665da3c8fbceb..d3d7ea7a53146 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_info(&pdev->dev, + "dmtimer pdata structure NULL, deferring probe\n"); + ret = -EPROBE_DEFER; goto put; }