Bogus KASSERT() in LFS?

2011-01-05 Thread Martin Husemann
Disclaimer: I know nothing about LFS, but it seems to me that there is no guarantee for curpg to not be NULL in the following code from src/sys/ufs/lfs/lfs_vnops.c: while (by_list || soff MIN(blkeof, endoffset)) { if (by_list) { /*

Re: Bogus KASSERT() in LFS?

2011-01-05 Thread Eduardo Horvath
On Wed, 5 Jan 2011, Martin Husemann wrote: Disclaimer: I know nothing about LFS, but it seems to me that there is no guarantee for curpg to not be NULL in the following code from src/sys/ufs/lfs/lfs_vnops.c: while (by_list || soff MIN(blkeof, endoffset)) { if

Re: Bogus KASSERT() in LFS?

2011-01-05 Thread Martin Husemann
On Wed, Jan 05, 2011 at 04:25:09PM +, Eduardo Horvath wrote: I think you're right. While I'm pretty sure that curpg won't be NULL on the first iteration, I think it can be NULL on subsequent iterations. I'd commit that change. It shouldn't get there on subsequent iterations if it

Re: CVS commit: src/sys/uvm

2011-01-05 Thread Masao Uebayashi
On Wed, Jan 05, 2011 at 05:58:34AM +, YAMAMOTO Takashi wrote: hi, I take silence as no objection. the silence in this case means was-busy-for-other-things-and-forgot. sorry. I have no real code for this big picture at this moment. Making vm_physseg available as reference is the

Re: Bogus KASSERT() in LFS?

2011-01-05 Thread Eduardo Horvath
On Wed, 5 Jan 2011, Martin Husemann wrote: On Wed, Jan 05, 2011 at 04:25:09PM +, Eduardo Horvath wrote: I think you're right. While I'm pretty sure that curpg won't be NULL on the first iteration, I think it can be NULL on subsequent iterations. I'd commit that change. It

Re: Bogus KASSERT() in LFS?

2011-01-05 Thread Martin Husemann
On Wed, Jan 05, 2011 at 05:03:15PM +, Eduardo Horvath wrote: If by_list is set we'll always get here, and I don't think we'd be called if the vnode had no pages at all Ok, I'll add a KASSERT() to check for that and re-run the tests. Martin

Re: Bogus KASSERT() in LFS?

2011-01-05 Thread Martin Husemann
On Wed, Jan 05, 2011 at 06:06:17PM +0100, Martin Husemann wrote: Ok, I'll add a KASSERT() to check for that and re-run the tests. Indeed, it never happens on first entry to the loop, but via the goto top later. I'll commit the original patch. Unfortunately I run into locking issues later, so

Re: Bogus KASSERT() in LFS?

2011-01-05 Thread Eduardo Horvath
On Wed, 5 Jan 2011, Martin Husemann wrote: I'll commit the original patch. Unfortunately I run into locking issues later, so this still does not fix the full test. Really? Last time I tried (about a month or two ago) I wasn't able to hang LFS. OTOH, looks like there's been quite some churn

Re: Bogus KASSERT() in LFS?

2011-01-05 Thread Martin Husemann
On Wed, Jan 05, 2011 at 07:35:53PM +, Eduardo Horvath wrote: Really? Last time I tried (about a month or two ago) I wasn't able to hang LFS. OTOH, looks like there's been quite some churn since then. What's your setup and what tests are you running? I run src/tests/fs/vfs/t_full

Re: Bogus KASSERT() in LFS?

2011-01-05 Thread Eduardo Horvath
On Wed, 5 Jan 2011, Martin Husemann wrote: On Wed, Jan 05, 2011 at 07:35:53PM +, Eduardo Horvath wrote: Really? Last time I tried (about a month or two ago) I wasn't able to hang LFS. OTOH, looks like there's been quite some churn since then. What's your setup and what tests

Providing access to the ELF Auxillary Vector for all binaries

2011-01-05 Thread Joerg Sonnenberger
Hi all, attached is a patch to provide all NetBSD binaries with a reference to the auxillary vector. This is a minor change for dynamically linked programs as the usual information are already used by ld.elf_so. It is a major change for statically linked programs as it allows the dl_iterate_phdr

Re: Providing access to the ELF Auxillary Vector for all binaries

2011-01-05 Thread Steven Bellovin
Further changes could include a careful check of initial system calls of typical process traces. One change to adopt from FreeBSD (IIRC) is to include the initial seed for arc4random to save that system call etc. Could you explain these points more carefully? What is the purpose of these

TLB tiredown by ASID bump

2011-01-05 Thread Toru Nishimura
There are growing number of CPU architecture which have ASID to extend TLB VA-PA translation and improve runtime TLB efficiency. ASID switching is the least cost MMU operation to make multiple processes run simultaneously. ASID eliminates the necessity to discard whole TLB context on each

Re: TLB tiredown by ASID bump

2011-01-05 Thread Matt Thomas
On Jan 5, 2011, at 6:41 PM, Toru Nishimura wrote: There are growing number of CPU architecture which have ASID to extend TLB VA-PA translation and improve runtime TLB efficiency. ASID switching is the least cost MMU operation to make multiple processes run simultaneously. ASID eliminates

Re: TLB tiredown by ASID bump

2011-01-05 Thread Toru Nishimura
Matt Thomas made a comment; The ASID generational stuff has a downside in that valid entries will be thrown away. For mips (and booke) I use a different algorithm which eliminates the overhead of discarding all the TLB entries when you run out of ASIDs. It's a good move to pursue efficent

Re: TLB tiredown by ASID bump

2011-01-05 Thread Matt Thomas
On Jan 5, 2011, at 9:36 PM, Toru Nishimura wrote: Matt Thomas made a comment; The ASID generational stuff has a downside in that valid entries will be thrown away. For mips (and booke) I use a different algorithm which eliminates the overhead of discarding all the TLB entries when you

Re: TLB tiredown by ASID bump

2011-01-05 Thread Matt Thomas
On Jan 5, 2011, at 9:36 PM, Toru Nishimura wrote: Matt Thomas made a comment; The ASID generational stuff has a downside in that valid entries will be thrown away. For mips (and booke) I use a different algorithm which eliminates the overhead of discarding all the TLB entries when you