Linux-Development-Sys Digest #724, Volume #7      Sat, 1 Apr 00 15:13:15 EST

Contents:
  Re: Zero padding in sprintf() doesn't work for strings - HELP ! (Juergen Heinzl)
  What's the difference between bzImage and zImage ("JKFang")
  Need a good Kernel Book that explains the dynamic loader ([EMAIL PROTECTED])
  Re: System.map location ("D. Stimits")
  Re: Precision of Linux's libm??? (Johan Kullstam)
  Re: Linux or Windows (Anthony Aicardi)
  Re: What's the difference between bzImage and zImage (John Reiser)
  not able to get changes after kernel build ([EMAIL PROTECTED])
  Re: Free BSD (Dan McGuirk)
  Bash compile errors please help ([EMAIL PROTECTED])
  Re: Getting IP address of self in C? (Lew Pitcher)
  Re: software raid patch (Dieter Rohlfing)
  gdb and threads ("simno")
  Re: Free BSD (Robert Redelmeier)
  Re: Free BSD (Mario Klebsch)
  Need a good book or document for x86 __asm__ syntax! ("Rocky Lin")
  Re: Need a good book or document for x86 __asm__ syntax! (Bryan Hackney)
  About Protected Mode ?? ("JKFang")
  Re: Bash compile errors please help (Paul Kimoto)
  Re: 2.3.99: what's next step? (Paul Kimoto)

----------------------------------------------------------------------------

From: [EMAIL PROTECTED] (Juergen Heinzl)
Crossposted-To: comp.os.linux.development.apps
Subject: Re: Zero padding in sprintf() doesn't work for strings - HELP !
Date: Sat, 01 Apr 2000 00:56:11 GMT

In article <[EMAIL PROTECTED]>, Stephen Harris wrote:
>Juergen Heinzl ([EMAIL PROTECTED]) wrote:
>: In article <8briic$ofu$[EMAIL PROTECTED]>, bill davidsen wrote:
>
>[ Re 0 padding of strings ]
>
>: >  Another reason why it should be changed. Both AIX and hp-ux pad with
>: >zeros as expected, so it would be at minimum acceptable to do it that
>
>
>: ... conversions and the same as far as the Unix98 specification
>: is concerned, so your installations of AIX and HP-UX are doing it
>: wrong and you might see whether there is an appropriate patch.
>
>Solaris 7 does it with zero's as well, although the manpage doesn't
>say it should :-)
>
>It sort of makes sense - if you want space padding, then the default syntax
>without a zero does that for you.

I can only hope though you are aware any binary dependent on a bug
is free to fail on site if the installation in question has had its
libc updated.

Now might be we should ask Microsoft the next time, finally their
customer base is quite large, so they ought to know what real C and
real C++ is ?

Yes, sure, ridiculous ... you get the idea though.

Now glibc provides some hooks and IMHO if unofficial behaviour
is required, then use a roll your own approach. Never mind, but
while I like a good and well done hack, I do not buy the "The
language is, what my compiler implements" approach at all.

Cheers,
Juergen

-- 
\ Real name     : J�rgen Heinzl                 \       no flames      /
 \ EMail Private : [EMAIL PROTECTED] \ send money instead /

------------------------------

From: "JKFang" <[EMAIL PROTECTED]>
Subject: What's the difference between bzImage and zImage
Date: Sat, 1 Apr 2000 09:14:25 +0800

When kernal is compiled, if keranl exceed 448 kb, We have to compile it to
bzImage.
And source code tell me that it will high load to 0x100000 instead of 0x1000
( the default place of zImage)

Why not just put bzImage on 0x1000.
In short, why have to distinguish between zImage and bzImage ??



------------------------------

From: [EMAIL PROTECTED]
Subject: Need a good Kernel Book that explains the dynamic loader
Date: Sat, 01 Apr 2000 02:40:41 GMT

