mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: hufey <hufeyy@gmail.com>
To: linux-kernel@vger.kernel.org
Subject: Re: strange probe order issue after platform_add_devices()
Date: Thu, 23 Aug 2007 00:27:11 +0800	[thread overview]
Message-ID: <88dfed9d0708220927r40f4bc64t833a3383159387e9@mail.gmail.com> (raw)
In-Reply-To: <88dfed9d0708180729s1837b56brf81e905045039561@mail.gmail.com>

Seems never reach to the list...

On 8/18/07, hufey <hufeyy@gmail.com> wrote:
> Hi list,
>
> I am facing a very strange issue about device probe order.
> I have a piece of code to support network interface card for an embedded box.
>
> It likes following:
>
> ...
> static struct platform_device *custom_devices[] __initdata = {
>           &a_device,
>           &b_device,
>           &c_device,
> };
>
> static int __init device_init()
> {
>            return platform_add_devices(custom_devices,
> ARRAY_SIZE(custom_devices);
> }
>
> subsys_initcall(device_init);
>
> /* end */
>
> This code works good with kernel 2.6.11. After platform_add_devices()
> is executed, a_device's probe function will be called first then
> b_device's probe function be called.
> I merged it to 2.6.17, but strange thing is b_device's probe be called
> first always now.
> Since b_device probe depends on a_device, so it always fails now.
>
> Does anyone know how to fix it? Or give me the hint about how kernel
> decide which device be called to probe in order by what mechanism?
>
> Thanks in advance and best regards,
> hufeyy
>

      reply	other threads:[~2007-08-22 16:27 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-18 14:29 hufey
2007-08-22 16:27 ` hufey [this message]

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=88dfed9d0708220927r40f4bc64t833a3383159387e9@mail.gmail.com \
    --to=hufeyy@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®