Uniprocessor Tests in SMP Configuration
Sebastian Huber
sebastian.huber at embedded-brains.de
Mon Feb 24 08:59:35 UTC 2014
On 2014-02-24 09:09, Joel Sherrill wrote:
> > > 2. Use alternatives to task variables for all RTEMS support components, e.g.
> > > the file system environment. Here we can use __getreent() for example with
> > >
> > > struct S {
> > > struct _reent reent;
> > > rtems_user_env_t env;
> > > }
>
> I am missing some detail here. Can you provide details?
>
Each thread can have its own file system environment. So we need some sort of
thread-local storage. Since applications using a file system will very likely
also enable the Newlib re-entrancy we can re-use the __getreent() function for
the file system environment. In newlib_create_hook() we create a structure
struct S {
struct _reent reent;
rtems_user_env_t *env;
}
and assign it to thread->libc_reent;
The file system can then use
(struct S *) __getreent()
to get its file system environment.
--
Sebastian Huber, embedded brains GmbH
Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone : +49 89 189 47 41-16
Fax : +49 89 189 47 41-09
E-Mail : sebastian.huber at embedded-brains.de
PGP : Public key available on request.
Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
More information about the devel
mailing list