lock order reversal under -current

2001-02-28 Thread Michael Reifenberger

Hi,
with -current sources (as of -now) I get during startup:

lock order reversal
 1st vnode interlock last acquired @ ../../kern/vfs_vnops.c:625
 2nd 0xc0306840 mntvnode @ ../../ufs/ffs/ffs_vfsops.c:940
 3rd 0xcbd20a0c vnode interlock @ ../../ufs/ffs/ffs_vfsops.c:949
 32

Is that bad?

Bye!

Michael Reifenberger
^.*Plaut.*$, IT, R/3 Basis, GPS


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Jail code has been dysfunctional...

2001-02-28 Thread Poul-Henning Kamp


For some time in current.  Unfortunately I found out when I MFC'ed
the non-working code into -stable.

I belive the code works in -current again now, and I will MFC the
fix probably some time sunday.

--
Poul-Henning Kamp   | UNIX since Zilog Zeus 3.20
[EMAIL PROTECTED] | TCP/IP since RFC 956
FreeBSD committer   | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



resolver problem with shared linked programs

2001-02-28 Thread John Hay

I noticed that sendmail started to complain of a failed reverse lookup
when starting:

Feb 28 11:40:43 beast sendmail[276]: 
gethostbyaddr(3ffe:2900:fffa:2:2a0:c9ff:fe8d:7c5f) failed: 2

At first I thought something is wrong with my ipv6 dns setup, but it turned
out that if a program is linked shared the first getipnodebyaddr() it does
will succeed, but the rest fail. For a staticly linked program all of
them will succeed:


beast:~/try > cc -Wall -static -O -o tstgetipnodebyaddr.static-c tstgetipnodebyaddr.c
beast:~/try > cc -Wall -O -o tstgetipnodebyaddr tstgetipnodebyaddr.c 
beast:~/try > ./tstgetipnodebyaddr.static-c And 
the answer is: beast.icomtek.csir.co.za
And the answer is: beast.icomtek.csir.co.za
beast:~/try > ./tstgetipnodebyaddr
And the answer is: beast.icomtek.csir.co.za
Oops: 2.
getipnodebyaddr: Host name lookup failure
beast:~/try >


My test program is at the end of the email. Maybe I (and sendmail) have
done something wrong?

John
-- 
John Hay -- [EMAIL PROTECTED]


#include 
#include 
#include 
#include 
#include 
#include 

int main(int argc, char **argv)
{
struct hostent *he;
int h_err;
u_char ipnum[16];
char *astr1;

astr1 = "146.64.24.3";
h_err = inet_pton(AF_INET, astr1, ipnum);
if(h_err == 0) {
printf("conversion error with inet_pton()\n");
exit(1);
}

he = getipnodebyaddr(ipnum, 4, AF_INET, &h_err);
if(he == NULL) {
printf("Oops: %d.\n", h_err);
herror("getipnodebyaddr");
} else
printf("And the answer is: %s\n", he->h_name);

he = getipnodebyaddr(ipnum, 4, AF_INET, &h_err);
if(he == NULL) {
printf("Oops: %d.\n", h_err);
herror("getipnodebyaddr");
} else
printf("And the answer is: %s\n", he->h_name);

return 0;
}

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: make kernel failure: pecoff: machine/lock.h

2001-02-28 Thread Bruce Evans

On Tue, 27 Feb 2001, Julian Elischer wrote:

> Bruce Evans wrote:
> > Most of the pcb actually has the same persistence as the kernel stack
> > (both mainly store the process's context while the process is in the
> > kernel).  But it is silly to put the pcb below the stack instead of
> > above it.  Perhaps the idea is to get a panic sooner when something
> > is corrupted.
> 
> I have never understood why the context is not ON the stack.

At least on i386's, it is because the context is not all saved in LIFO
order.  The pcb gets the non-LIFO stuff.  E.g., the FP state is saved
lazily, not pushed on every entry to the kernel.

Bruce


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: d.net client + today's kernel

2001-02-28 Thread Ilya Naumov

On Tue, 27 Feb 2001, Jake Burkholder wrote:

> > a distributed.net client (ports/misc/dnetc) being run on -current with
> > today's kernel just hangs my box. the system _dramatically_ slows
> > down and stops to respond on any external events (keyboard, network,
> > etc).
> Sorry, this should be fixed.  I'm running it now and it seems fine.

what's the date of your kernel?


sincerely,
ilya naumov (at work)



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: d.net client + today's kernel

2001-02-28 Thread Jake Burkholder

> On Tue, 27 Feb 2001, Jake Burkholder wrote:
> 
> > > a distributed.net client (ports/misc/dnetc) being run on -current with
> > > today's kernel just hangs my box. the system _dramatically_ slows
> > > down and stops to respond on any external events (keyboard, network,
> > > etc).
> > Sorry, this should be fixed.  I'm running it now and it seems fine.
> 
> what's the date of your kernel?
> 

2001/02/27 18:53:44 PST

Any time after that should be good.




To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



