Re: RFC: softint-based if_input

2016-01-28 Thread Ryota Ozaki
Hi, So here is a complete patch: http://www.netbsd.org/~ozaki-r/softint-if_input-full.diff With the patch if_input and above should not run in HW interrupt anymore. The patch includes the following changes: - Introduce softint-based if_input mechanism - It is enabled by default for all drivers

Re: I can't generate a kernel crash core.

2016-01-28 Thread Christos Zoulas
In article , Michael van Elst wrote: >chris...@astron.com (Christos Zoulas) writes: > >>It is not easy to go from dev_t -> device_t to exclude... > >Ideally its impossible because both aren't related. But >the common idiom is to search for the device with the >same name. > >Something like: > >bool

Re: I can't generate a kernel crash core.

2016-01-28 Thread Michael van Elst
bou...@antioche.eu.org (Manuel Bouyer) writes: >It's not only the dump device you need to reattach but all the >device chain up to mainbus (the detach code may have shut down a PCI >bridge for example). It doesn't look so easy. >If the dump device is open would this prevent it from being detached

Re: I can't generate a kernel crash core.

2016-01-28 Thread Michael van Elst
chris...@astron.com (Christos Zoulas) writes: >It is not easy to go from dev_t -> device_t to exclude... Ideally its impossible because both aren't related. But the common idiom is to search for the device with the same name. Something like: bool is_the_dump_device(device_t dev) { const

Re: I can't generate a kernel crash core.

2016-01-28 Thread Manuel Bouyer
On Thu, Jan 28, 2016 at 02:40:23PM +, Michael van Elst wrote: > bou...@antioche.eu.org (Manuel Bouyer) writes: > > >> The driver gets detached in config_detach_all() during a > >> regular reboot unless you use the RB_NOSYNC flag. Unfortunately > >> this also prevents unmounting and syncing the

Re: I can't generate a kernel crash core.

2016-01-28 Thread Christos Zoulas
In article , Michael van Elst wrote: >bou...@antioche.eu.org (Manuel Bouyer) writes: > >>> The driver gets detached in config_detach_all() during a >>> regular reboot unless you use the RB_NOSYNC flag. Unfortunately >>> this also prevents unmounting and syncing the filesystems. > >>RB_DUMP should

Re: I can't generate a kernel crash core.

2016-01-28 Thread Michael van Elst
bou...@antioche.eu.org (Manuel Bouyer) writes: >> The driver gets detached in config_detach_all() during a >> regular reboot unless you use the RB_NOSYNC flag. Unfortunately >> this also prevents unmounting and syncing the filesystems. >RB_DUMP should probably be handled as RB_NOSYNC then Maybe.

Re: I can't generate a kernel crash core.

2016-01-28 Thread Christos Zoulas
In article , Jose Luis Rodriguez Garcia wrote: >I have been debuging this problem with gdb and printfs in the source >for locate the path. > >I have found it fails in: > >arch/amd64/amd64/machdep.c:dodumpsys does: psize = bdev_size(dumpdev); >kern/subr_devsw.c:bdev_size calls rv = (*d->d_psize)(d

Re: RFC: softint-based if_input

2016-01-28 Thread Ryota Ozaki
On Thu, Jan 28, 2016 at 2:44 PM, Taylor R Campbell wrote: >Date: Thu, 28 Jan 2016 11:58:05 +0900 >From: Ryota Ozaki > >On Thu, Jan 28, 2016 at 12:17 AM, Taylor R Campbell > wrote: >> So vanilla might make less efficient use of the CPU cache, >> and vanilla migh

Re: I can't generate a kernel crash core.

2016-01-28 Thread Manuel Bouyer
On Thu, Jan 28, 2016 at 06:45:20AM +, Michael van Elst wrote: > joseyl...@gmail.com (Jose Luis Rodriguez Garcia) writes: > > >wd0: detached > >dumping to dev 0,1 (offset=8410383, size=1046094): > > As you have noticed, when the driver is detached, you can no > longer use its dump function. >