I need a good linux kernel book that will explain how the dynamic loader
works. I'm currently working on a port and I'm having trouble with the
dynamic loader, ld.so.6 to be exact.  I know the problem is with paging
routines.  It seems to be running out of stack space.  A good book or a
pointer to a site that explains how the dynamic loader works would be a
big help.

Thanks,
Mark


------------------------------

Date: Fri, 31 Mar 2000 19:55:04 -0700
From: "D. Stimits" <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
Subject: Re: System.map location

Moritz Franosch wrote:
> 
> "D. Stimits" <[EMAIL PROTECTED]> writes:
> 
> > I'm trying to find out where in the kernel it decides that it must
> > read /boot/System.map, so I can create alternate locations and names.
> > I'd like to boot multiple kernels without having to repoint sym links
> > first.
> 
> You can call the file System.map-`uname -r` (e.g. System.map-2.2.14).
> 
> Moritz

So far this seems to work best. It simply requires compiling the
EXTRAVERSION info into each kernel. My only problem with this is that
all kernels must have different minor versioning added to them. If
System.map could be explicitly stated at one location (each
application using System.map has its own search hierarchy *compiled*
in, rather than using a query from the kernel or a config file),
kernels and System.map files could be stored as pairs, in a more
organized sub directory structure, like /boot/2.2.14/smp/,
/boot/2.2.14/uni/, so on.

Admittedly though, this is a bit of nitpicking. I wouldn't have even
noticed it if not for the number of testing configurations I've gone
through lately. Modules that are not part of the kernel require
recompiling for every minor version number, even if the rest of the
changes in the kernel are irrelevant to the module.

------------------------------

Crossposted-To: comp.os.linux.misc,comp.os.linux.development.apps
Subject: Re: Precision of Linux's libm???
From: Johan Kullstam <[EMAIL PROTECTED]>
Date: Sat, 01 Apr 2000 02:56:23 GMT

Harlan Grove <[EMAIL PROTECTED]> writes:

> In article <[EMAIL PROTECTED]>, Johan Kullstam
> <[EMAIL PROTECTED]> wrote:
> 
> <snip>
> 
> >correct me if i'm wrong but
> >1) internally, the ia32 is a bit faster with smaller
> > float setting.
> 
> Shouldn't be in terms of calculation, but may be in terms
> of moving data between the FPU and memory. My old book on
> Intel 8087 assembler says all internal operations are 80
> bit, so even if data is stored as 32-bit floats, the FPU
> will convert them to 80 bits before using them.

the FPU can be put into 64 bit mode by setting the proper bit in its
control word.

> >2) 10 byte quantities do not align on power of two
> > boundaries very well.  using 80 bits, choose your poison:
> >      - double rounding
> >      - aligned with lots of wasted space
> >      - packed with poor performance
> 
> But if the bulk of or the entire data for a particular
> calculation were stored in the CPU cache, would there be a
> significant performance problem with packed data? The CPU
> would load/store several KB of memory at a time, so the
> only plausible drag would come from cache-FPU load/store
> operations. [Granted not all Intel-based linux machines
> have CPU memory caches.]

why do we bother with data alignment at all?  64 bit double-precision
load/store on aligned memory is much faster than unaligned.  why does
gcc bother otherwise?

-- 
J o h a n  K u l l s t a m
[[EMAIL PROTECTED]]
Don't Fear the Penguin!

------------------------------

From: Anthony Aicardi <[EMAIL PROTECTED]>
Crossposted-To: 3dfx.linux.apps.other
Subject: Re: Linux or Windows
Date: Sat, 01 Apr 2000 04:18:02 GMT

The learning curve can be a little steep at first so I would read all=20
I could on Linux.  =20
(Linux for dummies is agood start) No offense.
Running Linux third edition Oreilly Books is in my humble opinion
one of the best books on Linux.=20