KDE2 port?

2001-02-28 Thread Igor Robul

On Fri, Feb 23, 2001 at 04:50:37AM -0800, Alex Zepeda wrote:
> Define flawlessly?
> 
> I haven't noticed any problems yet with KDE2, other than the usual mixing
I can't build KDE2 port on -CURRENT-20010228
I'm not complaining of course, I even don't need KDE, but I wish try
it :-)
This -CURRENT is my workstation. On -STABLE server I have build KDE2
without problems, but then deinstalled it (why I need KDE on server?
:-) )

Problem is, while compiling I get:
cc -DHAVE_CONFIG_H -I. -I. -I../../.. -I./../../CContLib
-I/usr/local/include  -Wall  -c ProcessList.c
ProcessList.c: In function `updateProcess':
ProcessList.c:199: structure has no member named `ki_priority'



-- 
Igor Robul, Unix System Administrator & Programmer @ sanatorium "Raduga", 
Sochi, Russia
http://www.brainbench.com/transcript.jsp?pid=304744

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



struct ki_pri VS ki_priority in sys/user.h

2001-02-28 Thread Igor Robul

On Wed, Feb 28, 2001 at 03:25:15PM +0300, Igor Robul wrote:
> Problem is, while compiling I get:
> cc -DHAVE_CONFIG_H -I. -I. -I../../.. -I./../../CContLib
> -I/usr/local/include  -Wall  -c ProcessList.c
> ProcessList.c: In function `updateProcess':
> ProcessList.c:199: structure has no member named `ki_priority'
Ok, now there is "struct ki_pri" instead of "int (?) ki_priority"
This is used in ksysguardd, so (hoping I'll not get problems) I have
changed ki_priority to ki_pri.pri_user in KDE source.

But can somebody enlighten me on this topic?

-- 
Igor Robul, Unix System Administrator & Programmer @ sanatorium "Raduga", 
Sochi, Russia
http://www.brainbench.com/transcript.jsp?pid=304744

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: struct ki_pri VS ki_priority in sys/user.h

2001-02-28 Thread Maxim Sobolev

Igor Robul wrote:

> On Wed, Feb 28, 2001 at 03:25:15PM +0300, Igor Robul wrote:
> > Problem is, while compiling I get:
> > cc -DHAVE_CONFIG_H -I. -I. -I../../.. -I./../../CContLib
> > -I/usr/local/include  -Wall  -c ProcessList.c
> > ProcessList.c: In function `updateProcess':
> > ProcessList.c:199: structure has no member named `ki_priority'
> Ok, now there is "struct ki_pri" instead of "int (?) ki_priority"
> This is used in ksysguardd, so (hoping I'll not get problems) I have
> changed ki_priority to ki_pri.pri_user in KDE source.
>
> But can somebody enlighten me on this topic?

Should be fine. See http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/sys/user.h.

-Maxim



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Correct size of kinfo_proc

2001-02-28 Thread Maxim Sobolev

Hi Poul,

In revision 1.31 of src/sys/sys/user.h you have added new ki_layout field to
kinfo_proc structure, but forgot to increase KINFO_PROC_SIZE  from 644 to 648.
Please correct.

-Maxim


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: make kernel failure: pecoff: machine/lock.h

2001-02-28 Thread Julian Elischer

Bruce Evans wrote:
> 
> On Tue, 27 Feb 2001, Julian Elischer wrote:
> 
> > Bruce Evans wrote:
> > > Most of the pcb actually has the same persistence as the kernel stack
> > > (both mainly store the process's context while the process is in the
> > > kernel).  But it is silly to put the pcb below the stack instead of
> > > above it.  Perhaps the idea is to get a panic sooner when something
> > > is corrupted.
> >
> > I have never understood why the context is not ON the stack.
> 
> At least on i386's, it is because the context is not all saved in LIFO
> order.  The pcb gets the non-LIFO stuff.  E.g., the FP state is saved
> lazily, not pushed on every entry to the kernel.

We could push the pcb onto the stack as easily as have it somewhere else.
It's not compulsory to access stack memeory in sequential order.


> 
> Bruce
> 
> To Unsubscribe: send mail to [EMAIL PROTECTED]
> with "unsubscribe freebsd-current" in the body of the message

-- 
  __--_|\  Julian Elischer
 /   \ [EMAIL PROTECTED]
(   OZ) World tour 2000-2001
---> X_.---._/  
v

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: Correct size of kinfo_proc

2001-02-28 Thread Igor Robul

On Wed, Feb 28, 2001 at 03:00:48PM +0200, Maxim Sobolev wrote:
> Hi Poul,
> 
> In revision 1.31 of src/sys/sys/user.h you have added new ki_layout field to
> kinfo_proc structure, but forgot to increase KINFO_PROC_SIZE  from 644 to 648.
> Please correct.
Why don't use sizeof() insead of hardcoding numbers? 

-- 
Igor Robul, Unix System Administrator & Programmer @ sanatorium "Raduga", 
Sochi, Russia
http://www.brainbench.com/transcript.jsp?pid=304744

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: resolver problem with shared linked programs

2001-02-28 Thread Matthew Thyer

John Hay wrote:
> 
> I noticed that sendmail started to complain of a failed reverse lookup
> when starting:
> 
> Feb 28 11:40:43 beast sendmail[276]: 
>gethostbyaddr(3ffe:2900:fffa:2:2a0:c9ff:fe8d:7c5f) failed: 2
> 
> At first I thought something is wrong with my ipv6 dns setup, but it turned
> out that if a program is linked shared the first getipnodebyaddr() it does
> will succeed, but the rest fail. For a staticly linked program all of
> them will succeed:

So it's in -CURRENT too.  -STABLE users have been complaining of a
similar problem since about the 20th/21st of Feb.

I was damned lucky that I skimmed:
http://www.mail-archive.com/freebsd-stable%40freebsd.org/
before I built a -STABLE system today.

I'm cross posting to stable so others can try your program.

And I wont install my -CURRENT buildworld.

> 
> #include 
> #include 
> #include 
> #include 
> #include 
> #include 
> 
> int main(int argc, char **argv)
> {
> struct hostent *he;
> int h_err;
> u_char ipnum[16];
> char *astr1;
> 
> astr1 = "146.64.24.3";
> h_err = inet_pton(AF_INET, astr1, ipnum);
> if(h_err == 0) {
> printf("conversion error with inet_pton()\n");
> exit(1);
> }
> 
> he = getipnodebyaddr(ipnum, 4, AF_INET, &h_err);
> if(he == NULL) {
> printf("Oops: %d.\n", h_err);
> herror("getipnodebyaddr");
> } else
> printf("And the answer is: %s\n", he->h_name);
> 
> he = getipnodebyaddr(ipnum, 4, AF_INET, &h_err);
> if(he == NULL) {
> printf("Oops: %d.\n", h_err);
> herror("getipnodebyaddr");
> } else
> printf("And the answer is: %s\n", he->h_name);
> 
> return 0;
> }

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Inscription

2001-02-28 Thread Patrice JACQUES-GUSTAVE

Bonjour à tous !!!

Je découvre jour après jour Freebsd, qui finit par vraiment me plaire. Du
coup, j'aimerais faire partie de votre liste de diffusion.

Merci d'avance et merci à vous tous...



  RISC Technology Europe
  Les solutions et les services d'un expert
  http://www.risc.fr

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: Correct size of kinfo_proc

2001-02-28 Thread Bruce Evans

On Wed, 28 Feb 2001, Igor Robul wrote:

> On Wed, Feb 28, 2001 at 03:00:48PM +0200, Maxim Sobolev wrote:
> > Hi Poul,
> > 
> > In revision 1.31 of src/sys/sys/user.h you have added new ki_layout field to
> > kinfo_proc structure, but forgot to increase KINFO_PROC_SIZE  from 644 to 648.
> > Please correct.
> Why don't use sizeof() insead of hardcoding numbers? 

because we don't want the size of the struct.  We want the size that the
should have.  It must be a constant for binary compatibility.  This is
a small part of binary compatibility, but good enough to inhibit adding
new fields in the middle.

Bruce


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: Inscription

2001-02-28 Thread Stephane Legrand

On Wed, Feb 28, 2001 at 02:46:06PM +0100, Patrice JACQUES-GUSTAVE wrote:
> Bonjour à tous !!!
> 
> Je découvre jour après jour Freebsd, qui finit par vraiment me plaire. Du
> coup, j'aimerais faire partie de votre liste de diffusion.
> 
> Merci d'avance et merci à vous tous...
> 

Bonjour,

Attention, "freebsd-current" est une liste en langue anglaise, il
faut normalement éviter d'envoyer des messages dans une autre
langue. Si vous voulez toujours vous inscrire, la procédure à suivre
est indiquée sur
http://www.freebsd.org/handbook/eresources.html#ERESOURCES-MAIL
par exemple.

Pour info, il existe une liste de diffusion francophone au sujet
de FreeBSD. Pour plus de détails et pour vous inscrire, vous pouvez
consulter http://www.freebsd-fr.org/mailing-lists.html


Cordialement.
Stéphane Legrand.

-- 
[EMAIL PROTECTED]
FreeBSD Francophone : http://www.freebsd-fr.org/

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: resolver problem with shared linked programs

2001-02-28 Thread Larry Rosenman

* Matthew Thyer <[EMAIL PROTECTED]> [010228 07:26]:
> John Hay wrote:
> > 
> > I noticed that sendmail started to complain of a failed reverse lookup
> > when starting:
> > 
> > Feb 28 11:40:43 beast sendmail[276]: 
>gethostbyaddr(3ffe:2900:fffa:2:2a0:c9ff:fe8d:7c5f) failed: 2
> > 
> > At first I thought something is wrong with my ipv6 dns setup, but it turned
> > out that if a program is linked shared the first getipnodebyaddr() it does
> > will succeed, but the rest fail. For a staticly linked program all of
> > them will succeed:
> 
> So it's in -CURRENT too.  -STABLE users have been complaining of a
> similar problem since about the 20th/21st of Feb.
> 
> I was damned lucky that I skimmed:
> http://www.mail-archive.com/freebsd-stable%40freebsd.org/
> before I built a -STABLE system today.
> 
> I'm cross posting to stable so others can try your program.
Bingo.  It breaks on -STABLE too.  

LER
$ uname -a
FreeBSD lerbsd.lerctr.org 4.2-STABLE FreeBSD 4.2-STABLE #108: Tue Feb
27 22:28:4
0 CST 2001 [EMAIL PROTECTED]:/usr/src/sys/compile/LERBSD  i386
$ cc -O -static -o x x.c
$ ./x
And the answer is: beast.icomtek.csir.co.za
And the answer is: beast.icomtek.csir.co.za
$ cc -O -o x x.c
$ time ./x
And the answer is: beast.icomtek.csir.co.za
Oops: 2.
getipnodebyaddr: Host name lookup failure
   81.12s real 0.00s user 0.00s system
$
> 
> And I wont install my -CURRENT buildworld.
> 
> > 
> > #include 
> > #include 
> > #include 
> > #include 
> > #include 
> > #include 
> > 
> > int main(int argc, char **argv)
> > {
> > struct hostent *he;
> > int h_err;
> > u_char ipnum[16];
> > char *astr1;
> > 
> > astr1 = "146.64.24.3";
> > h_err = inet_pton(AF_INET, astr1, ipnum);
> > if(h_err == 0) {
> > printf("conversion error with inet_pton()\n");
> > exit(1);
> > }
> > 
> > he = getipnodebyaddr(ipnum, 4, AF_INET, &h_err);
> > if(he == NULL) {
> > printf("Oops: %d.\n", h_err);
> > herror("getipnodebyaddr");
> > } else
> > printf("And the answer is: %s\n", he->h_name);
> > 
> > he = getipnodebyaddr(ipnum, 4, AF_INET, &h_err);
> > if(he == NULL) {
> > printf("Oops: %d.\n", h_err);
> > herror("getipnodebyaddr");
> > } else
> > printf("And the answer is: %s\n", he->h_name);
> > 
> > return 0;
> > }
> 
> To Unsubscribe: send mail to [EMAIL PROTECTED]
> with "unsubscribe freebsd-stable" in the body of the message
-- 
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 972-414-9812 E-Mail: [EMAIL PROTECTED]
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



DNS & kqread (kq in general)

2001-02-28 Thread Jonathan Lemon

I"ve committed a fix for the problem where DNS hangs or takes 
a long time to resolve (the process gets stuck in kqread).

In the last kqueue update, I added a new filter-specific flag to
the read/write filters, which allows the filter to specify its
own read/write watermarks.  However, since this flag was previously
unused, if you do not initialize the structure to zero, you may
get unexpected results.

To that end, I'd encourage kqueue users to review their code and
make sure that the structure is completely initialized.  A new 
a new convenience macro EV_SET() was also added to 
which should also assist this process.
--
Jonathan

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: resolver problem with shared linked programs

2001-02-28 Thread Jonathan Lemon

In article 
[EMAIL PROTECTED]> you 
write:
>At first I thought something is wrong with my ipv6 dns setup, but it turned
>out that if a program is linked shared the first getipnodebyaddr() it does
>will succeed, but the rest fail. For a staticly linked program all of
>them will succeed:

I just fixed this a few minutes ago.
--
Jonathan

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: cvs commit: src/gnu/usr.bin/binutils/ar Makefile src/gnu/usr.bin/binutils/as Makefile.inc0 src/gnu/usr.bin/binutils/ld Makefile src/gnu/usr.bin/binutils/ranlib Makefile

2001-02-28 Thread Will Andrews

[  cc's trimmed, moved to -current  ]

On Wed, Feb 28, 2001 at 09:51:08AM -0700, Warner Losh wrote:
> So long as it is not forced unconditionally to be static.

I agree.

> b) I've not seen the numbers for this.  If it is only 1% faster, it
> doesn't make sense, even though it sounds good on paper.

I will perform careful benchmarks and publish results.  Can people wait
until that is done before moving forward please?  Give me until Saturday.

-- 
wca

 PGP signature


Re: KDE2 port?

2001-02-28 Thread Will Andrews

On Wed, Feb 28, 2001 at 03:25:15PM +0300, Igor Robul wrote:
> I can't build KDE2 port on -CURRENT-20010228
> I'm not complaining of course, I even don't need KDE, but I wish try
> it :-)
> This -CURRENT is my workstation. On -STABLE server I have build KDE2
> without problems, but then deinstalled it (why I need KDE on server?
> :-) )
> 
> Problem is, while compiling I get:
> cc -DHAVE_CONFIG_H -I. -I. -I../../.. -I./../../CContLib
> -I/usr/local/include  -Wall  -c ProcessList.c
> ProcessList.c: In function `updateProcess':
> ProcessList.c:199: structure has no member named `ki_priority'

