After studying the code in net/ipv4/ipconfig.c I'm fairly confident
that the problem is caused by wait_for_devices() failing to find any
network interfaces and timing out. That function waits for 12 seconds
before giving up, and the time difference between the "IP-Config:
Entered" message and the end of the delay is just a hair over 12
seconds.
It makes sense that wait_for_devices() would fail: There are no
network devices until the initramfs loads the network interface
modules, and the initramfs init script doesn't start running until
after the kernel is done processing the ip=* argument.
So if the kernel fails to handle the ip=* argument, how does the ip=*
parameter work at all? The answer is the initramfs: The initramfs
init script parses the ip command-line argument and the
scripts/functions script runs the ipconfig utility with the
appropriate arguments to configure the interface.
I see a few ways to fix this:
* Modify the kernel source code to provide a way to change/disable
the timeout.
* Modify the kernel source code to allow the initramfs to load while
the kernel is still waiting for a network device to appear.
* Compile all network drivers into the kernel itself (don't build
them as modules).
* Modify the initramfs init script to introduce an alias for the
ip=* parameter, e.g., initramfs_ip=*. This would allow users to
avoid the pointless kernel processing.
The last option is probably the easiest and least likely to introduce
any unintended side effects.
After studying the code in net/ipv4/ipconfig.c I'm fairly confident
that the problem is caused by wait_for_devices() failing to find any
network interfaces and timing out. That function waits for 12 seconds
before giving up, and the time difference between the "IP-Config:
Entered" message and the end of the delay is just a hair over 12
seconds.
It makes sense that wait_for_devices() would fail: There are no
network devices until the initramfs loads the network interface
modules, and the initramfs init script doesn't start running until
after the kernel is done processing the ip=* argument.
So if the kernel fails to handle the ip=* argument, how does the ip=*
parameter work at all? The answer is the initramfs: The initramfs
init script parses the ip command-line argument and the
scripts/functions script runs the ipconfig utility with the
appropriate arguments to configure the interface.
I see a few ways to fix this:
* Modify the kernel source code to provide a way to change/disable
the timeout.
* Modify the kernel source code to allow the initramfs to load while
the kernel is still waiting for a network device to appear.
* Compile all network drivers into the kernel itself (don't build
them as modules).
* Modify the initramfs init script to introduce an alias for the
ip=* parameter, e.g., initramfs_ip=*. This would allow users to
avoid the pointless kernel processing.
The last option is probably the easiest and least likely to introduce
any unintended side effects.