Re: sharp zaurus: prevent killing spitz-en

Pavel Machek
2005-10-25T23:14:53Z

Hi!

> > This is wrong solution, but it prevents breaking flashing mechanism on
> > spitz with too big kernel. It may be handy to someone...
> >
> > Pavel
> >
> > --- clean-rp/arch/arm/boot/Makefile 2004-12-25 13:34:57.000000000 +0100
> > +++ linux-rp/arch/arm/boot/Makefile 2005-10-25 20:43:58.000000000 +0200
> > @@ -53,6 +53,12 @@
> > $(obj)/zImage: $(obj)/compressed/vmlinux FORCE
> > $(call if_changed,objcopy)
> > @echo ' Kernel: $@ is ready'
> > + @ls -al $@
> > + @wc -c $@ | ( read SIZE Y; \
> > + if [ $$SIZE -gt 1294336 ]; then \
> > + echo ' Kernel is too big, would kill spitz'; \
> > + rm $@; \
> > + fi )
> >
> > endif
>
> It would be better for each machine to export an config option
> from the Kconfig to specify if they have a maximum size.

It is probably best to stop it at the flasher script, but ... this was
quite a quick hack.
Pavel
--
Thanks, Sharp!