devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Heiko Stübner" <heiko@sntech.de>
To: Doug Anderson <dianders@chromium.org>
Cc: "Addy Ke" <addy.ke@rock-chips.com>,
	"Rob Herring" <robh+dt@kernel.org>,
	"Pawel Moll" <pawel.moll@arm.com>,
	"Mark Rutland" <mark.rutland@arm.com>,
	"Ian Campbell" <ijc+devicetree@hellion.org.uk>,
	"Kumar Gala" <galak@codeaurora.org>,
	"Randy Dunlap" <rdunlap@infradead.org>,
	"Seungwon Jeon" <tgih.jun@samsung.com>,
	"Jaehoon Chung" <jh80.chung@samsung.com>,
	"Chris Ball" <chris@printf.net>,
	"Ulf Hansson" <ulf.hansson@linaro.org>,
	"Dinh Nguyen" <dinguyen@altera.com>,
	"Olof Johansson" <olof@lixom.net>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"linux-doc@vger.kernel.org" <linux-doc@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-mmc@vger.kernel.org" <linux-mmc@vger.kernel.org>,
	"zhenfu.fang" <zhenfu.fang@rock-chips.com>,
	"Eddie Cai" <cf@rock-chips.com>, lintao <lintao@rock-chips.com>,
	chenfen <chenfen@rock-chips.com>, zyf <zyf@rock-chips.com>,
	"Jianqun Xu" <xjq@rock-chips.com>,
	"Tao Huang" <huangtao@rock-chips.com>, Chris <zyw@rock-chips.com>,
	姚智情 <yzq@rock-chips.com>, "han jiang" <hj@rock-chips.com>,
	"Kever Yang" <kever.yang@rock-chips.com>,
	zhangqing <zhangqing@rock-chips.com>,
	"Lin Huang" <hl@rock-chips.com>
Subject: Re: [PATCH] mmc: dw_mmc: move rockchip related code to a separate file
Date: Fri, 15 Aug 2014 21:52:32 +0200	[thread overview]
Message-ID: <5377586.rAxPyABi4v@diego> (raw)
In-Reply-To: <CAD=FV=W-UFsELR-pLdqg+CC7bG8J3zCYa=fxy_4pd0vOnvc62w@mail.gmail.com>

Am Donnerstag, 14. August 2014, 10:09:55 schrieb Doug Anderson:
> Addy,
> 
> On Thu, Aug 14, 2014 at 1:01 AM, Addy Ke <addy.ke@rock-chips.com> wrote:
> > diff --git a/drivers/mmc/host/dw_mmc-rockchip.c
> > b/drivers/mmc/host/dw_mmc-rockchip.c new file mode 100644
> > index 0000000..3d86ef3
> > --- /dev/null
> > +++ b/drivers/mmc/host/dw_mmc-rockchip.c

[...]

> > +static int dw_mci_rockchip_probe(struct platform_device *pdev)
> > +{
> > +       const struct dw_mci_drv_data *drv_data;
> > +       const struct of_device_id *match;
> > +
> > +       match = of_match_node(dw_mci_rockchip_match, pdev->dev.of_node);
> 
> Your code doesn't have "if (pdev->dev.of_node)".  That's OK (I think)
> but it means that your KConfig needs a "depends on OF", right?

Almost all of_* functions have stubs for the !CONFIG_OF case [0].
Instead I guess this simply needs a

if (!pdev->dev.of_node)
	return -ENODEV;

to handle the case when there is no of_node.


Heiko


[0] http://lxr.free-electrons.com/source/include/linux/of.h#L585

  reply	other threads:[~2014-08-15 19:52 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-05 12:59 [PATCH] mmc: dw_mmc: add support for RK3288 addy ke
2014-07-07  2:07 ` Jaehoon Chung
2014-07-07  2:42   ` addy ke
2014-07-10  3:31 ` [PATCH v2] " Addy Ke
2014-07-29  4:52   ` Doug Anderson
2014-07-29 16:38     ` Doug Anderson
2014-07-31  6:01   ` [PATCH] " Addy Ke
2014-07-31 15:40     ` Doug Anderson
2014-08-12 12:17       ` Ulf Hansson
2014-08-07  8:47     ` Jaehoon Chung
     [not found]     ` <1406786498-3935-1-git-send-email-addy.ke-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2014-08-14  8:01       ` [PATCH] mmc: dw_mmc: move rockchip related code to a separate file Addy Ke
2014-08-14 12:16         ` Bartlomiej Zolnierkiewicz
2014-08-14 17:09         ` Doug Anderson
2014-08-15 19:52           ` Heiko Stübner [this message]
2014-08-19  4:36         ` [PATCH v2] " Addy Ke
2014-08-19  5:08           ` Jaehoon Chung
2014-08-19 17:28           ` Doug Anderson
2014-08-29 11:05             ` Ulf Hansson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5377586.rAxPyABi4v@diego \
    --to=heiko@sntech.de \
    --cc=addy.ke@rock-chips.com \
    --cc=cf@rock-chips.com \
    --cc=chenfen@rock-chips.com \
    --cc=chris@printf.net \
    --cc=devicetree@vger.kernel.org \
    --cc=dianders@chromium.org \
    --cc=dinguyen@altera.com \
    --cc=galak@codeaurora.org \
    --cc=hj@rock-chips.com \
    --cc=hl@rock-chips.com \
    --cc=huangtao@rock-chips.com \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=jh80.chung@samsung.com \
    --cc=kever.yang@rock-chips.com \
    --cc=lintao@rock-chips.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=olof@lixom.net \
    --cc=pawel.moll@arm.com \
    --cc=rdunlap@infradead.org \
    --cc=robh+dt@kernel.org \
    --cc=tgih.jun@samsung.com \
    --cc=ulf.hansson@linaro.org \
    --cc=xjq@rock-chips.com \
    --cc=yzq@rock-chips.com \
    --cc=zhangqing@rock-chips.com \
    --cc=zhenfu.fang@rock-chips.com \
    --cc=zyf@rock-chips.com \
    --cc=zyw@rock-chips.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).