Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 8 Aug 2012 19:24:18 +0200
From:      Ed Schouten <ed@80386.nl>
To:        Hans Petter Selasky <hselasky@c2i.net>
Cc:        Konstantin Belousov <kostikbel@gmail.com>, freebsd-current@freebsd.org
Subject:   Re: ttydev_cdevsw has no d_purge
Message-ID:  <CAJOYFBD4DxL8ZAeKDYZwtv2FaqcV0Taw%2BLES5nc6Ry_t%2BuzfOw@mail.gmail.com>
In-Reply-To: <201208081827.53824.hselasky@c2i.net>
References:  <20120801160323.GN2676@deviant.kiev.zoral.com.ua> <201208071703.13773.hselasky@c2i.net> <20120808113133.GO2676@deviant.kiev.zoral.com.ua> <201208081827.53824.hselasky@c2i.net>

next in thread | previous in thread | raw e-mail | index | archive | help
2012/8/8 Hans Petter Selasky <hselasky@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@80386.nl>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJOYFBD4DxL8ZAeKDYZwtv2FaqcV0Taw%2BLES5nc6Ry_t%2BuzfOw>