?? pise.c
字號:
/*************************************************************************/
/* */
/* Copyright (c) 1993-1996 Accelerated Technology, Inc. */
/* */
/* PROPRIETARY RIGHTS of Accelerated Technology are involved in the */
/* subject matter of this material. All manufacturing, reproduction, */
/* use, and sales rights pertaining to this subject matter are governed */
/* by the license agreement. The recipient of this software implicitly */
/* accepts the terms of the license. */
/* */
/*************************************************************************/
/*************************************************************************/
/* */
/* FILE NAME VERSION */
/* */
/* pise.c PLUS 1.2 */
/* */
/* COMPONENT */
/* */
/* PI - Pipe Management */
/* */
/* DESCRIPTION */
/* */
/* This file contains error checking routines for supplemental */
/* functions of the Pipe component. This permits easy removal of */
/* error checking logic when it is not needed. */
/* */
/* AUTHOR */
/* */
/* William E. Lamie, Accelerated Technology, Inc. */
/* */
/* DATA STRUCTURES */
/* */
/* None */
/* */
/* FUNCTIONS */
/* */
/* PISE_Reset_Pipe Reset a pipe */
/* PISE_Send_To_Front_Of_Pipe Send message to pipe's front */
/* PISE_Broadcast_To_Pipe Broadcast message to pipe */
/* */
/* DEPENDENCIES */
/* */
/* cs_extr.h Common Service functions */
/* tc_extr.h Thread Control functions */
/* pi_extr.h Pipe functions */
/* */
/* HISTORY */
/* */
/* NAME DATE REMARKS */
/* */
/* W. Lamie 03-01-1994 Created initial version 1.1 from */
/* routines originally in core */
/* error checking file */
/* R. Pfaff - */
/* D. Lamie 03-18-1994 Verified version 1.1 */
/* M.Q. Qian 04-17-1996 updated to version 1.2 */
/* */
/*************************************************************************/
#define NU_SOURCE_FILE
#include "cs_extr.h" /* Common service functions */
#include "tc_extr.h" /* Thread control functions */
#include "pi_extr.h" /* Pipe functions */
/*************************************************************************/
/* */
/* FUNCTION */
/* */
/* PISE_Reset_Pipe */
/* */
/* DESCRIPTION */
/* */
/* This function performs error checking on the parameter supplied */
/* to the pipe reset function. */
/* */
/* AUTHOR */
/* */
/* William E. Lamie, Accelerated Technology, Inc. */
/* */
/* CALLED BY */
/* */
/* Application */
/* */
/* CALLS */
/* */
/* PIS_Reset_Pipe Actual reset pipe function */
/* */
/* INPUTS */
/* */
/* pipe_ptr Pipe control block pointer */
/* */
/* OUTPUTS */
/* */
/* NU_INVALID_PIPE Invalid pipe pointer */
/* */
/* HISTORY */
/* */
/* NAME DATE REMARKS */
/* */
/* W. Lamie 03-01-1993 Created initial version 1.0 */
/* D. Lamie 04-19-1993 Verified version 1.0 */
/* W. Lamie 03-01-1994 Modified function interface, */
/* resulting in version 1.1 */
/* R. Pfaff - */
/* D. Lamie 03-18-1994 Verified version 1.1 */
/* */
/*************************************************************************/
STATUS PISE_Reset_Pipe(NU_PIPE *pipe_ptr)
{
PI_PCB *pipe;
STATUS status;
/* Move input pipe pointer into internal pointer. */
pipe = (PI_PCB *) pipe_ptr;
/* Determine if there is an error with the pipe pointer. */
if (pipe == NU_NULL)
/* Indicate that the pipe pointer is invalid. */
status = NU_INVALID_PIPE;
else if (pipe -> pi_id != PI_PIPE_ID)
/* Indicate that the pipe pointer is invalid. */
status = NU_INVALID_PIPE;
else
/* All the parameters are okay, call the actual function to reset
a pipe. */
status = PIS_Reset_Pipe(pipe_ptr);
/* Return completion status. */
return(status);
}
/*************************************************************************/
/* */
/* FUNCTION */
/* */
/* PISE_Send_To_Front_Of_Pipe */
/* */
/* DESCRIPTION */
/* */
/* This function performs error checking on the parameters supplied */
/* to the send message to front of pipe function. */
/* */
/* AUTHOR */
/* */
/* William E. Lamie, Accelerated Technology, Inc. */
/* */
/* CALLED BY */
/* */
/* Application */
/* */
/* CALLS */
/* */
/* PIS_Send_To_Front_Of_Pipe Actual send to front of pipe */
/* function */
/* TCCE_Suspend_Error Check suspend validity */
/* */
/* INPUTS */
/* */
/* pipe_ptr Pipe control block pointer */
/* message Pointer to message to send */
/* size Size of message to send */
/* suspend Suspension option if full */
/* */
/* OUTPUTS */
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -