00001 #ifndef sysap_macros_h 00002 #define sysap_macros_h 00003 00004 #include <scs_routines.h> 00005 00006 #define scs_init_cdrp( cdrp_p ) 00007 ((struct _cdrp *) cdrp_p)->cdrp_q_res_wait_state = 0; \ 00008 ((struct _cdrp *) cdrp_p)->cdrp_l_bd_addr = 0; \ 00009 ((struct _cdrp *) cdrp_p)->cdrp_l_rbun = 0; 00010 00011 #define scs_stall( stall_condition_code, cdt_p, pdt_p, cdrp_p, ravail_p ) \ 00012 scs_std_stall( stall_condition_code, cdt_p, pdt_p, cdrp_p, ravail_p ) 00013 #define alloc_msg_buf( pdt_p, cdrp_p, ravail_p ) \ 00014 scs_std_alloc_msgbuf( pdt_p, cdrp_p, ravail_p ) 00015 00016 #define recych_msg_buf( pdt_p, cdrp_p, ravail_p ) \ 00017 scs_std_rchmsgbuf( pdt_p, cdrp_p, ravail_p ) 00018 00019 #define recycl_msg_buf( pdt_p, cdrp_p, ravail_p ) \ 00020 scs_std_rclmsgbuf( pdt_p, cdrp_p, ravail_p ) 00021 #define dealloc_msg_buf( pdt_p, cdrp_p ) \ 00022 scs_std_deallocmsg( pdt_p, cdrp_p ) 00023 00024 #define dealloc_msg_buf_reg( msg_buf_p, cdt_p, pdt_p ) \ 00025 scs_std_dealrgmsg( msg_buf_p, cdt_p, pdt_p ) 00026 00027 #define restore_credit( pdt_p, cdrp_p ) \ 00028 scs_std_restore_credit( pdt_p, cdrp_p ) 00029 00030 #define alloc_dg_buf( pdt_p, cdrp_p ) \ 00031 scs_std_allocdg( pdt_p, cdrp_p ) 00032 00033 #define dealloc_dg_buf( dgbuf_p, pdt_p ) \ 00034 scs_std_deallocdg( dgbuf_p, pdt_p ) 00035 00036 #define queue_mlt_dgs( buffer_count, cdt_p, pdt_p, buffers_added_p ) \ 00037 scs_std_queuemdgs( buffer_count, cdt_p, pdt_p, buffers_added_p ) 00038 #define queue_dg_buf( dg_buf_p, cdt_p, pdt_p ) \ 00039 scs_std_queuedg( dg_buf_p, cdt_p, pdt_p ) 00040 #define alloc_rspid( cdt_p, pdt_p, cdrp_p, ravail_p ) \ 00041 scs_std_alloc_rspid( cdt_p, pdt_p, cdrp_p, ravail_p ) 00042 #define recycl_rspid( cdrp_p ) \ 00043 scs_std_recyl_rspid( cdrp_p ) 00044 #define dealloc_rspid( cdrp_p ) \ 00045 scs_std_deall_rspid( cdrp_p ) 00046 00047 #define map( svapte_boff_bcnt_p, pdt_p, cdrp_p, ravail_p ) \ 00048 scs_std_map( svapte_boff_bcnt_p, pdt_p, cdrp_p, ravail_p ) 00049 00050 #define unmap( pdt_p, cdrp_p ) \ 00051 scs_std_unmap( pdt_p, cdrp_p ) 00052 #define scan_msgbuf_wait( action_p, action_param, cdt_p ) \ 00053 scs_std_lkp_msgwait( action_p, action_param, cdt_p ) 00054 00055 #define scan_rdt( action_p, action_param, cdt_p ) \ 00056 scs_std_lkp_rdtcdrp( action_p, action_param, cdt_p ) 00057 00058 #define scan_rspid_wait( action_p, action_param, cdt_p ) \ 00059 scs_std_lkp_rdtwait( action_p, action_param, cdt_p ) 00060 00061 #define cancel_wait( rwcptr_upd, pdt_p, cdrp_p ) \ 00062 scs_std_cancel_wait( rwcptr_upd, pdt_p, cdrp_p ) 00063 00064 #define find_rspid_rdte( rspid, rdte_p ) \ 00065 scs_std_find_rdte( rspid, rdte_p ) 00066 00067 #define resume_resource_waiter( resume_status, cdrp_p ) \ 00068 scs_std_resumewaitr( resume_status, cdrp_p ) 00069 #define resume_thread( resume_status, cdrp_p ) \ 00070 scs_std_resume_thread( resume_status, cdrp_p ) 00071 00072 #define config_pth( rmst_lclprt_p, pbo_p, pb_p ) \ 00073 scs_std_config_pth( rmst_lclprt_p, pbo_p, pb_p ) 00074 00075 #define config_sys( scssystemid_p, sbo_p, sb_p ) \ 00076 scs_std_config_sys( scssystemid_p, sbo_p, sb_p ) 00077 #define poll_proc( notification_p, context_data_p, sysap_name_p, sppb_p ) \ 00078 scs_std_poll_proc( notification_p, context_data_p, sysap_name_p, sppb_p ) 00079 00080 #define poll_mode( enable_disable, sppb_p, scssystemid_p ) \ 00081 scs_std_poll_mode( enable_disable, sppb_p, scssystemid_p ) 00082 00083 #define poll_mbx( channel_number, sysap_name_p, sppb_p ) \ 00084 scs_std_poll_mbx( channel_number, sysap_name_p, sppb_p ); 00085 00086 #define cancel_mbx( sppb_p ) \ 00087 scs_std_cancel_mbx( sppb_p ) 00088 #define mreset( force_flag, rstation_p, pdt_p ) \ 00089 scs_std_mreset( force_flag, rstation_p, pdt_p ); 00090 00091 #define mstart( boot_flag, rstation_p, boot_address, pdt_p ) \ 00092 scs_std_mstart( boot_flag, rstation_p, boot_address, pdt_p ) 00093 00094 #define listen( msgadr_p, erradr_p, lprname_p, prinfo_p, cdt_p ) \ 00095 scs_std_listen( msgadr_p, erradr_p, lprname_p, prinfo_p, cdt_p ) 00096 #define accept( msgadr_p, dgadr_p, erradr_p, initcr, minscr, initdg, blkpri, \ 00097 condat_p, auxstr_p, badrsp_p, movadr_p, load_rating, \ 00098 complete_p, cdt_p, cdrp_p ) \ 00099 scs_std_accept( msgadr_p, dgadr_p, erradr_p, initcr, minscr, \ 00100 initdg, blkpri, condat_p, auxstr_p, badrsp_p, \ 00101 movadr_p, (load_rating ? load_rating : CDT_C_YELLOW), \ 00102 complete_p, cdt_p, cdrp_p ) 00103 #define reject( rejtyp, cdt_p, complete_p, cdrp_p ) \ 00104 scs_std_reject( rejtyp, cdt_p, complete_p, cdrp_p ) 00105 #define connect( msgadr_p, dgadr_p, erradr_p, rsysid_p, rstadr_p, rprnam_p, \ 00106 lprnam_p, initcr, minscr, initdg, blkpri, condat_p, auxstr_p, \ 00107 badrsp_p, movadr_p, load_rating, req_fast_recvmsg_p, \ 00108 fast_recvmsg_pm_p, change_aff_p, complete_p, connect_parameter ) \ 00109 scs_std_connect( msgadr_p, dgadr_p, erradr_p, rsysid_p, rstadr_p, \ 00110 rprnam_p, lprnam_p, initcr, minscr, initdg, blkpri, \ 00111 condat_p, auxstr_p, badrsp_p, movadr_p, \ 00112 (load_rating ? load_rating : CDT_C_YELLOW), \ 00113 req_fast_recvmsg_p, fast_recvmsg_pm_p, change_aff_p, \ 00114 complete_p, connect_parameter ) 00115 00116 #define disconnect( distyp, cdt_p, complete_p, disparam ) \ 00117 scs_std_disconnect( distyp, cdt_p, complete_p, disparam ) 00118 00119 #define set_load_rating( rating, cdt_p ) \ 00120 scs_std_set_load_rating( rating, cdt_p ) 00121 00122 #define reqdata( pdt_p, cdrp_p, complete_p ) \ 00123 scs_std_reqdata( pdt_p, cdrp_p, complete_p ) 00124 00125 #define senddata( pdt_p, cdrp_p, complete_p ) \ 00126 scs_std_senddata( pdt_p, cdrp_p, complete_p ) 00127 00128 #define senddatawm( pdt_p, cdrp_p, complete_p ) \ 00129 scs_std_senddata_wmsg( pdt_p, cdrp_p, complete_p ) 00130 00131 #define request_data( pdt_p, cdrp_p, complete_p ) \ 00132 scs_std_request_data( pdt_p, cdrp_p, complete_p ) 00133 00134 #define send_data( pdt_p, cdrp_p, complete_p ) \ 00135 scs_std_send_data( pdt_p, cdrp_p, complete_p ) 00136 00137 #define send_data_wmsg( msg_buf_len, pdt_p, cdrp_p, complete_p ) \ 00138 scs_std_send_data_wmsg( msg_buf_len, pdt_p, cdrp_p, complete_p ) 00139 #define send_dg_buf( disposition_flag, db_msg_length, cdrp_p ) \ 00140 scs_std_senddg( disposition_flag, db_msg_length, cdrp_p ) 00141 00142 #define send_dg_buf_reg( disposition_flag, dg_msg_length, dg_buf_p, cdt_p, pdt_p ) \ 00143 scs_std_sendrgdg( disposition_flag, dg_msg_length, dg_buf_p, cdt_p, pdt_p ) 00144 00145 #define sendmsgbuf( pdt_p, cdrp_p, complete_p ) \ 00146 scs_std_sendmsg( SCS$GW_MAXMSG, pdt_p, cdrp_p, complete_p ) 00147 00148 #define sendcntmsgbuf( buf_size, pdt_p, cdrp_p, complete_p ) \ 00149 scs_std_sendmsg( buf_size, pdt_p, cdrp_p, complete_p ) 00150 00151 #define FAST_SENDMSG_REQUEST( svapte_boff_bcnt_p, pdt_p, cdrp_p ) \ 00152 scs_std_fast_sendmsg_request( svapte_boff_bcnt_p, pdt_p, cdrp_p ) 00153 00154 #define fast_sendmsg_associate_pm( svapte_boff_bcnt_p, pdt_p, cdrp_p ) \ 00155 scs_std_fast_sendmsg_ass_res_pm( svapte_boff_bcnt_p, pdt_p, cdrp_p ) 00156 #define fast_sendmsg_pm( msg_buf_len, cdt_p, pdt_p, cdrp_p, complete_p ) \ 00157 scs_std_fast_sendmsg_pm( msg_buf_len, cdt_p, pdt_p, cdrp_p, complete_p ) 00158 #define fast_recvmsg_chk_res( cdt_p, pdt_p, cdrp_p ) \ 00159 ( cdrp_p->cdrp_l_rbun ? SS$_NORMAL : \ 00160 ( cdrp_p->cdrp_l_scs_state & cdrp$v_rbun_wanted ? \ 00161 scs_std_fast_recvmsg_chk_res( cdt_p, pdt_p, cdrp_p ) : 0 ) ) 00162 00163 #define repo_cdrp( pdt_p, cdrp_p ) \ 00164 scs_std_repossess_cdrp( pdt_p, cdrp_p ); 00165 00166 #endif 00167