Known problem.  Will be fixed as soon as I can get my hands on a fresh
-CURRENT box.  This post should have been sent to -ports anyawys...

-- 
wca

 PGP signature


Re: resolver problem with shared linked programs

2001-02-28 Thread Larry Rosenman

* Larry Rosenman <[EMAIL PROTECTED]> [010228 09:37]:
> * Matthew Thyer <[EMAIL PROTECTED]> [010228 07:26]:
> > John Hay wrote:
> > > 
> > > I noticed that sendmail started to complain of a failed reverse lookup
> > > when starting:
> > > 
> > > Feb 28 11:40:43 beast sendmail[276]: 
>gethostbyaddr(3ffe:2900:fffa:2:2a0:c9ff:fe8d:7c5f) failed: 2
> > > 
> > > At first I thought something is wrong with my ipv6 dns setup, but it turned
> > > out that if a program is linked shared the first getipnodebyaddr() it does
> > > will succeed, but the rest fail. For a staticly linked program all of
> > > them will succeed:
> > 
> > So it's in -CURRENT too.  -STABLE users have been complaining of a
> > similar problem since about the 20th/21st of Feb.
> > 
> > I was damned lucky that I skimmed:
> > http://www.mail-archive.com/freebsd-stable%40freebsd.org/
> > before I built a -STABLE system today.
> > 
> > I'm cross posting to stable so others can try your program.
> Bingo.  It breaks on -STABLE too.  
> 
> LER
> $ uname -a
> FreeBSD lerbsd.lerctr.org 4.2-STABLE FreeBSD 4.2-STABLE #108: Tue Feb
> 27 22:28:4
> 0 CST 2001 [EMAIL PROTECTED]:/usr/src/sys/compile/LERBSD  i386
> $ cc -O -static -o x x.c
> $ ./x
> And the answer is: beast.icomtek.csir.co.za
> And the answer is: beast.icomtek.csir.co.za
> $ cc -O -o x x.c
> $ time ./x
> And the answer is: beast.icomtek.csir.co.za
> Oops: 2.
> getipnodebyaddr: Host name lookup failure
>81.12s real 0.00s user 0.00s system
Jonathan Lemon's res_send.c fix fixes this:

Welcome to FreeBSD!
$ ./x
And the answer is: beast.icomtek.csir.co.za
And the answer is: beast.icomtek.csir.co.za
$ cc -O -o x x.c
$ ./x
And the answer is: beast.icomtek.csir.co.za
And the answer is: beast.icomtek.csir.co.za
$ time ./x
And the answer is: beast.icomtek.csir.co.za
And the answer is: beast.icomtek.csir.co.za
0.00s real 0.00s user 0.00s system
$

> $
> > 
> > And I wont install my -CURRENT buildworld.
> > 
> > > 
> > > #include 
> > > #include 
> > > #include 
> > > #include 
> > > #include 
> > > #include 
> > > 
> > > int main(int argc, char **argv)
> > > {
> > > struct hostent *he;
> > > int h_err;
> > > u_char ipnum[16];
> > > char *astr1;
> > > 
> > > astr1 = "146.64.24.3";
> > > h_err = inet_pton(AF_INET, astr1, ipnum);
> > > if(h_err == 0) {
> > > printf("conversion error with inet_pton()\n");
> > > exit(1);
> > > }
> > > 
> > > he = getipnodebyaddr(ipnum, 4, AF_INET, &h_err);
> > > if(he == NULL) {
> > > printf("Oops: %d.\n", h_err);
> > > herror("getipnodebyaddr");
> > > } else
> > > printf("And the answer is: %s\n", he->h_name);
> > > 
> > > he = getipnodebyaddr(ipnum, 4, AF_INET, &h_err);
> > > if(he == NULL) {
> > > printf("Oops: %d.\n", h_err);
> > > herror("getipnodebyaddr");
> > > } else
> > > printf("And the answer is: %s\n", he->h_name);
> > > 
> > > return 0;
> > > }
> > 
> > To Unsubscribe: send mail to [EMAIL PROTECTED]
> > with "unsubscribe freebsd-stable" in the body of the message
> -- 
> Larry Rosenman http://www.lerctr.org/~ler
> Phone: +1 972-414-9812 E-Mail: [EMAIL PROTECTED]
> US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749
> 
> To Unsubscribe: send mail to [EMAIL PROTECTED]
> with "unsubscribe freebsd-stable" in the body of the message
-- 
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 972-414-9812 E-Mail: [EMAIL PROTECTED]
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: make kernel failure: pecoff: machine/lock.h

2001-02-28 Thread John Baldwin


On 28-Feb-01 Bruce Evans wrote:
> On Tue, 27 Feb 2001, John Baldwin wrote:
> 
>> Ok.  It may be that we are overflowing the kernel stack and corrupting the
>> pcb
>> in the process.  One idea atm is to move the pcb off of the stack (since it
>> stores persistent data it's a bad place for it anyways) and to add a red
>> zone
>> at the bottom of the stack to catch overflows.
> 
> Most of the pcb actually has the same persistence as the kernel stack
> (both mainly store the process's context while the process is in the
> kernel).  But it is silly to put the pcb below the stack instead of
> above it.  Perhaps the idea is to get a panic sooner when something
> is corrupted.

That is the idea.  Not all of the pcb is just used while in the kernel.  The
pcb_ext that points to a TSS on the i386 for example.  The problem I think
people are having with the ltr panic is that the stack gets deep enough to
overwrite that field of the pcb, and we die later on when we try to access an
invalid pointer there.  Perhaps pcb_ext, pcb_ldt, and other things that are
persistent across kernel entry/exit should be stored in p_md instead of p_addr.

However, I would like the machine to panic when it overflows the stack rather
than trash the pcb, yes.

> Bruce

-- 

John Baldwin <[EMAIL PROTECTED]> -- http://www.FreeBSD.org/~jhb/
PGP Key: http://www.baldwin.cx/~john/pgpkey.asc
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



RE: lock order reversal under -current

2001-02-28 Thread John Baldwin


On 28-Feb-01 Michael Reifenberger wrote:
> Hi,
> with -current sources (as of -now) I get during startup:
> 
> lock order reversal
>  1st vnode interlock last acquired @ ../../kern/vfs_vnops.c:625
>  2nd 0xc0306840 mntvnode @ ../../ufs/ffs/ffs_vfsops.c:940
>  3rd 0xcbd20a0c vnode interlock @ ../../ufs/ffs/ffs_vfsops.c:949
>  32
> 
> Is that bad?

Yes and no.  It's a bug yes, but it has probably been around since at least
4.4BSD, so you can ignore it for now.

-- 

John Baldwin <[EMAIL PROTECTED]> -- http://www.FreeBSD.org/~jhb/
PGP Key: http://www.baldwin.cx/~john/pgpkey.asc
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



(device hints) okay, what's wrong with this?

2001-02-28 Thread Matthew Jacob


I have 3 hints in /boot/device.hints

hint.isp.0.portwnn="w5000"
hint.isp.0.nodewnn="w50000001"
hint.isp.0.role=3  


resource_get_int picks up 'hint.isp.0.role=3' with no problem.
resource_get_string fails to pick up either hint.isp.0.portwnn
or hint.isp.0.nodewwn. Nor does a getenv on a handcrafted
"hint.isp.0.portwwn" string work. What am I doing wrong?

What's this?

-matt



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Never Mind: Re: (device hints) okay, what's wrong with this?

2001-02-28 Thread Matthew Jacob

Clearly I'm going blind. Sorry for the noise.



> 
> I have 3 hints in /boot/device.hints
> 
> hint.isp.0.portwnn="w5000"
> hint.isp.0.nodewnn="w50000001"
> hint.isp.0.role=3  
> 
> 
> resource_get_int picks up 'hint.isp.0.role=3' with no problem.
> resource_get_string fails to pick up either hint.isp.0.portwnn
> or hint.isp.0.nodewwn. Nor does a getenv on a handcrafted
> "hint.isp.0.portwwn" string work. What am I doing wrong?
> 
> What's this?
> 
> -matt
> 
> 
> 


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: Inscription

2001-02-28 Thread Bosko Milekic


Stephane Legrand wrote:


> On Wed, Feb 28, 2001 at 02:46:06PM +0100, Patrice JACQUES-GUSTAVE
wrote:
> > Bonjour à tous !!!
> >
> > Je découvre jour après jour Freebsd, qui finit par vraiment me
plaire. Du
> > coup, j'aimerais faire partie de votre liste de diffusion.
> >
> > Merci d'avance et merci à vous tous...
> >
>
> Bonjour,
>
> Attention, "freebsd-current" est une liste en langue anglaise, il
> faut normalement éviter d'envoyer des messages dans une autre
> langue. Si vous voulez toujours vous inscrire, la procédure à suivre
> est indiquée sur
> http://www.freebsd.org/handbook/eresources.html#ERESOURCES-MAIL
> par exemple.
>
> Pour info, il existe une liste de diffusion francophone au sujet
> de FreeBSD. Pour plus de détails et pour vous inscrire, vous pouvez
> consulter http://www.freebsd-fr.org/mailing-lists.html

Attention. Certains de nous parlent et écrivent le français, quand
même. :-)

>
> Cordialement.
> Stéphane Legrand.
>
> --
> [EMAIL PROTECTED]
> FreeBSD Francophone : http://www.freebsd-fr.org/



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



RE: Never Mind: Re: (device hints) okay, what's wrong with this?

2001-02-28 Thread John Baldwin


On 01-Mar-01 Matthew Jacob wrote:
> Clearly I'm going blind. Sorry for the noise.

You're not the only one.  Was hard for me to see it as well. :)
 
>> I have 3 hints in /boot/device.hints
>> 
>> hint.isp.0.portwnn="w5000"
>> hint.isp.0.nodewnn="w50000001"
>> hint.isp.0.role=3  
>> 
>> 
>> resource_get_int picks up 'hint.isp.0.role=3' with no problem.
>> resource_get_string fails to pick up either hint.isp.0.portwnn
>> or hint.isp.0.nodewwn. Nor does a getenv on a handcrafted
>> "hint.isp.0.portwwn" string work. What am I doing wrong?
>> 
>> What's this?
>> 
>> -matt
>> 
>> 
>> 
> 
> 
> To Unsubscribe: send mail to [EMAIL PROTECTED]
> with "unsubscribe freebsd-current" in the body of the message

-- 

John Baldwin <[EMAIL PROTECTED]> -- http://www.FreeBSD.org/~jhb/
PGP Key: http://www.baldwin.cx/~john/pgpkey.asc
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



RE: Never Mind: Re: (device hints) okay, what's wrong with this?

2001-02-28 Thread Matthew Jacob


> 
> You're not the only one.  Was hard for me to see it as well. :)

> >> hint.isp.0.portwnn="w5000"

In the quest to manage far too many digits, I stumbled over far too many
letters.

Sigh. What still is unfortunate here is that I have to this leading 'w' if I
want a string because there is no quad (uint64_t) resource, and
resource_get_long will I'm sure happily return you a munged translation of
above when I really want all of it.

Now that I think about it, we also need 128 bit UUIDs as well...

-matt



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: Never Mind: Re: (device hints) okay, what's wrong with this?

2001-02-28 Thread Warner Losh

In message <[EMAIL PROTECTED]> Matthew Jacob 
writes:
: Now that I think about it, we also need 128 bit UUIDs as well...

This is the big reason why I think storing things as strings might not
be such a horrible idea.

Warner

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: Correct size of kinfo_proc

2001-02-28 Thread Warner Losh

In message <[EMAIL PROTECTED]> Igor Robul writes:
: On Wed, Feb 28, 2001 at 03:00:48PM +0200, Maxim Sobolev wrote:
: > Hi Poul,
: > 
: > In revision 1.31 of src/sys/sys/user.h you have added new ki_layout field to
: > kinfo_proc structure, but forgot to increase KINFO_PROC_SIZE  from 644 to 648.
: > Please correct.
: Why don't use sizeof() insead of hardcoding numbers? 

Because KINFO_PROC_SIZE is part of the ABI.  Changes to its size are
always wrong, in that they break the ABI.  The checks are there to
tell us when the ABI has been broken.

Warner

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: make kernel failure: pecoff: machine/lock.h

2001-02-28 Thread Warner Losh

In message <[EMAIL PROTECTED]> Leif Neland 
writes:
: ===> pecoff
: make: don't know how to make machine/lock.h. Stop

If you are making from pure, clean sources, like I think you said you
were, you may need to rm src/sys/modules/pecoff/.depend.

