linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [ANNOUNCE] Diet /sbin/hotplug package released
@ 2001-08-29 19:04 Greg KH
  2001-08-30  5:12 ` Aaron Lehmann
  0 siblings, 1 reply; 9+ messages in thread
From: Greg KH @ 2001-08-29 19:04 UTC (permalink / raw)
  To: linux-hotplug-devel, linux-kernel

I'd like to announce the initial version of the Diet /sbin/hotplug
package.  It can be found at:
	http://prdownloads.sourceforge.net/linux-hotplug/diethotplug-0.1.tar.gz

Q: What is it?
A: It's a replacement for the current linux-hotplug script package.  It
   is written in C and if compiled with dietLibc[0], can produce a very
   small program.

   For instance, on my machine the /lib/modules/2.4.9-ac3/modules.usbmap
   is 59221 bytes.  The current linux-hotplug system needs this file,
   plus all of the linux-hotplug scripts and bash and awk to work.
   diethotplug compiles to about 20K on my machine and does not need
   modules.usbmap or any other helper programs to work.

Q: Will this replace the current linux-hotplug script package?
A: NO!  The current linux-hotplug scripts work quite well in a general
   purpose machine.  They do not need to be modified for each kernel
   version, and allow users to add their own scripts quite easily.
   
   The diethotplug program is only useful for systems that have memory
   constraints, do not have awk or bash, and do not change kernel
   versions (as the modules.pcimap and modules.usbmap are compiled into
   the program.)  Embedded systems and the upcoming 2.5 initrd method of
   kernel booting are good applications for this program.

Currently usb module loading works (tested on my limited range of
devices.)  More testing on other usb devices is most welcome.  PCI
loading of modules is next on the list of things to do.

thanks,

greg k-h

[0] http://www.fefe.de/dietlibc/

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

* Re: [ANNOUNCE] Diet /sbin/hotplug package released
  2001-08-29 19:04 [ANNOUNCE] Diet /sbin/hotplug package released Greg KH
@ 2001-08-30  5:12 ` Aaron Lehmann
  2001-08-30  5:22   ` Greg KH
  0 siblings, 1 reply; 9+ messages in thread
From: Aaron Lehmann @ 2001-08-30  5:12 UTC (permalink / raw)
  To: Greg KH; +Cc: linux-kernel

On Wed, Aug 29, 2001 at 12:04:40PM -0700, Greg KH wrote:
>    is 59221 bytes.  The current linux-hotplug system needs this file,
>    plus all of the linux-hotplug scripts and bash and awk to work.

Hrm, why does it use bash-specific shell features? That's very bad.
POSIX would be a much cleaner spec to conform to.

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

* Re: [ANNOUNCE] Diet /sbin/hotplug package released
  2001-08-30  5:12 ` Aaron Lehmann
@ 2001-08-30  5:22   ` Greg KH
  2001-08-30  5:27     ` Aaron Lehmann
  0 siblings, 1 reply; 9+ messages in thread
From: Greg KH @ 2001-08-30  5:22 UTC (permalink / raw)
  To: Aaron Lehmann; +Cc: linux-kernel

On Wed, Aug 29, 2001 at 10:12:46PM -0700, Aaron Lehmann wrote:
> On Wed, Aug 29, 2001 at 12:04:40PM -0700, Greg KH wrote:
> >    is 59221 bytes.  The current linux-hotplug system needs this file,
> >    plus all of the linux-hotplug scripts and bash and awk to work.
> 
> Hrm, why does it use bash-specific shell features? That's very bad.
> POSIX would be a much cleaner spec to conform to.

I don't know if it uses bash-specific features, I haven't tried it on
any other shell (and am not the main author of the shell scripts).

Why would POSIX "cleanness" matter for these scripts?

thanks,

greg k-h

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

* Re: [ANNOUNCE] Diet /sbin/hotplug package released
  2001-08-30  5:22   ` Greg KH
@ 2001-08-30  5:27     ` Aaron Lehmann
  2001-08-30  5:27       ` Greg KH
  0 siblings, 1 reply; 9+ messages in thread
From: Aaron Lehmann @ 2001-08-30  5:27 UTC (permalink / raw)
  To: Greg KH; +Cc: linux-kernel

On Wed, Aug 29, 2001 at 10:22:06PM -0700, Greg KH wrote:
> Why would POSIX "cleanness" matter for these scripts?

Believe it or not, some people don't use bash as /bin/sh, or at all.
I notice that /etc/hotplug/hotplug.functions uses #!/bin/bash, which
is better than pretending to be an "sh" script and using bashisms.

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

* Re: [ANNOUNCE] Diet /sbin/hotplug package released
  2001-08-30  5:27     ` Aaron Lehmann
@ 2001-08-30  5:27       ` Greg KH
  2001-08-30 10:47         ` Stefan Fleiter
  0 siblings, 1 reply; 9+ messages in thread
From: Greg KH @ 2001-08-30  5:27 UTC (permalink / raw)
  To: Aaron Lehmann; +Cc: linux-kernel

