1. 16

  2. 1

    Nice read, what exactly happens if there are multiple drivers claiming device support? Will it be a first come first serve kinda situation?

    1. 4

      First come first serve. If a device is already paired with a module, the driver’s probe() function is skipped [1]. As a side effect of being part of the kernel image, builtin modules get the first shot at it. Of the builtins, the order they’re served is the order in which they’re linked in to the kernel [2].

      [1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/base/dd.c#n943 [2] https://lwn.net/Articles/260856/