Alt.os.linux.caldera has a nice faq's and how to on just what you are=20
wanting to accomplish.
alt.os.linux newsgroup is a good place to go as well.
Good luck
/tony
>>>>>>>>>>>>>>>>>> Original Message <<<<<<<<<<<<<<<<<<

On 2/24/00, 8:35:02 AM, "RH" <[EMAIL PROTECTED]> wrote regarding=20
Linux or Windows:


> I am debating wheather to run Linux on my computer or to stick with=20
windows.
> I know very little about linux and want to know which is best.  I want=
=20
to be
> able to run it on the same computer as windows. Help please.
> RH
> [EMAIL PROTECTED]
> Visit our home page at www.pwr.org.uk




------------------------------

From: John Reiser <[EMAIL PROTECTED]>
Subject: Re: What's the difference between bzImage and zImage
Date: Fri, 31 Mar 2000 20:38:58 -0800

JKFang wrote:
> 
> When kernal is compiled, if keranl exceed 448 kb, We have to compile it to
> bzImage.
> And source code tell me that it will high load to 0x100000 instead of 0x1000
> ( the default place of zImage)
> 
> Why not just put bzImage on 0x1000.
> In short, why have to distinguish between zImage and bzImage ??

It is much easier for both the Linux kernel and the various bootstrap loaders
if the destination for bootstrap loading is one contiguous interval of memory
addresses.  Because of BIOS history and conventions for disk booting, the
first 64KB of physical address space from 0x0 to 0x10000 is considered to
have reserved uses (such as the BIOS disk boot running at 0x7c00).
The famous 640KB limit for "low memory" on a PC means that one cannot depend
on the contents of 0xA0000 thru 0x100000.  Also, the 64KB from 0x90000
to 0xA0000 is used for parameter passing among the BIOS/bootstrap/kernel.
Thus, there is only 512KB (0x80000) of low memory (from 0x10000 to 0x90000)
that is usable, and zImage goes there.  Anything bigger (bzImage) must go
somewhere else.  The chosen address was 0x100000, although it would have
been better to pick 0x110000, again because of historical PC "high memory"
considerations.

------------------------------

From: [EMAIL PROTECTED]
Subject: not able to get changes after kernel build
Date: Sat, 01 Apr 2000 06:00:13 GMT

Hello,
In kernel's(2.2.12) source there is file /net/ipv4/protocol.c which
includes one routine called inet_get_protocol. But
the /include/net/protocol.h have no prototype for the same. Because of
which I am not able to use this routine. To make use of this I have
inserted the same into .h file and rebuild the kernel. After this also
I am getting the error as 'inet_getprotocol symbol not found'. Can
anyone tell me how to do this ?
Thanks in advance,
Bhagyashree


Sent via Deja.com http://www.deja.com/
Before you buy.

------------------------------

From: Dan McGuirk <[EMAIL PROTECTED]>
Subject: Re: Free BSD
Date: Fri, 31 Mar 2000 22:29:36 -0800

Mario Klebsch wrote:
> Linkux is just a kernel, FreeBSD is a complete operating system. The
> rating is left to the reader. :-)

Well, FreeBSD uses gcc and glibc too.  So don't you mean the
"GNU/FreeBSD System"?

-- 
Dan McGuirk  <[EMAIL PROTECTED]>

De omnibus dubitandum est.

------------------------------

From: [EMAIL PROTECTED]
Subject: Bash compile errors please help
Date: Sat, 01 Apr 2000 06:50:05 GMT