On Wed, Aug 29, 2001 at 10:27:26PM -0700, Aaron Lehmann wrote:
> On Wed, Aug 29, 2001 at 10:22:06PM -0700, Greg KH wrote:
> > Why would POSIX "cleanness" matter for these scripts?
> 
> Believe it or not, some people don't use bash as /bin/sh, or at all.
> I notice that /etc/hotplug/hotplug.functions uses #!/bin/bash, which
> is better than pretending to be an "sh" script and using bashisms.

I realize that not all /bin/sh is really bash, that's why the scripts
explicitly ask for bash.  I'm guessing some bashisms are in there :)

thanks,

greg k-h

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

* Re: [ANNOUNCE] Diet /sbin/hotplug package released
  2001-08-30  5:27       ` Greg KH
@ 2001-08-30 10:47         ` Stefan Fleiter
  2001-08-30 15:21           ` Alex Bligh - linux-kernel
  0 siblings, 1 reply; 9+ messages in thread
From: Stefan Fleiter @ 2001-08-30 10:47 UTC (permalink / raw)
  To: linux-kernel

Hi Greg!

On Wed, 29 Aug 2001 Greg KH wrote:

> I realize that not all /bin/sh is really bash, that's why the scripts
> explicitly ask for bash.  I'm guessing some bashisms are in there :)

Does it really make any sense to optimize for size and at the same time
force the user to install a bash compatible shell?

Stefan

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

* Re: [ANNOUNCE] Diet /sbin/hotplug package released
  2001-08-30 10:47         ` Stefan Fleiter
@ 2001-08-30 15:21           ` Alex Bligh - linux-kernel
  2001-08-30 20:51             ` Greg KH
  2001-08-30 20:56             ` Stefan Fleiter
  0 siblings, 2 replies; 9+ messages in thread
From: Alex Bligh - linux-kernel @ 2001-08-30 15:21 UTC (permalink / raw)
  To: Stefan Fleiter, linux-kernel; +Cc: Alex Bligh - linux-kernel



--On Thursday, August 30, 2001 12:47 PM +0200 Stefan Fleiter 
<stefan.fleiter@gmx.de> wrote:

> Does it really make any sense to optimize for size and at the same time
> force the user to install a bash compatible shell?

No, that's why diet /sbin/hotplug didn't require any shell (as I understood
it), whereas the normal hotplug suite does.

--
Alex Bligh

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

* Re: [ANNOUNCE] Diet /sbin/hotplug package released
  2001-08-30 15:21           ` Alex Bligh - linux-kernel
@ 2001-08-30 20:51             ` Greg KH
  2001-08-30 20:56             ` Stefan Fleiter
  1 sibling, 0 replies; 9+ messages in thread
From: Greg KH @ 2001-08-30 20:51 UTC (permalink / raw)
  To: Stefan Fleiter, linux-kernel

On Thu, Aug 30, 2001 at 04:21:48PM +0100, Alex Bligh - linux-kernel wrote:
> 
> 
> --On Thursday, August 30, 2001 12:47 PM +0200 Stefan Fleiter 
> <stefan.fleiter@gmx.de> wrote:
> 
> > Does it really make any sense to optimize for size and at the same time
> > force the user to install a bash compatible shell?
> 
> No, that's why diet /sbin/hotplug didn't require any shell (as I understood
> it), whereas the normal hotplug suite does.

Exactly.  diethotplug does not require any shell or awk to be present to
work.  It compiles to a binary which is smaller than the existing
modules.usbmap file is (and can get smaller, I haven't started to
optimize for space yet.)

To help clear up a few questions I've been getting, diethotplug is for
systems that care about space, like embedded or boot rescue discs.  It
will also be handy for loading PCI and USB kernel modules at boot time
based on what devices are present in the system, with the upcoming 2.5
initrd method.

It is not a replacement for the current linux-hotplug scrips, but
another alternative for situations that they didn't make sense.

thanks,

greg k-h

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

* Re: [ANNOUNCE] Diet /sbin/hotplug package released
  2001-08-30 15:21           ` Alex Bligh - linux-kernel
  2001-08-30 20:51             ` Greg KH
@ 2001-08-30 20:56             ` Stefan Fleiter
  1 sibling, 0 replies; 9+ messages in thread
From: Stefan Fleiter @ 2001-08-30 20:56 UTC (permalink / raw)
  To: Alex Bligh - linux-kernel; +Cc: linux-kernel

Hi Alex!

On Thu, 30 Aug 2001 Alex Bligh - linux-kernel wrote:

>> Does it really make any sense to optimize for size and at the same time
>> force the user to install a bash compatible shell?
> No, that's why diet /sbin/hotplug didn't require any shell (as I understood
> it), whereas the normal hotplug suite does.

Oh. That really makes sense...

Stefan, a bit ashamed...

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

end of thread, other threads:[~2001-08-30 21:44 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-08-29 19:04 [ANNOUNCE] Diet /sbin/hotplug package released Greg KH
2001-08-30  5:12 ` Aaron Lehmann
2001-08-30  5:22   ` Greg KH
2001-08-30  5:27     ` Aaron Lehmann
2001-08-30  5:27       ` Greg KH
2001-08-30 10:47         ` Stefan Fleiter
2001-08-30 15:21           ` Alex Bligh - linux-kernel
2001-08-30 20:51             ` Greg KH
2001-08-30 20:56             ` Stefan Fleiter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).