\hypertarget{PL_8c}{
\section{PL.c File Reference}
\label{PL_8c}\index{PL.c@{PL.c}}
}
Implements the callable interface for the PL routines.  


{\tt \#include $<$IPBS/PL.h$>$}\par
{\tt \#include $<$IPBS/L.ih$>$}\par
{\tt \#include $<$IPBS/L\_\-protos.h$>$}\par
{\tt \#include $<$IPBS/RW\_\-protos.h$>$}\par
\subsection*{Functions}
\begin{CompactItemize}
\item 
int \hyperlink{PL_8c_a5f905946c919cc7bf5dd5f17ebee555}{PL\_\-init} (\hyperlink{struct__PL__ctl}{PL\_\-ctl} $\ast$pl, \hyperlink{PL__type_8h_4bcbeacfd51c6f320d5ed29c4593dda2}{PL\_\-type} type, int nques)
\begin{CompactList}\small\item\em Initializes the list head of a doubly linked list to an empty list of the specified type. \item\end{CompactList}\item 
int \hyperlink{PL_8c_781d9452478215044ff220661e3e8fcd}{PL\_\-destroy} (\hyperlink{struct__PL__ctl}{PL\_\-ctl} $\ast$pl)
\begin{CompactList}\small\item\em Destroys the data structures associate with a PL. \item\end{CompactList}\end{CompactItemize}


\subsection{Detailed Description}
Implements the callable interface for the PL routines. 

\begin{Desc}
\item[Author:]JJRussell - \href{mailto:russell@slac.stanford.edu}{\tt russell@slac.stanford.edu}\end{Desc}


\footnotesize\begin{verbatim}
    CVS $Id: PL.c,v 1.2 2011/03/25 21:14:42 saxton Exp $
\end{verbatim}
\normalsize


This defines the callable interface for the Priority List routines. 

\subsection{Function Documentation}
\hypertarget{PL_8c_781d9452478215044ff220661e3e8fcd}{
\index{PL.c@{PL.c}!PL\_\-destroy@{PL\_\-destroy}}
\index{PL\_\-destroy@{PL\_\-destroy}!PL.c@{PL.c}}
\subsubsection[{PL\_\-destroy}]{\setlength{\rightskip}{0pt plus 5cm}int PL\_\-destroy ({\bf PL\_\-ctl} $\ast$ {\em pl})}}
\label{PL_8c_781d9452478215044ff220661e3e8fcd}


Destroys the data structures associate with a PL. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em pl}]Pointer to the PL to destroy.\end{description}
\end{Desc}
This routine frees any resources the PL list gathered when it was initialized. The actual resources released depends on both the platform and whether blocking and timeouts were requested. 

References \_\-PL\_\-ctl::rw, and RW\_\-destroy().

Referenced by FORK\_\-destroy().\hypertarget{PL_8c_a5f905946c919cc7bf5dd5f17ebee555}{
\index{PL.c@{PL.c}!PL\_\-init@{PL\_\-init}}
\index{PL\_\-init@{PL\_\-init}!PL.c@{PL.c}}
\subsubsection[{PL\_\-init}]{\setlength{\rightskip}{0pt plus 5cm}int PL\_\-init ({\bf PL\_\-ctl} $\ast$ {\em pl}, \/  {\bf PL\_\-type} {\em type}, \/  int {\em nques})}}
\label{PL_8c_a5f905946c919cc7bf5dd5f17ebee555}


Initializes the list head of a doubly linked list to an empty list of the specified type. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em pl}]Pointer to the Priority Ques control structure to initialize. \item[{\em type}]The type blocking/waiting, see PL\_\-type \item[{\em nques}]The number of ques to support \end{description}
\end{Desc}
\begin{Desc}
\item[Return values:]
\begin{description}
\item[{\em 0,Success}]\item[{\em ENOMEM,Insufficient}]memory \item[{\em ENOTSUP,Type}]not supported. \end{description}
\end{Desc}


References \_\-PL\_\-que::head, \_\-PL\_\-que::id, L\_\-init(), \_\-PL\_\-ctl::mactive, \_\-PL\_\-ctl::mcfg, \_\-PL\_\-ctl::nques, \_\-PL\_\-que::pl, PL\_\-NLIST, \_\-PL\_\-ctl::ques, \_\-PL\_\-ctl::rw, and RW\_\-init().

Referenced by FORK\_\-create().