On Fri, Nov 27, 2015 at 08:09:15AM +0200, Michael Smith wrote:
> Hi.
> I am in the process of writing a rtdm device driver that is accessing
> another rtmd driver.
> But I am having difficulty finding an rtdm alternative for something
> like the try_module_get() &
> module_put().
> Where the 1st module effectively locks the 2nd module from unloading
> (via the module's reference count) until the 1st module is finished
> accessing it.
>
> Is there workaround for this, or an Xenomai alternative?
You can use try_module_get() and module_put(), starting from the
I-pipe patch for Linux 3.14, these can be called from real-time
context. Also note that if you plan to use
try_module_get()/module_put() from the driver open and close
callbacks, these callbacks are called from secondary mode anyway, so
they can use any Linux service.
--
Gilles.
https://click-hack.org
_______________________________________________
Xenomai mailing list
[email protected]
http://xenomai.org/mailman/listinfo/xenomai