public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Support for building individual .ko's would be nice :-)
@ 2004-04-20 18:59 Pekka Pietikainen
  2004-04-20 19:16 ` Marc Singer
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Pekka Pietikainen @ 2004-04-20 18:59 UTC (permalink / raw)
  To: sam; +Cc: linux-kernel

I was told you're the man to bug about this :-)

Having a slow box, a vendor kernel (+ kernel-source package with config
for it) and a need to modify one line of a module, recompile it,
replace existing module with it and continue business as usual
made me notice kbuild doesn't seem to have a facility for this.

What would be nice is (say)

cp configs/xxx-i686.config .config
emacs drivers/media/dvb/frontends/ves1820.c
make drivers/media/dvb/frontends/ves1820.ko
cp ves1820.ko /lib/modules/...
rmmod ves1820; modprobe ves1820 

Or am I missing something obvious that let me get just that one .ko
without recompiling just about everything? (.o is easy, but that's
not very useful :-) )

-- 
Pekka Pietikainen

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Support for building individual .ko's would be nice :-)
  2004-04-20 18:59 Support for building individual .ko's would be nice :-) Pekka Pietikainen
@ 2004-04-20 19:16 ` Marc Singer
  2004-04-20 19:42 ` Sam Ravnborg
  2004-04-20 19:57 ` Axel Weiss
  2 siblings, 0 replies; 4+ messages in thread
From: Marc Singer @ 2004-04-20 19:16 UTC (permalink / raw)
  To: Pekka Pietikainen; +Cc: sam, linux-kernel

On Tue, Apr 20, 2004 at 09:59:04PM +0300, Pekka Pietikainen wrote:
> I was told you're the man to bug about this :-)
> 
> Having a slow box, a vendor kernel (+ kernel-source package with config
> for it) and a need to modify one line of a module, recompile it,
> replace existing module with it and continue business as usual
> made me notice kbuild doesn't seem to have a facility for this.
> 
> What would be nice is (say)
> 
> cp configs/xxx-i686.config .config
> emacs drivers/media/dvb/frontends/ves1820.c
> make drivers/media/dvb/frontends/ves1820.ko
> cp ves1820.ko /lib/modules/...
> rmmod ves1820; modprobe ves1820 
> 
> Or am I missing something obvious that let me get just that one .ko
> without recompiling just about everything? (.o is easy, but that's
> not very useful :-) )

If you leave the compiled tree intact, all you need to do is modify
the one source file and then "make modules".  You'll wait a while the
first time, but successive builds will be minimal.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Support for building individual .ko's would be nice :-)
  2004-04-20 18:59 Support for building individual .ko's would be nice :-) Pekka Pietikainen
  2004-04-20 19:16 ` Marc Singer
@ 2004-04-20 19:42 ` Sam Ravnborg
  2004-04-20 19:57 ` Axel Weiss
  2 siblings, 0 replies; 4+ messages in thread
From: Sam Ravnborg @ 2004-04-20 19:42 UTC (permalink / raw)
  To: Pekka Pietikainen; +Cc: sam, linux-kernel

On Tue, Apr 20, 2004 at 09:59:04PM +0300, Pekka Pietikainen wrote:
> I was told you're the man to bug about this :-)
> 
> Having a slow box, a vendor kernel (+ kernel-source package with config
> for it) and a need to modify one line of a module, recompile it,
> replace existing module with it and continue business as usual
> made me notice kbuild doesn't seem to have a facility for this.
> 
> What would be nice is (say)
> 
> cp configs/xxx-i686.config .config
> emacs drivers/media/dvb/frontends/ves1820.c
> make drivers/media/dvb/frontends/ves1820.ko

Use
make drivers/media/dvb/frontends/

to just compile the module.

But then you need to do an:
make modules

which will build all modules. Here you need to tweak the .config to only
specify one module, the one you want.
Sorry, no better way today.

Keep a pre-built kernel is always a good choice.

	Sam

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Support for building individual .ko's would be nice :-)
  2004-04-20 18:59 Support for building individual .ko's would be nice :-) Pekka Pietikainen
  2004-04-20 19:16 ` Marc Singer
  2004-04-20 19:42 ` Sam Ravnborg
@ 2004-04-20 19:57 ` Axel Weiss
  2 siblings, 0 replies; 4+ messages in thread
From: Axel Weiss @ 2004-04-20 19:57 UTC (permalink / raw)
  To: linux-kernel; +Cc: Pekka Pietikainen

On Tuesday 20 April 2004 20:59, Pekka Pietikainen wrote:
> I was told you're the man to bug about this :-)
>
> Having a slow box, a vendor kernel (+ kernel-source package with config
> for it) and a need to modify one line of a module, recompile it,
> replace existing module with it and continue business as usual
> made me notice kbuild doesn't seem to have a facility for this.
>
> What would be nice is (say)
>
> cp configs/xxx-i686.config .config
> emacs drivers/media/dvb/frontends/ves1820.c
> make drivers/media/dvb/frontends/ves1820.ko

Never tried before, but I would suggest to run
make M=drivers/media/dvb/frontends
at this place.

> cp ves1820.ko /lib/modules/...
save your old module first!

> rmmod ves1820; modprobe ves1820
rmmod ves1820
lsmod	# module unloaded?
modprobe ves1820

>
> Or am I missing something obvious that let me get just that one .ko
> without recompiling just about everything? (.o is easy, but that's
> not very useful :-) )

BTW: (asking the experts here) is it legal to hack a module like this??

I'd prefer to compile the whole thing (over night)!

Axel


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-04-20 22:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-04-20 18:59 Support for building individual .ko's would be nice :-) Pekka Pietikainen
2004-04-20 19:16 ` Marc Singer
2004-04-20 19:42 ` Sam Ravnborg
2004-04-20 19:57 ` Axel Weiss

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox