Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Daniel C. Sobral
Matthew Dillon wrote: > > I found it. The code itself is broken. I missed the lack of parens. > > if (m->m_len < sizeof(struct arphdr) && > (m = m_pullup(m, sizeof(struct arphdr)) == NULL)) { > log(LOG_ERR, "arp: runt packet -- m_

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Nate Williams
> > I found it. The code itself is broken. I missed the lack of parens. > > > > if (m->m_len < sizeof(struct arphdr) && > > (m = m_pullup(m, sizeof(struct arphdr)) == NULL)) { > > log(LOG_ERR, "arp: runt packet -- m_pullup failed."

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Jim Mercer
On Thu, Mar 23, 2000 at 10:29:52AM -0800, Matthew Dillon wrote: > Jim, what C flags is make using when you compile up your kernel? Are > you trying to do weird optimizations? I don't see anything in your > kernel config, do you have anything weird in your /etc/make.conf[.local]?

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Thomas M. Sommers
Matthew Dillon wrote: > > :0xc01997a7 : sete %al > :0xc01997aa : movzbl %al,%ebxBING BING BING! > :0xc01997ad : testl %ebx,%ebx > [snip] > What the frig is this 'sete' instruction? And the movzbl ? Move byte > to long? > sete is set byte if equ

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Matthew Dillon
: :On Thu, Mar 23, 2000 at 12:45:07PM -0700, Nate Williams wrote: :> Never mind, I missed the paren. However, I would have written the fix :> as follow so I wouldn't have missed the fix. :) :> :> To each his own. :) : :so, with this fix, do you think i can consider the box stable enough for :p

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Nate Williams
> > Never mind, I missed the paren. However, I would have written the fix > > as follow so I wouldn't have missed the fix. :) > > > > To each his own. :) > > so, with this fix, do you think i can consider the box stable enough for > production? I'll let Matt answer it, but based on the back-t

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Jim Mercer
On Thu, Mar 23, 2000 at 12:45:07PM -0700, Nate Williams wrote: > Never mind, I missed the paren. However, I would have written the fix > as follow so I wouldn't have missed the fix. :) > > To each his own. :) so, with this fix, do you think i can consider the box stable enough for production?

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Nate Williams
> I found it. The code itself is broken. I missed the lack of parens. > > if (m->m_len < sizeof(struct arphdr) && > (m = m_pullup(m, sizeof(struct arphdr)) == NULL)) { > log(LOG_ERR, "arp: runt packet -- m_pullup failed."); >

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Jim Mercer
On Thu, Mar 23, 2000 at 12:56:35PM -0700, Nate Williams wrote: > > so, with this fix, do you think i can consider the box stable enough for > > production? > > I'll let Matt answer it, but based on the back-trace and Matt's > sleuthing, I'd say he fixed the cause of the panic. cool. when he sai

Re: Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Matthew Dillon
I found it. The code itself is broken. I missed the lack of parens. if (m->m_len < sizeof(struct arphdr) && (m = m_pullup(m, sizeof(struct arphdr)) == NULL)) { log(LOG_ERR, "arp: runt packet -- m_pullup failed.");

Doh, compiler bug... (was Re: possible bug in kernel/if_ether.c)

2000-03-23 Thread Matthew Dillon
Ok, lets see what we have here. %ebx is NULL at the point the code fails. (the <-- below at c01997c8) %ebx is the 'm' pointer. if (m->m_len < sizeof(struct arphdr) && :0xc0199794 : cmpl $0x7,0xc(%ebx) :0xc0199798 : ja 0xc01997c8 :0xc019979a : pushl