I have downloaded bash-2.03 archieve from ftp site. I unpacked it on
the machine running Redhat 6.1. The configured it with './configure --
enable-static-link' command. When I tried to generate the executable
file by issuing make command it did not complie. Following message was
given:
# make
/bin/sh ./support/mkversion.sh -b -s release -d 2.03 -p 0 -o
newversion.h \
&& mv newversion.h version.h
***********************************************************
* *
* Making Bash-2.03.0-release for a i686 running linux-gnu
* *
***********************************************************
rm -f shell.o
gcc -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"i686"' -DCONF_OSTYPE='"linux-
gnu"' -DC
ONF_MACHTYPE='"i686-pc-linux-gnu"' -DCONF_VENDOR='"pc"' -DSHELL -
DHAVE_CONFIG_H
-D_FILE_OFFSET_BITS=64 -I. -I. -I./lib -I/usr/local/include -g -O2 -
c shell.c
In file included from shell.h:37,
from shell.c:53:
externs.h:131: conflicting types for `strncasecmp'
/usr/include/string.h:266: previous declaration of `strncasecmp'
externs.h:138: conflicting types for `gethostname'
/usr/include/unistd.h:733: previous declaration of `gethostname'
externs.h:146: conflicting types for `setlinebuf'
/usr/include/stdio.h:242: previous declaration of `setlinebuf'
make: *** [shell.o] Error 1
Then I transferred the archive on another machine running RedHat 6.0
where I followed the same sequence and it compiled without any trouble.
I want to compile it on the machine running redhat 6.1.
What is wrong? Both machines have gcc 2.91.66.
Rajendra Jadhao


Sent via Deja.com http://www.deja.com/
Before you buy.

------------------------------

From: Lew Pitcher <[EMAIL PROTECTED]>
Subject: Re: Getting IP address of self in C?
Date: Sat, 01 Apr 2000 07:23:13 GMT

Kaz Kylheku wrote:
> 
> On Fri, 31 Mar 2000 01:27:56 GMT, Pete Cavender <[EMAIL PROTECTED]> wrote:
> >Hi-
> >
> >How can I get my IP address from C?  I used to use gethostid() but with
> >newer kernels that doesn't seem to work...I can run ifconfig and dig
> >through the text and look for it, bu there has to be a C way...  Thanks!
> 
> You might not be aware of this, but it's possible for a machine to have many IP
> addresses. This is true even if it only has one network adapter, thanks to IP
> aliasing. 

Kaz, I'm shocked.

Think loopback _and_ ethernet: two addresses (127.0.0.1 _and_
your.eth.ip.addr)

> So you may have to rethink your problem.
> 
> For most networking applications, a program doesn't need to determine the IP
> address of the local machine; it's almost always a bad idea to try to send a
> local IP to a remote machine. These days more than ever, such addresses are
> likely to be wrong, thanks to the spread of network address translating
> firewalls.
> 
> --
> #exclude <windows.h>

-- 
Lew Pitcher

Master Codewright and JOAT-in-training

------------------------------

From: [EMAIL PROTECTED] (Dieter Rohlfing)
Subject: Re: software raid patch
Date: Sat, 1 Apr 2000 13:35:06 +0200
Reply-To: [EMAIL PROTECTED]

On 29 Mar 2000 19:47:21 GMT, bill davidsen <[EMAIL PROTECTED]> wrote:

>In article <[EMAIL PROTECTED]>,
>D. Stimits <[EMAIL PROTECTED]> wrote:
>| It appears that the software raid 0 patch (e.g., raidtools with
>| raid0145-19990824-2.2.11) is still not part of the kernel at 2.2.14.
>| Anyone know if software raid for striping will be built into the
>| kernel soon, since it is a time-consuming to manually adjust these
>| patches to work on newer kernels?
>
>  RAID-0 is already built into the kernel. You are using the wrong
>toolset, which in turn requires the patches. See the "md" stuff.

I'm not quite sure about your statement.

On one Linux box I'm running Suse 5.1 with a 2.0.38 kernel and the
mdutils-0.35 (included in Suse 5.1). This combo works flawlessly. :-)

On another Linux box I installed RedHat 5.2 and they offered the mdutils
and the raid-tools. I wondered about the difference between both packages
and read the docs. For me it seems, that the raid-tools supercede the
mdutils. So, for the future the mdtools will be obsolete. Did I miss
anything? Can someone jump in and clearify?

