SysLink API Reference  2.21.03.11
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Notify.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2012, Texas Instruments Incorporated
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions
7  * are met:
8  *
9  * * Redistributions of source code must retain the above copyright
10  * notice, this list of conditions and the following disclaimer.
11  *
12  * * Redistributions in binary form must reproduce the above copyright
13  * notice, this list of conditions and the following disclaimer in the
14  * documentation and/or other materials provided with the distribution.
15  *
16  * * Neither the name of Texas Instruments Incorporated nor the names of
17  * its contributors may be used to endorse or promote products derived
18  * from this software without specific prior written permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
22  * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23  * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
24  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
25  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
26  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
27  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
29  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
30  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  * */
104 #ifndef ti_ipc_Notify__include
105 #define ti_ipc_Notify__include
106 
107 #if defined (__cplusplus)
108 extern "C" {
109 #endif
110 
111 /* =============================================================================
112  * All success and failure codes for the module
113  * =============================================================================
114  */
115 
119 #define Notify_S_BUSY 2
120 
124 #define Notify_S_ALREADYSETUP 1
125 
129 #define Notify_S_SUCCESS 0
130 
134 #define Notify_E_FAIL -1
135 
139 #define Notify_E_INVALIDARG -2
140 
144 #define Notify_E_MEMORY -3
145 
149 #define Notify_E_ALREADYEXISTS -4
150 
154 #define Notify_E_NOTFOUND -5
155 
159 #define Notify_E_TIMEOUT -6
160 
164 #define Notify_E_INVALIDSTATE -7
165 
169 #define Notify_E_OSFAILURE -8
170 
174 #define Notify_E_ALREADYSETUP -9
175 
179 #define Notify_E_RESOURCE -10
180 
184 #define Notify_E_RESTART -11
185 
189 #define Notify_E_BUSY -12
190 
194 #define Notify_E_DRIVERNOTREGISTERED -13
195 
199 #define Notify_E_EVTNOTREGISTERED -14
200 
204 #define Notify_E_EVTDISABLED -15
205 
209 #define Notify_E_NOTINITIALIZED -16
210 
214 #define Notify_E_EVTRESERVED -17
215 
216 /* =============================================================================
217  * Macros
218  * =============================================================================
219  */
220 
224 #define Notify_MAXEVENTS (UInt16)32
225 
229 #define Notify_MAX_INTLINES 4u
230 
236 #define Notify_SYSTEMKEY ((UInt16)0xC1D2)
237 
238 /* =============================================================================
239  * Structures & Enums
240  * =============================================================================
241  */
242 
255 
256 /* =============================================================================
257  * Notify Module-wide Functions
258  * =============================================================================
259  */
260 
286 Int Notify_attach(UInt16 remoteProcId, Ptr sharedAddr);
287 
311 UInt Notify_disable(UInt16 procId, UInt16 lineId);
312 
336 Void Notify_disableEvent(UInt16 procId, UInt16 lineId, UInt32 eventId);
337 
356 Void Notify_enableEvent(UInt16 procId, UInt16 lineId, UInt32 eventId);
357 
384 Bool Notify_eventAvailable(UInt16 procId, UInt16 lineId, UInt32 eventId);
385 
401 Bool Notify_intLineRegistered(UInt16 procId, UInt16 lineId);
402 
413 UInt16 Notify_numIntLines(UInt16 procId);
414 
428 SizeT Notify_sharedMemReq(UInt16 procId, Ptr sharedAddr);
429 
462 Int Notify_registerEvent(UInt16 procId,
463  UInt16 lineId,
464  UInt32 eventId,
465  Notify_FnNotifyCbck fnNotifyCbck,
466  UArg cbckArg);
467 
494 Int Notify_registerEventSingle(UInt16 procId,
495  UInt16 lineId,
496  UInt32 eventId,
497  Notify_FnNotifyCbck fnNotifyCbck,
498  UArg cbckArg);
499 
515 Void Notify_restore(UInt16 procId, UInt16 lineId, UInt key);
516 
563 Int Notify_sendEvent(UInt16 procId, UInt16 lineId, UInt32 eventId,
564  UInt32 payload, Bool waitClear);
565 
589 Int Notify_unregisterEvent(UInt16 procId, UInt16 lineId, UInt32 eventId,
590  Notify_FnNotifyCbck fnNotifyCbck, UArg cbckArg);
591 
609 Int Notify_unregisterEventSingle(UInt16 procId, UInt16 lineId, UInt32 eventId);
610 
611 #if defined (__cplusplus)
612 }
613 #endif /* defined (__cplusplus) */
614 #endif /* ti_ipc_Notify__include */
615 
616 /*
617  */
618 
619 /*
620  * @(#) ti.ipc; 1, 0, 0, 0,; 11-7-2012 13:07:52; /db/vtree/library/trees/ipc/ipc-i09/src/ xlibrary
621 
622  */
623 
Copyright 2014, Texas Instruments Incorporated