Re: kqueue for KBD.

From: Hans Petter Selasky <hps_at_bitfrost.no>
Date: Thu, 27 Feb 2014 12:03:29 +0100
On 02/27/14 11:59, Kohji Okuno wrote:
> +	sc = kbd->kb_dev->si_drv1;
> +	knlist_clear(&sc->gkb_rsel.si_note, 0);
> +	knlist_destroy(&sc->gkb_rsel.si_note);
> +
>   	free(kbd->kb_dev->si_drv1, M_DEVBUF);
>   	destroy_dev(kbd->kb_dev);

Hi,

You should put the "knlist_destroy()" after the "destroy_dev()" and 
leave out the "knlist_clear()" I think! Because "destroy_dev()" is a 
synchronous function which ensure that all character device refs are 
gone including knotes, if I'm not mistaken.

--HPS
Received on Thu Feb 27 2014 - 10:02:42 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:47 UTC