initramfs 'pro' needed

Doug Hunley doug.hunley at gmail.com
Sat Apr 21 14:29:13 PDT 2012


On Fri, Apr 20, 2012 at 20:41, David A. Bandel <david.bandel at gmail.com> wrote:
> On Fri, Apr 20, 2012 at 08:25, Doug Hunley <doug.hunley at gmail.com> wrote:
>> I recently started booting via initrams (thanks to the udev 'no
>> separate /usr' shit) and it works fine. However, I have a new issue
>> that requires me to recompile nouveau as a module (it's currently
>> compiled-in to the kernel as I don't use modules if I can avoid it). I
>> can easily enough flip the bits in the kernel compile to make it a
>> module, that's no biggie. However, I'm not sure what I need to do to
>> my initramfs to get the module included. ;)
>
> Q:  your distro?  Debian and derivatives (Ubuntu, Mint, etc.) have all
> in /etc/initramfs-tools/initramfs.conf and with modules in the modules
> file.

Gentoo

>
>>
>> I'm using an init.cfg (attached) to have the kernel build the
>
> ?? kernel doesn't build initrd.img, that's the job of update-initramfs
> or similar script run during kernel upgrades (or on a whim from cli).

Yes, it can. If you point the kernel at the config file like so:
CONFIG_INITRAMFS_SOURCE="/usr/src/init.cfg"
then it parses that file and builds the initramfs into the kernel
itself and fetches whatever files/nodes are in that config

It's pretty slick actually

I've attached my init.sh that goes into the initramfs. I know that I
can 'modprobe <foo>' from within this script. That's the easy part.
What I need to know is how to add to the init.cfg such that
/lib/modules/`uname -r`/<module> is copied into the correct place in
the initramfs so that modprobe can find it ;)

Also, please don't confuse initramfs and initrd. Not the same. Similar though.
-- 
Douglas J Hunley (doug.hunley at gmail.com)
Twitter: @hunleyd                                               Web:
douglasjhunley.com
G+: http://goo.gl/sajR3
-------------- next part --------------
A non-text attachment was scrubbed...
Name: init.sh
Type: application/x-sh
Size: 772 bytes
Desc: not available
Url : http://mailman.celestial.com/pipermail/linux-users/attachments/20120421/09a6f0e8/attachment-0001.sh 


More information about the Linux-users mailing list