EPROBE_DEFER and how it is supposed to work

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I'm not a newbie, but I am trying to understand the semantics of deferred probing.

My question is generic, but for an example:

Let's say I have a platform driver "A" for a device "a", that requires device "b" (controlled by driver "B") to be operational first. Both A &B can be built as part of kernel, or as modules independently.  As far as I could tell, there is no way to specify the ORDER in which the drivers' probe routines should be called. I took a look at modprobe / depmod, but it seems to be of relevance for modules only that are loaded from user space. My questions:

1) Is there a way to specify that "Kernel should call A's probe routine only after B's probe routine"?

2) How I currently do this: In A's probe routine, I currently check if the device "b" is available. If not, I return -EPROBE_DEFER. This mostly works ok. However, I'm curious about the case where the driver B is not built as part of the kernel but A is. After getting an _EPROB_DEFER from a B's probe routine, when will the kernel try again? And for how long would it keep on trying? I verified that if I load the driver B manually from user space, the A's probe routine does not get called (if it gets called now - it would have returned success!).

Thanks,

Rajat
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs




[Index of Archives]     [Audio]     [Hams]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Fedora Users]

  Powered by Linux