On Monday 27 October 2008 09:48:00 Dirk Zimoch wrote:
>
> It might be possible to make this thread-safe by disabling interrupts
> before calling dbPvdAdd().
That won't work on any workstation OS, where epicsInterruptLock() just takes a
global mutex so it won't stop another thread from calling dvPvdFind while the
dbPvdAdd() is in the middle of initializing an unused bucket or adding a new
node (unfortunately both actions currently insert their new object before
initializing it completely).
On vxWorks and RTEMS that might be safe as long as the record has been
completely initialized before the lock is released, but I'm not sure you
could safely insert the new record into a lockset since you have to take a
lock to do that, and the OS allows itself to re-enable interrupts if your
code blocks or releases a lock. Read the vxWorks manual entry for intLock()
for details.
- Andrew
--
Talk is cheap. Show me the code. -- Linus Torvalds
- References:
- recordGenerator record Kalantari Babak
- Re: recordGenerator record Andrew Johnson
- Re: recordGenerator record Dirk Zimoch
- Navigate by Date:
- Prev:
Re: recordGenerator record Dirk Zimoch
- Next:
RE: EPICS and CAN field bus David Beauregard
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
<2008>
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Re: recordGenerator record Dirk Zimoch
- Next:
areaDetector R1-2 released Mark Rivers
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
<2008>
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|