Re: ttydev_cdevsw has no d_purge

From: Ed Schouten <ed_at_80386.nl>
Date: Wed, 8 Aug 2012 19:24:18 +0200
2012/8/8 Hans Petter Selasky <hselasky_at_c2i.net>:
>> I have a question regarding the changed fragment of code. Why don't you use
>> unr(9) KPI to manage unit numbers ?
>
> Probably I could, but right now the unr interface doesn't support pending unit
> free which I need for other reasons, see below.

What does `pending unit free' mean? I also would prefer it if you used
unr(9) -- not just here, but across the entire USB stack.

> Ed: I would really like to see a custom argument for the tsw_free(), because
> it only needs to know the unit number, and the xsc for UCOM is freed when this
> is called and cannot be referred. Is it possible to have a separate "void *"
> for the tsw_free() function? Is this something which you can implement?

We could extend the TTY code to allow the softc to be changed, e.g.
tty_set_softc(). This function could be called right before calling
tty_rel_gone(). Still, I would prefer it if these kind of things would
not be part of the API. Is there really no way the deallocation of the
softc can be delayed until tsw_free() is called?

Thanks,
-- 
Ed Schouten <ed_at_80386.nl>
Received on Wed Aug 08 2012 - 15:24:19 UTC

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