Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp3139242imm; Sun, 29 Jul 2018 11:09:17 -0700 (PDT) X-Google-Smtp-Source: AAOMgperBZRNEYN4FJEgvYj42Fccs01WUJ/J8Q/SBB1M7dJcG7i9RTh6hR7T4mqfpcOWMe9G0apc X-Received: by 2002:a62:998:: with SMTP id 24-v6mr14545508pfj.99.1532887757323; Sun, 29 Jul 2018 11:09:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532887757; cv=none; d=google.com; s=arc-20160816; b=xPJmC+KO2gb4LSwZElkR83XD9fxIHkUicMZvFqLte+YD7dPylvD5IkFsQVg1H5hGJr cFE+UWPR0g0F3LXk5bRoMeChP5qq8GUBS1uvIHaOMrRHwAK6hLCCm8oh6ThbPlWz89rt 83b0lBpeG85rezBrcNOgG1qEG7NXkELPIAlXIFg5v2f/oz5EfdG15P6W/j925RdMKk8d QAl5SOS5ZlXSybVe+rzHnxoSDuVXEUvUrgFyZbbRohYwDnFd65D2kDg6DP4S8POUF6UR rjqOiXAUXejbUJ3dym/rwZVuB7PYBH2qLf4cWrnBOwD0QneyUotP7BlKhLMkjSHBQMQB ztpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=XHexJzjy7lmRCuehvYYEDKRDYq9pWtYCE/7E0cQ9/+U=; b=SnebQOMB4XOqsm/rhwTU1iIIQSRLjm07ViVFz3NpPcZiOjFS2B1sSvGFKvtLQmWkNM lHW9de92S25de8l7oknTmBTcp2jrqukJiv1t59MM9/NNdjhkfGu+gdOo5IZlli7remYI 2EhvcxUT8+yj/49iSmAOCkM342AhjjzlPU2MnLAF+/FVMxI+6++49/EXNUCUHzArZOu6 ohJ/5GC/s4P+5m31+cs5TaLckGCE31aYmhE3ZuWy79fN2/LzheCJImZP6EwGxZAYdbO+ 2Y8R8aHHKJlE2DNfkC8HbOf/5w22hbOki3kIL5WiPsS9D0FddGLn2qjy1pu6ygW+dUtr mu0Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z127-v6si8530995pgb.455.2018.07.29.11.09.02; Sun, 29 Jul 2018 11:09:17 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726899AbeG2Tjb (ORCPT + 99 others); Sun, 29 Jul 2018 15:39:31 -0400 Received: from eddie.linux-mips.org ([148.251.95.138]:37254 "EHLO cvs.linux-mips.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726493AbeG2Tjb (ORCPT ); Sun, 29 Jul 2018 15:39:31 -0400 Received: (from localhost user: 'ladis' uid#1021 fake: STDIN (ladis@eddie.linux-mips.org)) by eddie.linux-mips.org id S23993024AbeG2SINQQSw4 (ORCPT + 2 others); Sun, 29 Jul 2018 20:08:13 +0200 Date: Sun, 29 Jul 2018 20:08:04 +0200 From: Ladislav Michl To: "H. Nikolaus Schaller" Cc: Andreas Kemnade , David Rivshin , linux-pwm@vger.kernel.org, linux-omap , Tony Lindgren , Keerthy , Linux Kernel Mailing List , Thierry Reding , Discussions about the Letux Kernel Subject: Re: [PATCH] pwm: pwm-omap-dmtimer: fix probing problems by returning EPROBE_DEFER Message-ID: <20180729180804.GA18468@lenoch> References: <20180728165914.15871-1-andreas@kemnade.info> <20180728203501.GA16194@lenoch> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Jul 29, 2018 at 08:32:41AM +0200, H. Nikolaus Schaller wrote: > Hi, > > > Am 28.07.2018 um 22:35 schrieb Ladislav Michl : > > > > Hi Andreas, > > > > On Sat, Jul 28, 2018 at 06:59:14PM +0200, Andreas Kemnade wrote: > >> I got this in the kernel log: > >> [ 0.756042] omap-dmtimer-pwm dmtimer-pwm: dmtimer pdata structure NULL > >> [ 0.756134] omap-dmtimer-pwm: probe of dmtimer-pwm failed with error -22 > >> > >> the probe function has to wait until omap_dm_timer_probe() in > >> clocksource/timer-ti-dm.c has initialized pdata, so defer probing > > > > There already is a patch by David Rivshin addressing the same issue... > > Here it is: > > https://patchwork.ozlabs.org/patch/943148/ > > but hasn't arrived in linux-next. That's because there'll be v3. > But it is questionable if a driver should dev_info() about doing deferred probing. > IMHO, it should just do it which is how Andreas' patch works. See here: https://patchwork.ozlabs.org/patch/949659/ > >> Fixes: b7290cf6ff78 (pwm: pwm-omap-dmtimer: Adapt driver to utilize dmtimer pdata ops) > >> Signed-off-by: Andreas Kemnade > >> --- > >> drivers/pwm/pwm-omap-dmtimer.c | 3 +-- > >> 1 file changed, 1 insertion(+), 2 deletions(-) > >> > >> diff --git a/drivers/pwm/pwm-omap-dmtimer.c b/drivers/pwm/pwm-omap-dmtimer.c > >> index 665da3c8fbce..808835179c2e 100644 > >> --- a/drivers/pwm/pwm-omap-dmtimer.c > >> +++ b/drivers/pwm/pwm-omap-dmtimer.c > >> @@ -264,8 +264,7 @@ 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; > >> + ret = -EPROBE_DEFER; > >> goto put; > >> } > >> > >> -- > >> 2.11.0 > >> > > BR, > Nikolaus >