I had a few of these kicking around and it caused me problems, even on
a clean build :-(

Warner

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: make kernel failure: pecoff: machine/lock.h

2001-02-28 Thread Warner Losh

In message <[EMAIL PROTECTED]> "David O'Brien" writes:
: On Tue, Feb 27, 2001 at 11:28:37AM -0800, John Baldwin wrote:
: > Have you tried running make depend?
: 
: I've got the same problem about a bogus dependancy on machine/lock.h.
: And yes, this is after a `make depend' on a /sys I *just* CVSup'ed.  :-(

find /sys -name .depend | xargs egrep machine/lock.h

was how I found the problem.

Warner

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: make kernel failure: pecoff: machine/lock.h

2001-02-28 Thread Warner Losh

In message <[EMAIL PROTECTED]> Edwin Culp writes:
: I had that, and many other problems, about a week ago and I am not
: sure but i think that I ended up doing an rm -rf /usr/sys/modules/*
: , cvsuped made world and built new kernel with no problem.  I
: remember that I had to erase all the modules directory but I'm not
: comeletely sure that it was this problem.  Sorry, it's old age.

Likely it is stale .depend files in the src/sys/modules hierarchy.
That's why killing it worked.

Warner

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: make kernel failure: pecoff: machine/lock.h

2001-02-28 Thread Bruce Evans

On Wed, 28 Feb 2001, John Baldwin wrote:

> On 28-Feb-01 Bruce Evans wrote:
> > Most of the pcb actually has the same persistence as the kernel stack
> > (both mainly store the process's context while the process is in the
> > kernel).  But it is silly to put the pcb below the stack instead of
> > above it.  Perhaps the idea is to get a panic sooner when something
> > is corrupted.
> 
> That is the idea.  Not all of the pcb is just used while in the kernel.  The
> pcb_ext that points to a TSS on the i386 for example.  The problem I think
> people are having with the ltr panic is that the stack gets deep enough to
> overwrite that field of the pcb, and we die later on when we try to access an
> invalid pointer there.  Perhaps pcb_ext, pcb_ldt, and other things that are
> persistent across kernel entry/exit should be stored in p_md instead of p_addr.

I think that at least the pointers belong in p_md.

I had some panics that looked a bit like the ltr one.  These turned out
to be caused by priority inversion (related to the native priority bugs)
preventing an ithread from running.  The ithread held a pointer to a
process and the process exited before the pointer was used.

Bruce


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: Never Mind: Re: (device hints) okay, what's wrong with this?

2001-02-28 Thread Matthew Jacob


> In message <[EMAIL PROTECTED]> Matthew Jacob 
>writes:
> : Now that I think about it, we also need 128 bit UUIDs as well...
> 
> This is the big reason why I think storing things as strings might not
> be such a horrible idea.

As long as simple things can be treated simply- we're cool. Most everyone will
want just an integer.

-matt



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



ltr %si panic

2001-02-28 Thread Peter S. Housel


I'm getting the "ltr %si" panic on my laptop whenever I insert my
Ethernet card.  My last CVSup/build was Tuesday evening; I won't be able
to do any more until this gets fixed, obviously.

-Peter-

Copyright (c) 1992-2001 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD 5.0-CURRENT #5: Wed Feb 28 22:21:23 PST 2001
root@nomad:/usr/src/sys/compile/NOMAD
Timecounter "i8254"  frequency 1193182 Hz
Timecounter "TSC"  frequency 595504803 Hz
CPU: Pentium (595.50-MHz 586-class CPU)
  Origin = "GenuineTMx86"  Id = 0x543
real memory  = 184483840 (180160K bytes)
avail memory = 175194112 (171088K bytes)
Preloaded elf kernel "kernel" at 0xc041c000.
WARNING: size of kinfo_proc (648) should be 644!!!
Using $PIR table, 9 entries at 0xc00fdf30
npx0:  on motherboard
npx0: INT 16 interface
pcib0:  at pcibus 0 on motherboard
pci0:  on pcib0
pci0:  at 0.1 (no driver attached)
pci0:  at 0.2 (no driver attached)
isab0:  at device 7.0 on pci0
isa0:  on isab0
atapci0:  port 0x1050-0x105f at device 7.1 on pci0
ata0: at 0x1f0 irq 14 on atapci0
ata1: at 0x170 irq 15 on atapci0
uhci0:  port 0x1060-0x107f irq 9 at device 
7.2 on pci0
usb0:  on uhci0
usb0: USB revision 1.0
uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
umass0: Y-E DATA FlashBuster-U, rev 1.00/3.04, addr 2
umass1: Sony USB Memory Stick Slot, rev 1.10/1.31, addr 3
pci0:  at 7.3 (no driver attached)
pci0:  at 8.0 (no driver attached)
pcm0:  port 0x1080-0x1083,0x1000-0x103f mem 
0xfc01-0xfc017fff irq 9 at device 9.0 on pci0
pci0:  at 10.0 (no driver attached)
pci0:  at 11.0 (no driver attached)
pcic-pci0:  at device 12.0 on pci0
pci0:  at 13.0 (no driver attached)
atkbdc0:  at port 0x60,0x64 on isa0
atkbd0:  flags 0x1 irq 1 on atkbdc0
kbd0 at atkbd0
psm0:  irq 12 on atkbdc0
psm0: model Generic PS/2 mouse, device ID 0
pcic0:  at port 0x3e0 iomem 0xd on isa0
pcic0: Polling mode
pccard0:  on pcic0
pmtimer0 on isa0
sc0:  at flags 0x100 on isa0
sc0: VGA <16 virtual consoles, flags=0x300>
sio0: configured irq 4 not in bitmap of probed irqs 0
sio0 at port 0x3f8-0x3ff irq 4 flags 0x10 on isa0
sio0: type 8250
sio1: configured irq 3 not in bitmap of probed irqs 0
vga0:  at port 0x3c0-0x3df iomem 0xa-0xb on isa0
unknown:  can't assign resources
unknown:  can't assign resources
ad0: 11513MB  [23392/16/63] at ata0-master UDMA33
(probe1:umass-sim0:0:1:0): INQUIRY. CDB: 12 0 0 0 24 0 
(probe1:umass-sim0:0:1:0): NOT READY asc:3a,0
(probe1:umass-sim0:0:1:0): Medium not present
Mounting root from ufs:/dev/ad0s2a
da0 at umass-sim0 bus 0 target 0 lun 0
da0:  Removable Direct Access SCSI-0 device 
da0: 20KB/s transfers
da0: Attempt to query device size failed: NOT READY, Medium not present
kernel trap 9 with interrupts disabled

Fatal trap 9: general protection fault while in kernel mode
instruction pointer = 0x8:0xc02d1b48
stack pointer   = 0x10:0xc960ff50
frame pointer   = 0x10:0xc960ff64
code segment= base 0x0, limit 0xf, type 0x1b
= DPL 0, pres 1, def32 1, gran 1
processor eflags= resume, IOPL = 0
current process = 20 (irq9: uhci0 pcm0)


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message