Under RedHat 5.2 I want to run kernel 2.2.14, and therefore the question
about the right raid-tools and/or kernel patches is essential for me.

Dieter Rohlfing

------------------------------

From: "simno" <[EMAIL PROTECTED]>
Subject: gdb and threads
Date: Sat, 1 Apr 2000 14:35:37 +0100

Whenever I try to debug a program with threads, gdb traps
an unknown signal in sigsuspend.c. The threads keep running,
however the main program locks solid. All works well
without gdb (except for a seg fault I'm trying to track down).

Is there any way of getting gdb to ignore unknown signals?



------------------------------

From: Robert Redelmeier <[EMAIL PROTECTED]>
Subject: Re: Free BSD
Date: Sat, 01 Apr 2000 07:45:30 -0600

Dan McGuirk wrote:
> Well, FreeBSD uses gcc and glibc too.  So don't you mean the
> "GNU/FreeBSD System"?

I asked RMS himself on the subject and he said no, it isn't
GNU/*BSD .

I know *BSD uses BSD utils, not GNU utils.  I know *BSD uses
`gcc`.  I have conflicting reports on whether BSD has it's 
own libs.  FreeBSD uses glibc for Linux compatibility (when
intalled).

-- Robert

------------------------------

From: [EMAIL PROTECTED] (Mario Klebsch)
Subject: Re: Free BSD
Date: Sat, 1 Apr 2000 14:53:39 +0200

Dan McGuirk <[EMAIL PROTECTED]> writes:

>Mario Klebsch wrote:
>> Linkux is just a kernel, FreeBSD is a complete operating system. The
>> rating is left to the reader. :-)

>Well, FreeBSD uses gcc and glibc too.  So don't you mean the
>"GNU/FreeBSD System"?

I know only one OS called FreeBSD and no other OS containing FreeBSD
in its name.

73, Mario
-- 
Mario Klebsch                                           [EMAIL PROTECTED]

------------------------------

From: "Rocky Lin" <[EMAIL PROTECTED]>
Subject: Need a good book or document for x86 __asm__ syntax!
Date: Sun, 2 Apr 2000 01:27:41 +0800

I found some x86 assembly instructions of __asm__ section in kernel files.
And there
is some explain of the syntax in Documents/excepation.txt.
But I do need a good book or some documents for detail explan of the syntax.
Woudl you please help me?

Thanks and Best Regards,
Rocky.




------------------------------

From: Bryan Hackney <[EMAIL PROTECTED]>
Subject: Re: Need a good book or document for x86 __asm__ syntax!
Date: Sat, 01 Apr 2000 12:01:33 -0600

Rocky Lin wrote:
> 
> I found some x86 assembly instructions of __asm__ section in kernel files.
> And there
> is some explain of the syntax in Documents/excepation.txt.
> But I do need a good book or some documents for detail explan of the syntax.
> Woudl you please help me?
> 
> Thanks and Best Regards,
> Rocky.

Start here:

http://www.gnu.org/software/gcc/onlinedocs/gcc_4.html#SEC96

Go to Intel to get the x86 reference, if you need that.

Watch out for things like mov x,y vs mov y,x. They mean
the same thing to different folks.


-- 
                                 Bryan Hackney / BHC / [EMAIL PROTECTED]
                                        http://www.FreeClassAds.com/
                                        http://bhconsult.com/
                                        http://bhconsult.com/bh/pgp.key

------------------------------

From: "JKFang" <[EMAIL PROTECTED]>
Subject: About Protected Mode ??
Date: Sun, 2 Apr 2000 02:41:52 +0800

In Setup.S,
 lmsw ax  (ax=1 ), so we cut into protected mode..

Now comes my question ==>
(1). Just after running LMSW, I guess the CPU accessses memory as 8086
(where CS*16+IP.)
      Only After we reload cs by far jmp, then CPU ACTUALLY accesses memoey
via GDT.
      And then CPU really work on 32-bit Code ..
      Is my guess right ?

(2). Friends on net tell me zImage is put on 0x10000 (ie. 64k  absoloute
address),
      But the source reload the CS by  =>
                 db      0x66,0xea       ! prefix + jmpi-opcode
     code32: dd      0x1000
This line is strange. it should be 0x10000 not 0x1000, it should means
offset not a segment ???
Is anything wrong with my idea ??
                  dw      KERNEL_CS
     ( mixed 16-32 bits, by so it can jump to bzImage, too .. I guess)
============================================================================
=========
            KERNEL_CS  is a index to GDT , which means BASE address is
0x0000



------------------------------

From: [EMAIL PROTECTED] (Paul Kimoto)
Subject: Re: Bash compile errors please help
Date: 1 Apr 2000 14:33:21 -0500
Reply-To: [EMAIL PROTECTED]

In article <8c466q$n4q$[EMAIL PROTECTED]>, [EMAIL PROTECTED] wrote:

[Note: this is not really a c.o.l.d.system matter.]

> I have downloaded bash-2.03 archieve from ftp site. I unpacked it on
> the machine running Redhat 6.1. The configured it with './configure --
> enable-static-link' command.
 [...]
> In file included from shell.h:37,
> from shell.c:53:
> externs.h:131: conflicting types for `strncasecmp'
> /usr/include/string.h:266: previous declaration of `strncasecmp'
> externs.h:138: conflicting types for `gethostname'
> /usr/include/unistd.h:733: previous declaration of `gethostname'
> externs.h:146: conflicting types for `setlinebuf'
> /usr/include/stdio.h:242: previous declaration of `setlinebuf'
> make: *** [shell.o] Error 1
> Then I transferred the archive on another machine running RedHat 6.0
> where I followed the same sequence and it compiled without any trouble.
> I want to compile it on the machine running redhat 6.1.
> What is wrong? Both machines have gcc 2.91.66.

I believe that RH6.0 and RH6.1 use different versions of the C library
(glibc).  The newer version probably has corrections that the bash source
code doesn't know about.  (If you read C, take a look at the referenced
lines.)

I don't know why the bash source code needs to have its own function
prototypes, but perhaps it is for compatibility with old, wacky systems.
In any case, there is a recent bash-2.04 that may compile more cleanly with
current glibcs.

-- 
Paul Kimoto             <[EMAIL PROTECTED]>

------------------------------

From: [EMAIL PROTECTED] (Paul Kimoto)
Subject: Re: 2.3.99: what's next step?
Date: 1 Apr 2000 14:57:11 -0500
Reply-To: [EMAIL PROTECTED]

In article <[EMAIL PROTECTED]>, Toby Haynes wrote:
> !! "bill" == bill davidsen <[EMAIL PROTECTED]> writes:
>
>  bill>   Linux has perhaps the best development team around, but but
>  bill> they do code stuff without doing design first, and they not
>  bill> only don't do QA before letting out code, they rejected an
>  bill> offer to have a group do it when a new release was ready. I
>  bill> tried, not going to try again.

> Well - if this is an itch you wish to scratch, set up a site which
> does QA on the latest available kernel and posts the latest set of
> known problems, conflicts, things which work well, things which work
> badly.

Perhaps you could prod or contribute to Richard Gooch's webpage:
http://www.atnf.csiro.au/~rgooch/linux/docs/kernel-newsflash.html

-- 
Paul Kimoto             <[EMAIL PROTECTED]>

------------------------------


** FOR YOUR REFERENCE **

The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:

    Internet: [EMAIL PROTECTED]

You can send mail to the entire list (and comp.os.linux.development.system) via:

    Internet: [EMAIL PROTECTED]

Linux may be obtained via one of these FTP sites:
    ftp.funet.fi                                pub/Linux
    tsx-11.mit.edu                              pub/linux
    sunsite.unc.edu                             pub/Linux

End of Linux-Development-System Digest
******************************

Reply via email to