src/ssx/occhw/occhw_async_gpe.c
// Start a GpeRequest on a GPE
//
// \param async_request A GpeRequest upcast to an AsyncRequest.
//
// This is an internal API.
//
// This routine sends an async_request to a GPE.
//
Start a GpeRequest on a GPE
\param async_request A GpeRequest upcast to an AsyncRequest.

This is an internal API.

This routine sends an async_request to a GPE.
Start a GpeRequest on a GPE \ param async_request A GpeRequest upcast to an AsyncRequest . This is an internal API . This routine sends an async_request to a GPE .
int
gpe_run_method(AsyncRequest* async_request)
{
    GpeQueue*        queue = (GpeQueue*)(async_request->queue);
    GpeRequest*      request = (GpeRequest*)async_request;
    ipc_async_cmd_t* ipc_cmd = queue->ipc_cmd;
    int rc;
    ipc_init_msg(&ipc_cmd->cmd,
                 request->targeted_func_id,
                 gpe_async_handler,
                 queue);
    ipc_cmd->cmd_data = request->cmd_data;
    rc = ipc_send_cmd(&ipc_cmd->cmd);
    if(rc)
    {
        gpe_error_method(async_request);
        async_request->completion_state = ASYNC_REQUEST_STATE_FAILED;
        rc = -ASYNC_REQUEST_COMPLETE;
    }
    return rc;
}
int gpe_run_method ( AsyncRequest * async_request ) { GpeQueue * queue = ( GpeQueue * ) ( async_request -> queue ) ; GpeRequest * request = ( GpeRequest * ) async_request ; ipc_async_cmd_t * ipc_cmd = queue -> ipc_cmd ; int rc ; ipc_init_msg ( & ipc_cmd -> cmd , request -> targeted_func_id , gpe_async_handler , queue ) ; ipc_cmd -> cmd_data = request -> cmd_data ; rc = ipc_send_cmd ( & ipc_cmd -> cmd ) ; if ( rc ) { gpe_error_method ( async_request ) ; async_request -> completion_state = ASYNC_REQUEST_STATE_FAILED ; rc = - ASYNC_REQUEST_COMPLETE ; } return rc ; }
Start a GpeRequest on a GPE
\param async_request A GpeRequest upcast to an AsyncRequest.
Start a GpeRequest on a GPE \ param async_request A GpeRequest upcast to an AsyncRequest .
//Initialize the IPC command message //Send the IPC command //If there's an error in the send, collect ffdc and mark it as //having failed.