src/C/perm.c
bool perm_dmashm_is_granted(e_task_id from,
                            e_task_id to)
{
    /* sanitizing */
    if ((from == ID_UNUSED) || (to == ID_UNUSED)) {
        return false;
    }
    if ((from > ID_APPMAX) || (to > ID_APPMAX)) {
        return false;
    }
    /*
     * In C, table rows start with 0. EwoK id start with 1,
     * we need to decrement id in consequence
     */
    return com_dmashm_perm[from - 1][to - 1];
}
/**
 * \brief test if a task is allow to declare a DMA SHM with another task
 *
 * Here we are based on a symetric paradigm (i.e. when a
 * task is allowed to declare a DMA SHM with another task, the other
 * task is allowed to host a DMA SHM from it). Nonetheless it
 * is still an half duplex communication channel (DMA SHM are
 * read-only or write-only, accessible only by the DMA controler
 * and never mapped into the task memory slot).
 *
 * \param[in] from the task which want to declare a DMA SHM
 * \param[in] tto  the task target of the DMA SHM peering
 *
 * \return true if the permission is granted, of false
 *
 */
\brief test if a task is allow to declare a DMA SHM with another task
Here we are based on a symetric paradigm . Nonetheless it
is still an half duplex communication channel (DMA SHM are
read-only or write-only, accessible only by the DMA controler
and never mapped into the task memory slot).

\param[in] from the task which want to declare a DMA SHM
\param[in] tto  the task target of the DMA SHM peering

\return true if the permission is granted, of false
\ brief test if a task is allow to declare a DMA SHM with another task Here we are based on a symetric paradigm . Nonetheless it is still an half duplex communication channel ( DMA SHM are read - only or write - only accessible only by the DMA controler and never mapped into the task memory slot ) . \ param [ in ] from the task which want to declare a DMA SHM \ param [ in ] tto the task target of the DMA SHM peering \ return true if the permission is granted of false
bool perm_dmashm_is_granted(e_task_id from,
                            e_task_id to)
{
    if ((from == ID_UNUSED) || (to == ID_UNUSED)) {
        return false;
    }
    if ((from > ID_APPMAX) || (to > ID_APPMAX)) {
        return false;
    }
    return com_dmashm_perm[from - 1][to - 1];
}
bool perm_dmashm_is_granted ( e_task_id from , e_task_id to ) { if ( ( from == ID_UNUSED ) || ( to == ID_UNUSED ) ) { return false ; } if ( ( from > ID_APPMAX ) || ( to > ID_APPMAX ) ) { return false ; } return com_dmashm_perm [ from - 1 ] [ to - 1 ] ; }
\brief test if a task is allow to declare a DMA SHM with another task
 Here we are based on a symetric paradigm (i.e.
\ brief test if a task is allow to declare a DMA SHM with another task Here we are based on a symetric paradigm ( i . e .
/* sanitizing */ /*
     * In C, table rows start with 0. EwoK id start with 1,
     * we need to decrement id in consequence
     */