summaryrefslogtreecommitdiffstats
path: root/meta-agl-bsp/recipes-kernel/kern-tools-native
diff options
context:
space:
mode:
Diffstat (limited to 'meta-agl-bsp/recipes-kernel/kern-tools-native')
-rw-r--r--meta-agl-bsp/recipes-kernel/kern-tools-native/files/0001-merge_config.sh-add-CR-after-fragment.patch34
-rw-r--r--meta-agl-bsp/recipes-kernel/kern-tools-native/kern-tools-native_git.bbappend6
2 files changed, 0 insertions, 40 deletions
diff --git a/meta-agl-bsp/recipes-kernel/kern-tools-native/files/0001-merge_config.sh-add-CR-after-fragment.patch b/meta-agl-bsp/recipes-kernel/kern-tools-native/files/0001-merge_config.sh-add-CR-after-fragment.patch
deleted file mode 100644
index 350f9d4bf..000000000
--- a/meta-agl-bsp/recipes-kernel/kern-tools-native/files/0001-merge_config.sh-add-CR-after-fragment.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 8d12bbfc6179d7e9777e4663e10f1795de158b57 Mon Sep 17 00:00:00 2001
-From: Stephane Desneux <stephane.desneux@iot.bzh>
-Date: Tue, 5 Jun 2018 10:53:24 +0200
-Subject: [PATCH] tools/merge_config.sh: add CR after each fragment
-
-If a fragment file doesn't contain a CR at the end, two config options
-may be merged on the same line in the result file, leading to misconfiguration.
-
-This patch adds a CR after each fragment to ensure that config options
-are well separated in the result file.
-
-Bug-AGL: SPEC-1475
-
-Signed-off-by: Stephane Desneux <stephane.desneux@iot.bzh>
----
- tools/merge_config.sh | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/tools/merge_config.sh b/tools/merge_config.sh
-index 67d1314..296e759 100755
---- a/tools/merge_config.sh
-+++ b/tools/merge_config.sh
-@@ -129,6 +129,8 @@ for MERGE_FILE in $MERGE_LIST ; do
- sed -i "/$CFG[ =]/d" $TMP_FILE
- done
- cat $MERGE_FILE >> $TMP_FILE
-+ # workaround for fragments not ending with carriage return
-+ echo >> $TMP_FILE
- done
-
- if [ "$RUNMAKE" = "false" ]; then
---
-2.1.4
-
diff --git a/meta-agl-bsp/recipes-kernel/kern-tools-native/kern-tools-native_git.bbappend b/meta-agl-bsp/recipes-kernel/kern-tools-native/kern-tools-native_git.bbappend
deleted file mode 100644
index 814278302..000000000
--- a/meta-agl-bsp/recipes-kernel/kern-tools-native/kern-tools-native_git.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
-
-SRC_URI += "\
- file://0001-merge_config.sh-add-CR-after-fragment.patch;patchdir=git \
- "
-
ht .mf { color: #ae81ff } /* Literal.Number.Float */ .highlight .mh { color: #ae81ff } /* Literal.Number.Hex */ .highlight .mi { color: #ae81ff } /* Literal.Number.Integer */ .highlight .mo { color: #ae81ff } /* Literal.Number.Oct */ .highlight .sa { color: #e6db74 } /* Literal.String.Affix */ .highlight .sb { color: #e6db74 } /* Literal.String.Backtick */ .highlight .sc { color: #e6db74 } /* Literal.String.Char */ .highlight .dl { color: #e6db74 } /* Literal.String.Delimiter */ .highlight .sd { color: #e6db74 } /* Literal.String.Doc */ .highlight .s2 { color: #e6db74 } /* Literal.String.Double */ .highlight .se { color: #ae81ff } /* Literal.String.Escape */ .highlight .sh { color: #e6db74 } /* Literal.String.Heredoc */ .highlight .si { color: #e6db74 } /* Literal.String.Interpol */ .highlight .sx { color: #e6db74 } /* Literal.String.Other */ .highlight .sr { color: #e6db74 } /* Literal.String.Regex */ .highlight .s1 { color: #e6db74 } /* Literal.String.Single */ .highlight .ss { color: #e6db74 } /* Literal.String.Symbol */ .highlight .bp { color: #f8f8f2 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #a6e22e } /* Name.Function.Magic */ .highlight .vc { color: #f8f8f2 } /* Name.Variable.Class */ .highlight .vg { color: #f8f8f2 } /* Name.Variable.Global */ .highlight .vi { color: #f8f8f2 } /* Name.Variable.Instance */ .highlight .vm { color: #f8f8f2 } /* Name.Variable.Magic */ .highlight .il { color: #ae81ff } /* Literal.Number.Integer.Long */ } @media (prefers-color-scheme: light) { .highlight .hll { background-color: #ffffcc } .highlight .c { color: #888888 } /* Comment */ .highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */ .highlight .k { color: #008800; font-weight: bold } /* Keyword */ .highlight .ch { color: #888888 } /* Comment.Hashbang */ .highlight .cm { color: #888888 } /* Comment.Multiline */ .highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */ .highlight .cpf { color: #888888 } /* Comment.PreprocFile */ .highlight .c1 { color: #888888 } /* Comment.Single */ .highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */ .highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */ .highlight .ge { font-style: italic } /* Generic.Emph */ .highlight .gr { color: #aa0000 } /* Generic.Error */ .highlight .gh { color: #333333 } /* Generic.Heading */ .highlight .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */ .highlight .go { color: #888888 } /* Generic.Output */ .highlight .gp { color: #555555 } /* Generic.Prompt */ .highlight .gs { font-weight: bold } /* Generic.Strong */ .highlight .gu { color: #666666 } /* Generic.Subheading */ .highlight .gt { color: #aa0000 } /* Generic.Traceback */ .highlight .kc { color: #008800; font-weight: bold } /* Keyword.Constant */ .highlight .kd { color: #008800; font-weight: bold } /* Keyword.Declaration */ .highlight .kn { color: #008800; font-weight: bold } /* Keyword.Namespace */ .highlight .kp { color: #008800 } /* Keyword.Pseudo */ .highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */ .highlight .kt { color: #888888; font-weight: bold } /* Keyword.Type */ .highlight .m { color: #0000DD; font-weight: bold } /* Literal.Number */ .highlight .s { color: #dd2200; background-color: #fff0f0 } /* Literal.String */ .highlight .na { color: #336699 } /* Name.Attribute */ .highlight .nb { color: #003388 } /* Name.Builtin */ .highlight .nc { color: #bb0066; font-weight: bold } /* Name.Class */ .highlight .no { color: #003366; font-weight: bold } /* Name.Constant */ .highlight .nd { color: #555555 } /* Name.Decorator */ .highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */ }
/*------------------------------------------------------------------------------------------------*/
/* UNICENS V2.1.0-3491                                                                            */
/* Copyright (c) 2017 Microchip Technology Germany II GmbH & Co. KG.                              */
/*                                                                                                */
/* This program is free software: you can redistribute it and/or modify                           */
/* it under the terms of the GNU General Public License as published by                           */
/* the Free Software Foundation, either version 2 of the License, or                              */
/* (at your option) any later version.                                                            */
/*                                                                                                */
/* This program is distributed in the hope that it will be useful,                                */
/* but WITHOUT ANY WARRANTY; without even the implied warranty of                                 */
/* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the                                  */
/* GNU General Public License for more details.                                                   */
/*                                                                                                */
/* You should have received a copy of the GNU General Public License                              */
/* along with this program.  If not, see <http://www.gnu.org/licenses/>.                          */
/*                                                                                                */
/* You may also obtain this software under a propriety license from Microchip.                    */
/* Please contact Microchip for further information.                                              */
/*------------------------------------------------------------------------------------------------*/

/*!
 * \file
 * \brief Internal header file of the Connection Storage Pool.
 *
 * \cond UCS_INTERNAL_DOC
 * \addtogroup G_UCS_XRM_INT
 * @{
 */


#ifndef UCS_XRMPOOL_H
#define UCS_XRMPOOL_H

/*------------------------------------------------------------------------------------------------*/
/* Includes                                                                                       */
/*------------------------------------------------------------------------------------------------*/
#include "ucs_xrm_pb.h"
#include "ucs_dl.h"

#ifdef __cplusplus
extern "C"
{
#endif

/*------------------------------------------------------------------------------------------------*/
/* Type definitions                                                                               */
/*------------------------------------------------------------------------------------------------*/
/*! \brief Callback signature used by foreach-function for the resources list
 *  \param rc_ptr    Reference to a resource object in the list
 *  \param ud_ptr1   Reference to the user data 1
 *  \param ud_ptr2   Reference to the user data 2
 *  \param ud_ptr3   Reference to the user data 3
 *  \return true: Stop the for-each-loop
 *  \return false: Continue the for-each-loop
 */
typedef bool (*Xrmp_ForeachFunc_t)(void *rc_ptr, void *ud_ptr1, void *ud_ptr2, void *ud_ptr3);

/*! \brief Callback signature used by _GetResourceHandle-function to check whether found resources belongs to provided jobs list
 *  \param xrm_inst  Reference to the XRM instance to be looked for
 *  \param job_ptr   Reference to the job list to be checked
 *  \return true:    Stop the for-each-loop since given job matches, otherwise
 *  \return false:   Continue the for-each-loop in order to catch new jobs.
 */
typedef bool (*Xrmp_CheckJobListFunc_t)(void * xrm_inst, void * job_ptr);

/*! \brief  Function signature used for the results and reports of the Extended Resource Manager.
 *  \param  node_address        The node address from which the results come 
 *  \param  connection_label    Returned MOST network connection label
 *  \param  result              Result of the job
 *  \param  user_arg            Reference to the user argument
 *  \ingroup G_UCS_IRM
 */
typedef void (*Ucs_Xrm_ReportCb_t)(uint16_t node_address, uint16_t connection_label, Ucs_Xrm_Result_t result, void * user_arg);

/*------------------------------------------------------------------------------------------------*/
/* Structures                                                                                     */
/*------------------------------------------------------------------------------------------------*/
/*! \brief  Structure that defines a job of the Extended Resource Manager. */
typedef struct Xrm_Job_
{
    /*! \brief Reference to resource object list */
    UCS_XRM_CONST Ucs_Xrm_ResObject_t **resource_object_list_ptr;
    /*! \brief Report callback of the job */
    Ucs_Xrm_ReportCb_t report_fptr;
    /*! \brief User defined MOST connection label */
    uint16_t most_network_connection_label;
    /*! \brief MOST connection label, returned during MOST socket creation */
    uint16_t connection_label;
    /*!< \brief Node required for jobs pool */
    CDlNode node;
    /*! \brief address of the device in which the job is built */
    bool sync_lost;
    /*! \brief State of the job (valid/invalid) */
    bool valid;
    /*! \brief Notification flag */
    bool notify;
    /*!< \brief user argument */
    void * user_arg;

} Xrm_Job_t;

/*! \brief  Structure that defines an item of the resource handle list. */
typedef struct Xrm_ResourceHandleListItem_
{
    /*! \brief Reference to the job */
    Xrm_Job_t *job_ptr;
    /*! \brief Reference to the resource object */
    UCS_XRM_CONST Ucs_Xrm_ResObject_t *resource_object_ptr;
    /*! \brief INIC Resource handle */
    uint16_t resource_handle;

} Xrm_ResourceHandleListItem_t;

/*! \brief  Class structure of the Storage Pool of XRM Jobs and Resources. */
typedef struct CXrmPool_
{
    /*! \brief Job list */
    Xrm_Job_t job_list[XRM_NUM_JOBS];
    /*! \brief List of resource handles */
    Xrm_ResourceHandleListItem_t resource_handle_list[XRM_NUM_RESOURCE_HANDLES];
    /*!< \brief Reference to the resource identification table */
    Ucs_Xrm_ResIdentity_t * res_id_ptr;
    /*! \brief Size of the resources Id table.
     */
    uint16_t res_id_size;

} CXrmPool;

/*------------------------------------------------------------------------------------------------*/
/* Prototypes of class CXrmPool                                                                   */
/*------------------------------------------------------------------------------------------------*/
extern void Xrmp_Ctor(CXrmPool * self);
extern bool Xrmp_StoreResourceHandle(CXrmPool * self_ptr, uint16_t resource_handle, Xrm_Job_t * job_ptr, UCS_XRM_CONST Ucs_Xrm_ResObject_t * resource_object_ptr);
extern uint16_t Xrmp_GetResourceHandle(CXrmPool * self, Xrm_Job_t * job_ptr, UCS_XRM_CONST Ucs_Xrm_ResObject_t * resource_object_ptr, Xrmp_CheckJobListFunc_t func_ptr, void * usr_ptr);
extern uint8_t Xrmp_GetResourceHandleIdx(CXrmPool *self, Xrm_Job_t *job_ptr, UCS_XRM_CONST Ucs_Xrm_ResObject_t **obj_pptr);
extern Xrm_Job_t * Xrmp_GetJob(CXrmPool * self, UCS_XRM_CONST Ucs_Xrm_ResObject_t * resource_object_list[]);
extern void Xrmp_Foreach(CXrmPool *self, Xrmp_ForeachFunc_t func_ptr, void *user_data_ptr1, void *user_data_ptr2, void *user_data_ptr3);

#ifdef __cplusplus
}   /* extern "C" */
#endif

#endif /* #ifndef UCS_XRMPOOL_H */

/*!
 * @}
 * \endcond
 */

/*------------------------------------------------------------------------------------------------*/
/* End of file                                                                                    */
/*------------------------------------------------------------------------------------------------*/