EasyManuals Logo

Texas Instruments TMS320 User Manual

Texas Instruments TMS320
288 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #216 background imageLoading...
Page #216 background image
Data Pipe Manager (PIP Module)
6-14
The pipe's reader function, the HWI routine, calls PIP_get to read data from
the pipe. The pipe's writer function, the SWI routine, calls PIP_put. Since the
call to the notifyReader happens within PIP_put in the context of the current
routine, a call to PIP_get also happens from the SWI writer routine.
Hence, in the example described two threads with different priorities call PIP_get
for the same pipe. This could have catastrophic consequences if one thread
preempts the other and as a result, PIP_get is called twice before calling PIP_free,
or PIP_get is preempted and called again for the same pipe from a different thread.
Note:
As a general rule to avoid recursion, you should avoid calling PIP functions
as part of notifyReader and notifyWriter. If necessary for application
efficiency, such calls should be protected to prevent reentrancy for the
same pipe object and the wrong calling sequence for the PIP APIs.

Table of Contents

Other manuals for Texas Instruments TMS320

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments TMS320 and is the answer not in the manual?

Texas Instruments TMS320 Specifications

General IconGeneral
BrandTexas Instruments
ModelTMS320
CategoryComputer Hardware
LanguageEnglish

Related product manuals