openbcm

Git mirror of https://github.com/Broadcom-Network-Switching-Software/OpenBCM
git clone git://git.finwo.net/mirror/broadcom/openbcm
Log | Files | Refs | README

ifa.h (4126B)


      1 /*
      2  * DO NOT EDIT THIS FILE!
      3  * This file is auto-generated.
      4  * Edits to this file will be lost when it is regenerated.
      5  *
      6  * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file.
      7  * 
      8  * Copyright 2007-2020 Broadcom Inc. All rights reserved.
      9  */
     10 
     11 #ifndef BCMINT_LTSW_MBCM_IFA_H
     12 #define BCMINT_LTSW_MBCM_IFA_H
     13 
     14 #include <bcm_int/ltsw/ifa.h>
     15 #include <bcm_int/ltsw/ifa_int.h>
     16 
     17 #include <sal/sal_types.h>
     18 
     19 /*!
     20  * \brief Init IFA module.
     21  *
     22  * \param [in] unit Unit Number.
     23  *
     24  * \retval SHR_E_NONE No errors.
     25  * \retval !SHR_E_NONE Failure.
     26  */
     27 typedef int (*ifa_init_f)(int unit);
     28 
     29 /*!
     30  * \brief Detach IFA module.
     31  *
     32  * \param [in] unit Unit Number.
     33  *
     34  * \retval SHR_E_NONE No errors.
     35  * \retval !SHR_E_NONE Failure.
     36  */
     37 typedef int (*ifa_detach_f)(int unit);
     38 
     39 /*!
     40  * \brief Get IFA LT info.
     41  *
     42  * \param [in] unit Unit Number.
     43  * \param [in] lt_db IFA LT info.
     44  *
     45  * \retval SHR_E_NONE No errors.
     46  * \retval !SHR_E_NONE Failure.
     47  */
     48 typedef int (*ifa_lt_db_get_f)(
     49     int unit,
     50     bcmint_ifa_lt_db_t *lt_db);
     51 
     52 /*!
     53  * \brief Specify IFA switch control behaviors.
     54  *
     55  * \param [in] unit Unit Number.
     56  * \param [in] control The desired configuration parameter to modify.
     57  * \param [in] value The value with which to set the parameter.
     58  *
     59  * \retval SHR_E_NONE No errors.
     60  * \retval !SHR_E_NONE Failure.
     61  */
     62 typedef int (*ifa_control_set_f)(
     63     int unit,
     64     bcmi_ltsw_ifa_control_t control,
     65     uint32_t value);
     66 
     67 /*!
     68  * \brief Retrieve IFA switch control behaviors.
     69  *
     70  * \param [in] unit Unit Number.
     71  * \param [in] control The desired configuration parameter to retrieve.
     72  * \param [out] value Pointer to where the retrieved value will be written.
     73  *
     74  * \retval SHR_E_NONE No errors.
     75  * \retval !SHR_E_NONE Failure.
     76  */
     77 typedef int (*ifa_control_get_f)(
     78     int unit,
     79     bcmi_ltsw_ifa_control_t control,
     80     uint32_t *value);
     81 
     82 /*!
     83  * \brief Ifa driver structure.
     84  */
     85 typedef struct mbcm_ltsw_ifa_drv_s {
     86 
     87     /*! Init IFA module. */
     88     ifa_init_f ifa_init;
     89 
     90     /*! Detach IFA module. */
     91     ifa_detach_f ifa_detach;
     92 
     93     /*! Get IFA LT info. */
     94     ifa_lt_db_get_f ifa_lt_db_get;
     95 
     96     /*! Specify IFA switch control behaviors. */
     97     ifa_control_set_f ifa_control_set;
     98 
     99     /*! Retrieve IFA switch control behaviors. */
    100     ifa_control_get_f ifa_control_get;
    101 
    102 } mbcm_ltsw_ifa_drv_t;
    103 
    104 /*!
    105  * \brief Set the IFA driver of the device.
    106  *
    107  * \param [in] unit Unit Number.
    108  * \param [in] drv Ifa driver to set.
    109  *
    110  * \retval SHR_E_NONE No errors.
    111  * \retval !SHR_E_NONE Failure.
    112  */
    113 extern int
    114 mbcm_ltsw_ifa_drv_set(
    115     int unit,
    116     mbcm_ltsw_ifa_drv_t *drv);
    117 
    118 /*!
    119  * \brief Init IFA module.
    120  *
    121  * \param [in] unit Unit Number.
    122  *
    123  * \retval SHR_E_NONE No errors.
    124  * \retval !SHR_E_NONE Failure.
    125  */
    126 extern int
    127 mbcm_ltsw_ifa_init(int unit);
    128 
    129 /*!
    130  * \brief Detach IFA module.
    131  *
    132  * \param [in] unit Unit Number.
    133  *
    134  * \retval SHR_E_NONE No errors.
    135  * \retval !SHR_E_NONE Failure.
    136  */
    137 extern int
    138 mbcm_ltsw_ifa_detach(int unit);
    139 
    140 /*!
    141  * \brief Get IFA LT info.
    142  *
    143  * \param [in] unit Unit Number.
    144  * \param [in] lt_db IFA LT info.
    145  *
    146  * \retval SHR_E_NONE No errors.
    147  * \retval !SHR_E_NONE Failure.
    148  */
    149 extern int
    150 mbcm_ltsw_ifa_lt_db_get(
    151     int unit,
    152     bcmint_ifa_lt_db_t *lt_db);
    153 
    154 /*!
    155  * \brief Specify IFA switch control behaviors.
    156  *
    157  * \param [in] unit Unit Number.
    158  * \param [in] control The desired configuration parameter to modify.
    159  * \param [in] value The value with which to set the parameter.
    160  *
    161  * \retval SHR_E_NONE No errors.
    162  * \retval !SHR_E_NONE Failure.
    163  */
    164 extern int
    165 mbcm_ltsw_ifa_control_set(
    166     int unit,
    167     bcmi_ltsw_ifa_control_t control,
    168     uint32_t value);
    169 
    170 /*!
    171  * \brief Retrieve IFA switch control behaviors.
    172  *
    173  * \param [in] unit Unit Number.
    174  * \param [in] control The desired configuration parameter to retrieve.
    175  * \param [out] value Pointer to where the retrieved value will be written.
    176  *
    177  * \retval SHR_E_NONE No errors.
    178  * \retval !SHR_E_NONE Failure.
    179  */
    180 extern int
    181 mbcm_ltsw_ifa_control_get(
    182     int unit,
    183     bcmi_ltsw_ifa_control_t control,
    184     uint32_t *value);
    185 
    186 #endif /* BCMINT_LTSW_MBCM_IFA_H */