summaryrefslogtreecommitdiff
path: root/cleopatre/application/spidnetsnmp/agent
diff options
context:
space:
mode:
authorTom Yang2012-06-01 07:51:06 +0530
committerTom Yang2012-06-05 06:22:27 +0530
commit71f1433c9da1c4ac038e895cefe4be601e71d424 (patch)
tree10512c70dfd1d91f4259426222614e49e0059a9b /cleopatre/application/spidnetsnmp/agent
parenta6d6b1d0d744254d6e155885cbcb25bbed426021 (diff)
cleo/app/snmp[eoc]: generate eocCBATCardMACCNUIsolationTable skeleton code, refs #3156
- modify MIB file for eocCBATCardMACCNUIsolationEN value use disable(0), enable(1) - depends the new MIB file generate skeleton code
Diffstat (limited to 'cleopatre/application/spidnetsnmp/agent')
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable.h10
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/defaults/table-eocCBATCardMACCNUIsolationTable.m2d2
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable-README-eocCBATCardMACCNUIsolationTable.txt14
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable.h10
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_access.c133
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.c58
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.h2
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_set.c179
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_enums.h19
-rw-r--r--cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_interface.c104
10 files changed, 163 insertions, 368 deletions
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable.h b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable.h
index 5411c92632..848dad1860 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable.h
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable.h
@@ -1,5 +1,5 @@
-config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get)
-config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable)
-config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_set)
-config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_access)
-config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_interface)
+//config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get)
+//config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable)
+//config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_set)
+//config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_access)
+//config_require(mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_interface)
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/defaults/table-eocCBATCardMACCNUIsolationTable.m2d b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/defaults/table-eocCBATCardMACCNUIsolationTable.m2d
index 35d9353f46..ffc9123e1b 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/defaults/table-eocCBATCardMACCNUIsolationTable.m2d
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/defaults/table-eocCBATCardMACCNUIsolationTable.m2d
@@ -86,7 +86,7 @@
## Skip mapping between data context and MIB formats?
## // 0:generate maps, 1:skip maps, -1:skip unless enum/oid
##
-@eval $m2c_table_skip_mapping = -1@
+@eval $m2c_table_skip_mapping = 1@
##
## ########################################################################
##
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable-README-eocCBATCardMACCNUIsolationTable.txt b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable-README-eocCBATCardMACCNUIsolationTable.txt
index d12c8fe5bc..1934979a22 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable-README-eocCBATCardMACCNUIsolationTable.txt
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable-README-eocCBATCardMACCNUIsolationTable.txt
@@ -153,8 +153,8 @@ eocCBATCardMACCNUIsolationTable README
The index(es) for the eocCBATCardMACCNUIsolationTable table are:
eocCBATCardMACCNUIsolationIndex:
- Syntax: INTEGER
- DataType: INTEGER
+ Syntax: INTEGER32
+ DataType: INTEGER32
ASN type: ASN_INTEGER
C-code type: long
@@ -512,7 +512,7 @@ Table / column details
* Its status is Current, and its access level is ReadOnly.
* OID: .1.3.6.1.4.1.17409.2.4.3.1.1.1
* Description:
-CBAT板卡的序号索引
+
*
* Attributes:
* accessible 1 isscalar 0 enums 0 hasdefval 0
@@ -520,7 +520,7 @@ CBAT板卡的序号索引
* settable 0
*
*
- * Its syntax is INTEGER (based on perltype INTEGER)
+ * Its syntax is INTEGER32 (based on perltype INTEGER32)
* The net-snmp type is ASN_INTEGER. The C type decl is long (long)
*/
/*---------------------------------------------------------------------
@@ -529,16 +529,16 @@ CBAT板卡的序号索引
* Its status is Current, and its access level is ReadWrite.
* OID: .1.3.6.1.4.1.17409.2.4.3.1.1.2
* Description:
-CBAT板卡MAC层CNU隔离管理开关。1-表示隔离,0-表示不隔离
+
*
* Attributes:
* accessible 1 isscalar 0 enums 1 hasdefval 0
* readable 1 iscolumn 1 ranges 0 hashint 0
* settable 1
*
- * Enum range: 2/8. Values: true(1), false(2)
+ * Enum range: 2/8. Values: disable(0), enable(1)
*
- * Its syntax is TruthValue (based on perltype INTEGER)
+ * Its syntax is INTEGER (based on perltype INTEGER)
* The net-snmp type is ASN_INTEGER. The C type decl is long (u_long)
*/
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable.h b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable.h
index 86cbabc152..5b8c93db7a 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable.h
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable.h
@@ -20,6 +20,11 @@ extern "C" {
/* other required module components */
/* *INDENT-OFF* */
+config_add_mib(NSCRTV-EPONEOC-MOD-EOC-MIB)
+config_require(NSCRTV-EPONEOC-MOD-EOC-MIB/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_interface)
+config_require(NSCRTV-EPONEOC-MOD-EOC-MIB/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_access)
+config_require(NSCRTV-EPONEOC-MOD-EOC-MIB/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get)
+config_require(NSCRTV-EPONEOC-MOD-EOC-MIB/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_set)
/* *INDENT-ON* */
/* OID and column number definitions for eocCBATCardMACCNUIsolationTable */
@@ -28,7 +33,6 @@ extern "C" {
/* enum definions */
#include "eocCBATCardMACCNUIsolationTable_enums.h"
-#include "EoCCommon.h"
/* *********************************************************************
* function declarations
*/
@@ -74,7 +78,7 @@ typedef netsnmp_data_list eocCBATCardMACCNUIsolationTable_registration;
typedef struct eocCBATCardMACCNUIsolationTable_data_s {
/*
- * eocCBATCardMACCNUIsolationEN(2)/TruthValue/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h
+ * eocCBATCardMACCNUIsolationEN(2)/INTEGER/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h
*/
u_long eocCBATCardMACCNUIsolationEN;
@@ -96,7 +100,7 @@ typedef eocCBATCardMACCNUIsolationTable_data eocCBATCardMACCNUIsolationTable_und
typedef struct eocCBATCardMACCNUIsolationTable_mib_index_s {
/*
- * eocCBATCardMACCNUIsolationIndex(1)/INTEGER/ASN_INTEGER/long(long)//l/A/w/e/r/d/h
+ * eocCBATCardMACCNUIsolationIndex(1)/INTEGER32/ASN_INTEGER/long(long)//l/A/w/e/r/d/h
*/
long eocCBATCardMACCNUIsolationIndex;
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_access.c b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_access.c
index cb8b21d9d5..c6fa8e08cb 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_access.c
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_access.c
@@ -186,25 +186,21 @@ eocCBATCardMACCNUIsolationTable_container_shutdown(netsnmp_container *container_
*
*/
int
-eocCBATCardMACCNUIsolationTable_container_load (netsnmp_container * container)
+eocCBATCardMACCNUIsolationTable_container_load(netsnmp_container *container)
{
eocCBATCardMACCNUIsolationTable_rowreq_ctx *rowreq_ctx;
- size_t count = 0;
+ size_t count = 0;
/*
* temporary storage for index values
*/
- /*
- * eocCBATCardMACCNUIsolationIndex(1)/INTEGER/ASN_INTEGER/long(long)//l/A/w/e/r/d/h
- */
- /* this index is always 0 */
- long eocCBATCardMACCNUIsolationIndex = 0;
+ /*
+ * eocCBATCardMACCNUIsolationIndex(1)/INTEGER32/ASN_INTEGER/long(long)//l/A/w/e/r/d/h
+ */
+ long eocCBATCardMACCNUIsolationIndex;
- u_long eocCBATCardMACCNUIsolationEN = 0;
- char buffer[LIBSPID_CONFIG_KEY_MAX_LEN];
- int ret;
- DEBUGMSGTL (("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationTable_container_load", "called\n"));
+ DEBUGMSGTL(("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationTable_container_load","called\n"));
/*
* TODO:351:M: |-> Load/update data in the eocCBATCardMACCNUIsolationTable container.
@@ -212,93 +208,54 @@ eocCBATCardMACCNUIsolationTable_container_load (netsnmp_container * container)
* set the index(es) [and data, optionally] and insert into
* the container.
*/
- /* no need for a loop because index is always 1, so there is only one row in a table */
-
- /*
- * TODO:352:M: | |-> set indexes in new eocCBATCardMACCNUIsolationTable
- * rowreq context.
- * data context will be set from the param (unless NULL,
- * in which case a new data context will be allocated)
- */
- rowreq_ctx = eocCBATCardMACCNUIsolationTable_allocate_rowreq_ctx (NULL);
- if (NULL == rowreq_ctx)
- {
- snmp_log (LOG_ERR, "memory allocation failed\n");
- return MFD_RESOURCE_UNAVAILABLE;
- }
- if (MFD_SUCCESS !=
- eocCBATCardMACCNUIsolationTable_indexes_set (rowreq_ctx,
- eocCBATCardMACCNUIsolationIndex))
- {
- snmp_log (LOG_ERR, "error setting index while loading "
- "eocCBATCardMACCNUIsolationTable data.\n");
- eocCBATCardMACCNUIsolationTable_release_rowreq_ctx (rowreq_ctx);
- return MFD_RESOURCE_UNAVAILABLE;
- }
+ while( 1 ) {
+ /*
+ * check for end of data; bail out if there is no more data
+ */
+ if( 1 )
+ break;
+
+ /*
+ * TODO:352:M: | |-> set indexes in new eocCBATCardMACCNUIsolationTable rowreq context.
+ * data context will be set from the param (unless NULL,
+ * in which case a new data context will be allocated)
+ */
+ rowreq_ctx = eocCBATCardMACCNUIsolationTable_allocate_rowreq_ctx(NULL);
+ if (NULL == rowreq_ctx) {
+ snmp_log(LOG_ERR, "memory allocation failed\n");
+ return MFD_RESOURCE_UNAVAILABLE;
+ }
+ if(MFD_SUCCESS != eocCBATCardMACCNUIsolationTable_indexes_set(rowreq_ctx
+ , eocCBATCardMACCNUIsolationIndex
+ )) {
+ snmp_log(LOG_ERR,"error setting index while loading "
+ "eocCBATCardMACCNUIsolationTable data.\n");
+ eocCBATCardMACCNUIsolationTable_release_rowreq_ctx(rowreq_ctx);
+ continue;
+ }
- /*
- * TODO:352:r: | |-> populate eocCBATCardMACCNUIsolationTable data context.
- * Populate data context here. (optionally, delay until row prep)
- */
+ /*
+ * TODO:352:r: | |-> populate eocCBATCardMACCNUIsolationTable data context.
+ * Populate data context here. (optionally, delay until row prep)
+ */
/*
* TRANSIENT or semi-TRANSIENT data:
* copy data or save any info needed to do it in row_prep.
*/
/*
* setup/save data for eocCBATCardMACCNUIsolationEN
- * eocCBATCardMACCNUIsolationEN(2)/TruthValue/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h
+ * eocCBATCardMACCNUIsolationEN(2)/INTEGER/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h
*/
- /*
- * TODO:246:r: |-> Define eocCBATCardMACCNUIsolationEN mapping.
- * Map values between raw/native values and MIB values
- *
- * enums usually need mapping.
- */
- /* read buffer for CNU Isolation Enable from conf file */
- ret = libspid_config_read_item (LIBSPID_MASTER_CONF_PATH,
- LIBSPID_MASTER_CONF_LABEL_ISOLATION_ENABLE,
- buffer, LIBSPID_CONFIG_KEY_MAX_LEN);
- if (LIBSPID_SUCCESS != ret)
- {
- snmp_log (LOG_ERR, "libspid_config_read_item error\n");
- /* CNU Isolation Enable set to disabled to permit walk requests */
- eocCBATCardMACCNUIsolationEN =
- INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_FALSE;
- }
- else
- {
- /* parse CNU Isolation Enable from buffer */
- if (!strncmp (buffer, LIBSPID_MASTER_CONF_VALUE_YES,
- strlen (LIBSPID_MASTER_CONF_VALUE_YES)))
- {
- eocCBATCardMACCNUIsolationEN =
- INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_TRUE;
- }
- else if (!strncmp (buffer, LIBSPID_MASTER_CONF_VALUE_NO,
- strlen (LIBSPID_MASTER_CONF_VALUE_NO)))
- {
- eocCBATCardMACCNUIsolationEN =
- INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_FALSE;
- }
- else
- {
- eocCBATCardMACCNUIsolationEN = INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_FALSE; /* disabled CNU isolation is presumed as default */
- }
- }
- if (MFD_SUCCESS !=
- eocCBATCardMACCNUIsolationEN_map (&rowreq_ctx->
- data.eocCBATCardMACCNUIsolationEN,
- eocCBATCardMACCNUIsolationEN))
- {
- return MFD_ERROR;
- }
+ /** no mapping */
+ rowreq_ctx->data.eocCBATCardMACCNUIsolationEN = eocCBATCardMACCNUIsolationEN;
- /*
- * insert into table container
- */
- CONTAINER_INSERT (container, rowreq_ctx);
- ++count;
+ /*
+ * insert into table container
+ */
+ CONTAINER_INSERT(container, rowreq_ctx);
+ ++count;
+ }
DEBUGMSGT(("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationTable_container_load",
"inserted %d records\n", count));
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.c b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.c
index 52dbb791fc..9a95548d87 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.c
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.c
@@ -1,6 +1,6 @@
/*
* Note: this file originally auto-generated by mib2c using
- * version : 12088 $ of $
+ * version : 12088 $ of $
*
* $Id:$
*/
@@ -61,9 +61,9 @@ eocCBATCardMACCNUIsolationTable_indexes_set_tbl_idx(eocCBATCardMACCNUIsolationTa
{
DEBUGMSGTL(("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationTable_indexes_set_tbl_idx","called\n"));
- /* eocCBATCardMACCNUIsolationIndex(1)/INTEGER/ASN_INTEGER/long(long)//l/A/w/e/r/d/h */
+ /* eocCBATCardMACCNUIsolationIndex(1)/INTEGER32/ASN_INTEGER/long(long)//l/A/w/e/r/d/h */
tbl_idx->eocCBATCardMACCNUIsolationIndex = eocCBATCardMACCNUIsolationIndex_val;
-
+
return MFD_SUCCESS;
} /* eocCBATCardMACCNUIsolationTable_indexes_set_tbl_idx */
@@ -110,65 +110,19 @@ eocCBATCardMACCNUIsolationTable_indexes_set(eocCBATCardMACCNUIsolationTable_rowr
* Its status is Current, and its access level is ReadWrite.
* OID: .1.3.6.1.4.1.17409.2.4.3.1.1.2
* Description:
-CBAT板卡MAC层CNU隔离管理开关。1-表示隔离,0-表示不隔离
+
*
* Attributes:
* accessible 1 isscalar 0 enums 1 hasdefval 0
* readable 1 iscolumn 1 ranges 0 hashint 0
* settable 1
*
- * Enum range: 2/8. Values: true(1), false(2)
+ * Enum range: 2/8. Values: disable(0), enable(1)
*
- * Its syntax is TruthValue (based on perltype INTEGER)
+ * Its syntax is INTEGER (based on perltype INTEGER)
* The net-snmp type is ASN_INTEGER. The C type decl is long (u_long)
*/
/**
- * map a value from its original native format to the MIB format.
- *
- * @retval MFD_SUCCESS : success
- * @retval MFD_ERROR : Any other error
- *
- * @note parameters follow the memset convention (dest, src).
- *
- * @note generation and use of this function can be turned off by re-running
- * mib2c after adding the following line to the file
- * defaults/node-eocCBATCardMACCNUIsolationEN.m2d :
- * @eval $m2c_node_skip_mapping = 1@
- *
- * @remark
- * If the values for your data type don't exactly match the
- * possible values defined by the mib, you should map them here.
- * Otherwise, just do a direct copy.
- */
-int
-eocCBATCardMACCNUIsolationEN_map(u_long *mib_eocCBATCardMACCNUIsolationEN_val_ptr, u_long raw_eocCBATCardMACCNUIsolationEN_val)
-{
- netsnmp_assert(NULL != mib_eocCBATCardMACCNUIsolationEN_val_ptr);
-
- DEBUGMSGTL(("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationEN_map","called\n"));
-
- /*
- * TODO:241:o: |-> Implement eocCBATCardMACCNUIsolationEN enum mapping.
- * uses INTERNAL_* macros defined in the header files
- */
- switch(raw_eocCBATCardMACCNUIsolationEN_val) {
- case INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_TRUE:
- *mib_eocCBATCardMACCNUIsolationEN_val_ptr = TRUTHVALUE_TRUE;
- break;
-
- case INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_FALSE:
- *mib_eocCBATCardMACCNUIsolationEN_val_ptr = TRUTHVALUE_FALSE;
- break;
-
- default:
- snmp_log(LOG_ERR, "couldn't map value %ld for eocCBATCardMACCNUIsolationEN\n", raw_eocCBATCardMACCNUIsolationEN_val );
- return MFD_ERROR;
- }
-
- return MFD_SUCCESS;
-} /* eocCBATCardMACCNUIsolationEN_map */
-
-/**
* Extract the current value of the eocCBATCardMACCNUIsolationEN data.
*
* Set a value using the data context for the row.
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.h b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.h
index ba447ef9d6..9a91c7ba3f 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.h
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_get.h
@@ -41,9 +41,7 @@ extern "C" {
/*
* indexes
*/
- int eocCBATCardMACCNUIsolationIndex_map(long *mib_eocCBATCardMACCNUIsolationIndex_val_ptr, long raw_eocCBATCardMACCNUIsolationIndex_val);
- int eocCBATCardMACCNUIsolationEN_map(u_long *mib_eocCBATCardMACCNUIsolationEN_val_ptr, u_long raw_eocCBATCardMACCNUIsolationEN_val);
int eocCBATCardMACCNUIsolationEN_get( eocCBATCardMACCNUIsolationTable_rowreq_ctx *rowreq_ctx, u_long * eocCBATCardMACCNUIsolationEN_val_ptr );
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_set.c b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_set.c
index 4eec0f374c..449b73fd4f 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_set.c
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_data_set.c
@@ -240,12 +240,12 @@ int
eocCBATCardMACCNUIsolationTable_commit( eocCBATCardMACCNUIsolationTable_rowreq_ctx *rowreq_ctx)
{
int rc = MFD_SUCCESS;
- int save_flags;
+ int save_flags;
- DEBUGMSGTL (("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationTable_commit", "called\n"));
+ DEBUGMSGTL(("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationTable_commit","called\n"));
/** we should have a non-NULL pointer */
- netsnmp_assert (NULL != rowreq_ctx);
+ netsnmp_assert( NULL != rowreq_ctx );
/*
* save flags, then clear until we actually do something
@@ -260,33 +260,33 @@ eocCBATCardMACCNUIsolationTable_commit( eocCBATCardMACCNUIsolationTable_rowreq_c
* 3) set the column's flag in column_set_flags if it needs undo
* processing in case of a failure.
*/
- if (save_flags & COLUMN_EOCCBATCARDMACCNUISOLATIONEN_FLAG)
- {
- save_flags &= ~COLUMN_EOCCBATCARDMACCNUISOLATIONEN_FLAG; /* clear eocCBATCardMACCNUIsolationEN */
- /*
- * TODO:482:o: |-> commit column eocCBATCardMACCNUIsolationEN.
- */
-
- /*
- * set flag, in case we need to undo eocCBATCardMACCNUIsolationEN
- */
- rowreq_ctx->column_set_flags |=
- COLUMN_EOCCBATCARDMACCNUISOLATIONEN_FLAG;
+ if (save_flags & COLUMN_EOCCBATCARDMACCNUISOLATIONEN_FLAG) {
+ save_flags &= ~COLUMN_EOCCBATCARDMACCNUISOLATIONEN_FLAG; /* clear eocCBATCardMACCNUIsolationEN */
+ /*
+ * TODO:482:o: |-> commit column eocCBATCardMACCNUIsolationEN.
+ */
+ rc = -1;
+ if(-1 == rc) {
+ snmp_log(LOG_ERR,"eocCBATCardMACCNUIsolationTable column eocCBATCardMACCNUIsolationEN commit failed\n");
+ }
+ else {
+ /*
+ * set flag, in case we need to undo eocCBATCardMACCNUIsolationEN
+ */
+ rowreq_ctx->column_set_flags |= COLUMN_EOCCBATCARDMACCNUISOLATIONEN_FLAG;
+ }
}
/*
* if we successfully commited this row, set the dirty flag.
*/
- if (MFD_SUCCESS == rc)
- {
+ if (MFD_SUCCESS == rc) {
rowreq_ctx->rowreq_flags |= MFD_ROW_DIRTY;
}
- if (save_flags)
- {
- snmp_log (LOG_ERR, "unhandled columns (0x%x) in commit\n",
- save_flags);
- return MFD_ERROR;
+ if (save_flags) {
+ snmp_log(LOG_ERR, "unhandled columns (0x%x) in commit\n", save_flags);
+ return MFD_ERROR;
}
return rc;
@@ -348,16 +348,16 @@ eocCBATCardMACCNUIsolationTable_undo_commit( eocCBATCardMACCNUIsolationTable_row
* Its status is Current, and its access level is ReadWrite.
* OID: .1.3.6.1.4.1.17409.2.4.3.1.1.2
* Description:
-CBAT板卡MAC层CNU隔离管理开关。1-表示隔离,0-表示不隔离
+
*
* Attributes:
* accessible 1 isscalar 0 enums 1 hasdefval 0
* readable 1 iscolumn 1 ranges 0 hashint 0
* settable 1
*
- * Enum range: 2/8. Values: true(1), false(2)
+ * Enum range: 2/8. Values: disable(0), enable(1)
*
- * Its syntax is TruthValue (based on perltype INTEGER)
+ * Its syntax is INTEGER (based on perltype INTEGER)
* The net-snmp type is ASN_INTEGER. The C type decl is long (u_long)
*/
/**
@@ -393,7 +393,7 @@ CBAT板卡MAC层CNU隔离管理开关。1-表示隔离,0-表示不隔离
*
* The following checks have already been done for you:
* The syntax is ASN_INTEGER
- * The value is one of true(1), false(2)
+ * The value is one of disable(0), enable(1)
*
* If there a no other checks you need to do, simply return MFD_SUCCESS.
*
@@ -471,69 +471,11 @@ eocCBATCardMACCNUIsolationEN_set( eocCBATCardMACCNUIsolationTable_rowreq_ctx *ro
/** should never get a NULL pointer */
netsnmp_assert(NULL != rowreq_ctx);
-/*
- * TODO:245:o: |-> Implement eocCBATCardMACCNUIsolationEN reverse mapping.
- * If the values for your data type don't exactly match the
- * possible values defined by the mib, you should map them here.
- */
/*
- ***************************************************
- *** START EXAMPLE CODE ***
- ***---------------------------------------------***/
- switch (eocCBATCardMACCNUIsolationEN_val)
- {
- case TRUTHVALUE_TRUE:
-
- if (LIBSPID_SUCCESS !=
- libspid_config_write_item (LIBSPID_MASTER_CONF_PATH,
- LIBSPID_MASTER_CONF_LABEL_ISOLATION_ENABLE,
- LIBSPID_MASTER_CONF_VALUE_YES))
- {
- snmp_log (LOG_ERR, "libspid_config_write_item error\n");
- return SNMP_ERR_COMMITFAILED;
- }
- /* save configuration file to flash */
- if (LIBSPID_SUCCESS !=
- libspid_system_save_file (LIBSPID_MASTER_CONF_PATH))
- {
- snmp_log (LOG_ERR, "libspid_system_save_file error\n");
- return SNMP_ERR_COMMITFAILED;
- }
- rowreq_ctx->data.eocCBATCardMACCNUIsolationEN =
- INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_TRUE;
- break;
-
- case TRUTHVALUE_FALSE:
- if (LIBSPID_SUCCESS !=
- libspid_config_write_item (LIBSPID_MASTER_CONF_PATH,
- LIBSPID_MASTER_CONF_LABEL_ISOLATION_ENABLE,
- LIBSPID_MASTER_CONF_VALUE_NO))
- {
- snmp_log (LOG_ERR, "libspid_config_write_item error\n");
- return SNMP_ERR_COMMITFAILED;
- }
- /* save configuration file to flash */
- if (LIBSPID_SUCCESS !=
- libspid_system_save_file (LIBSPID_MASTER_CONF_PATH))
- {
- snmp_log (LOG_ERR, "libspid_system_save_file error\n");
- return SNMP_ERR_COMMITFAILED;
- }
- rowreq_ctx->data.eocCBATCardMACCNUIsolationEN =
- INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_FALSE;
- break;
-
- default:
- snmp_log (LOG_ERR,
- "couldn't reverse map value %ld for "
- "eocCBATCardMACCNUIsolationEN\n",
- eocCBATCardMACCNUIsolationEN_val);
- return SNMP_ERR_GENERR;
- }
- /*
- ***---------------------------------------------***
- *** END EXAMPLE CODE ***
- ***************************************************/
+ * TODO:461:M: |-> Set eocCBATCardMACCNUIsolationEN value.
+ * set eocCBATCardMACCNUIsolationEN value in rowreq_ctx->data
+ */
+ rowreq_ctx->data.eocCBATCardMACCNUIsolationEN = eocCBATCardMACCNUIsolationEN_val;
return MFD_SUCCESS;
} /* eocCBATCardMACCNUIsolationEN_set */
@@ -545,74 +487,21 @@ eocCBATCardMACCNUIsolationEN_set( eocCBATCardMACCNUIsolationTable_rowreq_ctx *ro
* Pointer to the users context.
*/
int
-eocCBATCardMACCNUIsolationEN_undo (eocCBATCardMACCNUIsolationTable_rowreq_ctx
- * rowreq_ctx)
+eocCBATCardMACCNUIsolationEN_undo( eocCBATCardMACCNUIsolationTable_rowreq_ctx *rowreq_ctx)
{
- DEBUGMSGTL (("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationEN_undo", "called\n"));
+ DEBUGMSGTL(("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationEN_undo","called\n"));
- netsnmp_assert (NULL != rowreq_ctx);
+ netsnmp_assert(NULL != rowreq_ctx);
/*
* TODO:456:o: |-> Clean up eocCBATCardMACCNUIsolationEN undo.
*/
- switch (rowreq_ctx->undo->eocCBATCardMACCNUIsolationEN)
- {
- case INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_FALSE:
- if (LIBSPID_SUCCESS !=
- libspid_config_write_item (LIBSPID_MASTER_CONF_PATH,
- LIBSPID_MASTER_CONF_LABEL_ISOLATION_ENABLE,
- LIBSPID_MASTER_CONF_VALUE_NO))
- {
- snmp_log (LOG_ERR, "libspid_config_write_item error\n");
-
- return SNMP_ERR_UNDOFAILED;
- }
- /* save configuration file to flash */
- if (LIBSPID_SUCCESS !=
- libspid_system_save_file (LIBSPID_MASTER_CONF_PATH))
- {
- snmp_log (LOG_ERR, "libspid_system_save_file error\n");
-
- return SNMP_ERR_COMMITFAILED;
- }
-
- break;
-
- case INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_TRUE:
- if (LIBSPID_SUCCESS !=
- libspid_config_write_item (LIBSPID_MASTER_CONF_PATH,
- LIBSPID_MASTER_CONF_LABEL_ISOLATION_ENABLE,
- LIBSPID_MASTER_CONF_VALUE_YES))
- {
- snmp_log (LOG_ERR, "libspid_config_write_item error\n");
-
- return SNMP_ERR_UNDOFAILED;
- }
- /* save configuration file to flash */
- if (LIBSPID_SUCCESS !=
- libspid_system_save_file (LIBSPID_MASTER_CONF_PATH))
- {
- snmp_log (LOG_ERR, "libspid_system_save_file error\n");
-
- return SNMP_ERR_COMMITFAILED;
- }
-
- break;
-
- default:
- snmp_log (LOG_ERR,
- "couldn't reverse map value %ld for "
- "undone modEoCCLTMACCNUIsolationEN\n",
- rowreq_ctx->undo->eocCBATCardMACCNUIsolationEN);
- return SNMP_ERR_GENERR;
- }
/*
* copy eocCBATCardMACCNUIsolationEN data
* set rowreq_ctx->data.eocCBATCardMACCNUIsolationEN from rowreq_ctx->undo->eocCBATCardMACCNUIsolationEN
*/
- rowreq_ctx->data.eocCBATCardMACCNUIsolationEN =
- rowreq_ctx->undo->eocCBATCardMACCNUIsolationEN;
+ rowreq_ctx->data.eocCBATCardMACCNUIsolationEN = rowreq_ctx->undo->eocCBATCardMACCNUIsolationEN;
return MFD_SUCCESS;
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_enums.h b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_enums.h
index 1a0c8ed3a4..296ab671f4 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_enums.h
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_enums.h
@@ -33,25 +33,18 @@ extern "C" {
/*************************************************************
* constants for enums for the MIB node
- * eocCBATCardMACCNUIsolationEN (TruthValue / ASN_INTEGER)
+ * eocCBATCardMACCNUIsolationEN (INTEGER / ASN_INTEGER)
*
* since a Textual Convention may be referenced more than once in a
* MIB, protect againt redefinitions of the enum values.
*/
-#ifndef TRUTHVALUE_ENUMS
-#define TRUTHVALUE_ENUMS
+#ifndef EOCCBATCARDMACCNUISOLATIONEN_ENUMS
+#define EOCCBATCARDMACCNUISOLATIONEN_ENUMS
-#define TRUTHVALUE_TRUE 1
-#define TRUTHVALUE_FALSE 2
+#define EOCCBATCARDMACCNUISOLATIONEN_DISABLE 0
+#define EOCCBATCARDMACCNUISOLATIONEN_ENABLE 1
-#endif /* TRUTHVALUE_ENUMS */
-
- /*
- * TODO:140:o: Define your interal representation of eocCBATCardMACCNUIsolationEN enums.
- * (used for value mapping; see notes at top of file)
- */
-#define INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_TRUE 1
-#define INTERNAL_EOCCBATCARDMACCNUISOLATIONTABLE_EOCCBATCARDMACCNUISOLATIONEN_FALSE 2
+#endif /* EOCCBATCARDMACCNUISOLATIONEN_ENUMS */
diff --git a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_interface.c b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_interface.c
index e3a752bdda..5796abd87d 100644
--- a/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_interface.c
+++ b/cleopatre/application/spidnetsnmp/agent/mibgroup/mstar-eoc-mib/eocCBATCardMACGroup/eocCBATCardMACCNUIsolationTable/eocCBATCardMACCNUIsolationTable_interface.c
@@ -1,6 +1,6 @@
/*
* Note: this file originally auto-generated by mib2c using
- * version : 15899 $ of $
+ * version : 15899 $ of $
*
* $Id:$
*/
@@ -60,7 +60,7 @@ typedef struct eocCBATCardMACCNUIsolationTable_interface_ctx_s {
netsnmp_cache *cache;
eocCBATCardMACCNUIsolationTable_registration * user_ctx;
-
+
netsnmp_table_registration_info tbl_info;
netsnmp_baby_steps_access_methods access_multiplexer;
@@ -141,7 +141,7 @@ eocCBATCardMACCNUIsolationTable_data *eocCBATCardMACCNUIsolationTable_allocate_d
/**
* @internal
- * Initialize the table eocCBATCardMACCNUIsolationTable
+ * Initialize the table eocCBATCardMACCNUIsolationTable
* (Define its contents and how it's structured)
*/
void
@@ -191,7 +191,7 @@ _eocCBATCardMACCNUIsolationTable_initialize_interface(eocCBATCardMACCNUIsolation
snmp_log(LOG_ERR,"could not initialize container for eocCBATCardMACCNUIsolationTable\n");
return;
}
-
+
/*
* access_multiplexer: REQUIRED wrapper for get request handling
*/
@@ -226,7 +226,7 @@ _eocCBATCardMACCNUIsolationTable_initialize_interface(eocCBATCardMACCNUIsolation
* Create a registration, save our reg data, register table.
*/
DEBUGMSGTL(("eocCBATCardMACCNUIsolationTable:init_eocCBATCardMACCNUIsolationTable",
- "Registering eocCBATCardMACCNUIsolationTable as a mibs-for-dummies table.\n"));
+ "Registering eocCBATCardMACCNUIsolationTable as a mibs-for-dummies table.\n"));
handler = netsnmp_baby_steps_access_multiplexer_get(access_multiplexer);
reginfo = netsnmp_handler_registration_create("eocCBATCardMACCNUIsolationTable", handler,
eocCBATCardMACCNUIsolationTable_oid,
@@ -257,14 +257,14 @@ _eocCBATCardMACCNUIsolationTable_initialize_interface(eocCBATCardMACCNUIsolation
mfd_modes |= BABY_STEP_PRE_REQUEST;
if( access_multiplexer->post_request )
mfd_modes |= BABY_STEP_POST_REQUEST;
-
+
if( access_multiplexer->undo_setup )
mfd_modes |= BABY_STEP_UNDO_SETUP;
if( access_multiplexer->undo_cleanup )
mfd_modes |= BABY_STEP_UNDO_CLEANUP;
if( access_multiplexer->undo_sets )
mfd_modes |= BABY_STEP_UNDO_SETS;
-
+
if( access_multiplexer->row_creation )
mfd_modes |= BABY_STEP_ROW_CREATE;
if( access_multiplexer->consistency_checks )
@@ -273,7 +273,7 @@ _eocCBATCardMACCNUIsolationTable_initialize_interface(eocCBATCardMACCNUIsolation
mfd_modes |= BABY_STEP_COMMIT;
if( access_multiplexer->undo_commit )
mfd_modes |= BABY_STEP_UNDO_COMMIT;
-
+
handler = netsnmp_baby_steps_handler_get(mfd_modes);
netsnmp_inject_handler(reginfo, handler);
@@ -338,12 +338,12 @@ eocCBATCardMACCNUIsolationTable_index_to_oid(netsnmp_index *oid_idx,
eocCBATCardMACCNUIsolationTable_mib_index *mib_idx)
{
int err = SNMP_ERR_NOERROR;
-
+
/*
* temp storage for parsing indexes
*/
/*
- * eocCBATCardMACCNUIsolationIndex(1)/INTEGER/ASN_INTEGER/long(long)//l/A/w/e/r/d/h
+ * eocCBATCardMACCNUIsolationIndex(1)/INTEGER32/ASN_INTEGER/long(long)//l/A/w/e/r/d/h
*/
netsnmp_variable_list var_eocCBATCardMACCNUIsolationIndex;
@@ -361,7 +361,7 @@ eocCBATCardMACCNUIsolationTable_index_to_oid(netsnmp_index *oid_idx,
DEBUGMSGTL(("verbose:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationTable_index_to_oid","called\n"));
- /* eocCBATCardMACCNUIsolationIndex(1)/INTEGER/ASN_INTEGER/long(long)//l/A/w/e/r/d/h */
+ /* eocCBATCardMACCNUIsolationIndex(1)/INTEGER32/ASN_INTEGER/long(long)//l/A/w/e/r/d/h */
snmp_set_var_value(&var_eocCBATCardMACCNUIsolationIndex, (u_char*)&mib_idx->eocCBATCardMACCNUIsolationIndex,
sizeof(mib_idx->eocCBATCardMACCNUIsolationIndex));
@@ -390,12 +390,12 @@ eocCBATCardMACCNUIsolationTable_index_from_oid(netsnmp_index *oid_idx,
eocCBATCardMACCNUIsolationTable_mib_index *mib_idx)
{
int err = SNMP_ERR_NOERROR;
-
+
/*
* temp storage for parsing indexes
*/
/*
- * eocCBATCardMACCNUIsolationIndex(1)/INTEGER/ASN_INTEGER/long(long)//l/A/w/e/r/d/h
+ * eocCBATCardMACCNUIsolationIndex(1)/INTEGER32/ASN_INTEGER/long(long)//l/A/w/e/r/d/h
*/
netsnmp_variable_list var_eocCBATCardMACCNUIsolationIndex;
@@ -515,12 +515,12 @@ eocCBATCardMACCNUIsolationTable_release_rowreq_ctx(eocCBATCardMACCNUIsolationTab
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:eocCBATCardMACCNUIsolationTable_release_rowreq_ctx","called\n"));
netsnmp_assert(NULL != rowreq_ctx);
-
+
eocCBATCardMACCNUIsolationTable_rowreq_ctx_cleanup(rowreq_ctx);
if(rowreq_ctx->undo)
eocCBATCardMACCNUIsolationTable_release_data(rowreq_ctx->undo);
-
+
/*
* free index oid pointer
*/
@@ -544,13 +544,13 @@ _mfd_eocCBATCardMACCNUIsolationTable_pre_request(netsnmp_mib_handler *handler,
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_pre_request",
"called\n"));
-
+
if (1 != netsnmp_row_merge_status_first(reginfo, agtreq_info)) {
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable",
"skipping additional pre_request\n"));
return SNMP_ERR_NOERROR;
}
-
+
rc = eocCBATCardMACCNUIsolationTable_pre_request(eocCBATCardMACCNUIsolationTable_if_ctx.user_ctx);
if (MFD_SUCCESS != rc) {
/*
@@ -560,7 +560,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_pre_request(netsnmp_mib_handler *handler,
"eocCBATCardMACCNUIsolationTable_pre_request\n", rc));
netsnmp_request_set_error_all(requests, SNMP_VALIDATE_ERR(rc));
}
-
+
return SNMP_ERR_NOERROR;
} /* _mfd_eocCBATCardMACCNUIsolationTable_pre_request */
@@ -595,7 +595,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_post_request(netsnmp_mib_handler *handler,
"waiting for last post_request\n"));
return SNMP_ERR_NOERROR;
}
-
+
packet_rc = netsnmp_check_all_requests_error(agtreq_info->asp, 0);
if ((MFD_SUCCESS != packet_rc) && eocCBATCardMACCNUIsolationTable_dirty_get()) {
/*
@@ -614,7 +614,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_post_request(netsnmp_mib_handler *handler,
DEBUGMSGTL(("eocCBATCardMACCNUIsolationTable","error %d from "
"eocCBATCardMACCNUIsolationTable_post_request\n", rc));
}
-
+
return SNMP_ERR_NOERROR;
} /* _mfd_eocCBATCardMACCNUIsolationTable_post_request */
@@ -631,7 +631,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_object_lookup(netsnmp_mib_handler *handler,
int rc = SNMP_ERR_NOERROR;
eocCBATCardMACCNUIsolationTable_rowreq_ctx *rowreq_ctx =
netsnmp_container_table_row_extract(requests);
-
+
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_object_lookup","called\n"));
/*
@@ -666,7 +666,7 @@ _eocCBATCardMACCNUIsolationTable_get_column( eocCBATCardMACCNUIsolationTable_row
netsnmp_variable_list *var, int column )
{
int rc = SNMPERR_SUCCESS;
-
+
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_get_column",
"called for %d\n", column));
@@ -675,14 +675,14 @@ _eocCBATCardMACCNUIsolationTable_get_column( eocCBATCardMACCNUIsolationTable_row
switch(column) {
- /* (INDEX) eocCBATCardMACCNUIsolationIndex(1)/INTEGER/ASN_INTEGER/long(long)//l/A/w/e/r/d/h */
+ /* (INDEX) eocCBATCardMACCNUIsolationIndex(1)/INTEGER32/ASN_INTEGER/long(long)//l/A/w/e/r/d/h */
case COLUMN_EOCCBATCARDMACCNUISOLATIONINDEX:
var->type = ASN_INTEGER;
var->val_len = sizeof(long);
(*var->val.integer) = rowreq_ctx->tbl_idx.eocCBATCardMACCNUIsolationIndex;
break;
- /* eocCBATCardMACCNUIsolationEN(2)/TruthValue/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
+ /* eocCBATCardMACCNUIsolationEN(2)/INTEGER/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
case COLUMN_EOCCBATCARDMACCNUISOLATIONEN:
var->val_len = sizeof(u_long);
var->type = ASN_INTEGER;
@@ -720,7 +720,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_get_values(netsnmp_mib_handler *handler,
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_get_values","called\n"));
netsnmp_assert(NULL != rowreq_ctx);
-
+
for(;requests; requests = requests->next) {
/*
* save old pointer, so we can free it if replaced
@@ -742,7 +742,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_get_values(netsnmp_mib_handler *handler,
tri = netsnmp_extract_table_info(requests);
if(NULL == tri)
continue;
-
+
rc = _eocCBATCardMACCNUIsolationTable_get_column(rowreq_ctx, requests->requestvb, tri->colnum);
if(rc) {
if(MFD_SKIP == rc) {
@@ -795,26 +795,26 @@ _eocCBATCardMACCNUIsolationTable_check_column( eocCBATCardMACCNUIsolationTable_r
netsnmp_variable_list *var, int column )
{
int rc = SNMPERR_SUCCESS;
-
+
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_eocCBATCardMACCNUIsolationTable_check_column",
"called for %d\n", column));
netsnmp_assert(NULL != rowreq_ctx);
switch(column) {
- /* (INDEX) eocCBATCardMACCNUIsolationIndex(1)/INTEGER/ASN_INTEGER/long(long)//l/A/w/e/r/d/h */
+ /* (INDEX) eocCBATCardMACCNUIsolationIndex(1)/INTEGER32/ASN_INTEGER/long(long)//l/A/w/e/r/d/h */
case COLUMN_EOCCBATCARDMACCNUISOLATIONINDEX:
rc = SNMP_ERR_NOTWRITABLE; /* can not change index of active row */
break;
- /* eocCBATCardMACCNUIsolationEN(2)/TruthValue/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
+ /* eocCBATCardMACCNUIsolationEN(2)/INTEGER/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
case COLUMN_EOCCBATCARDMACCNUISOLATIONEN:
rc = netsnmp_check_vb_type_and_size( var, ASN_INTEGER,
sizeof( rowreq_ctx->data.eocCBATCardMACCNUIsolationEN ) );
/* check that the value is one of defined enums */
if( (SNMPERR_SUCCESS == rc)
- && ( *var->val.integer != TRUTHVALUE_TRUE )
- && ( *var->val.integer != TRUTHVALUE_FALSE )
+ && ( *var->val.integer != EOCCBATCARDMACCNUISOLATIONEN_DISABLE )
+ && ( *var->val.integer != EOCCBATCARDMACCNUISOLATIONEN_ENABLE )
) {
rc = SNMP_ERR_WRONGVALUE;
}
@@ -854,7 +854,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_check_objects(netsnmp_mib_handler *handler,
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_check_objects","called\n"));
netsnmp_assert(NULL != rowreq_ctx);
-
+
for(;requests; requests = requests->next) {
/*
@@ -889,7 +889,7 @@ NETSNMP_STATIC_INLINE int
_eocCBATCardMACCNUIsolationTable_undo_setup_column( eocCBATCardMACCNUIsolationTable_rowreq_ctx *rowreq_ctx, int column )
{
int rc = SNMPERR_SUCCESS;
-
+
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_eocCBATCardMACCNUIsolationTable_undo_setup_column",
"called for %d\n", column));
@@ -897,7 +897,7 @@ _eocCBATCardMACCNUIsolationTable_undo_setup_column( eocCBATCardMACCNUIsolationTa
switch(column) {
- /* eocCBATCardMACCNUIsolationEN(2)/TruthValue/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
+ /* eocCBATCardMACCNUIsolationEN(2)/INTEGER/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
case COLUMN_EOCCBATCARDMACCNUISOLATIONEN:
rowreq_ctx->column_set_flags |= COLUMN_EOCCBATCARDMACCNUISOLATIONEN_FLAG;
rc = eocCBATCardMACCNUIsolationEN_undo_setup(rowreq_ctx );
@@ -962,7 +962,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_undo_setup(netsnmp_mib_handler *handler,
tri = netsnmp_extract_table_info(requests);
if(NULL == tri)
continue;
-
+
rc = _eocCBATCardMACCNUIsolationTable_undo_setup_column(rowreq_ctx, tri->colnum);
if(MFD_SUCCESS != rc) {
DEBUGMSGTL(("eocCBATCardMACCNUIsolationTable:mfd","error %d from "
@@ -971,7 +971,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_undo_setup(netsnmp_mib_handler *handler,
}
} /* for results */
}
-
+
return SNMP_ERR_NOERROR;
} /* _mfd_eocCBATCardMACCNUIsolationTable_undo_setup */
@@ -1035,7 +1035,7 @@ _eocCBATCardMACCNUIsolationTable_set_column( eocCBATCardMACCNUIsolationTable_row
netsnmp_variable_list *var, int column )
{
int rc = SNMPERR_SUCCESS;
-
+
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_eocCBATCardMACCNUIsolationTable_set_column",
"called for %d\n", column));
@@ -1043,7 +1043,7 @@ _eocCBATCardMACCNUIsolationTable_set_column( eocCBATCardMACCNUIsolationTable_row
switch(column) {
- /* eocCBATCardMACCNUIsolationEN(2)/TruthValue/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
+ /* eocCBATCardMACCNUIsolationEN(2)/INTEGER/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
case COLUMN_EOCCBATCARDMACCNUISOLATIONEN:
rowreq_ctx->column_set_flags |= COLUMN_EOCCBATCARDMACCNUISOLATIONEN_FLAG;
rc = eocCBATCardMACCNUIsolationEN_set(rowreq_ctx, *((u_long *)var->val.string) );
@@ -1054,7 +1054,7 @@ _eocCBATCardMACCNUIsolationTable_set_column( eocCBATCardMACCNUIsolationTable_row
rc = SNMP_ERR_GENERR;
break;
}
-
+
return rc;
} /* _eocCBATCardMACCNUIsolationTable_set_column */
@@ -1072,7 +1072,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_set_values(netsnmp_mib_handler *handler,
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_set_values","called\n"));
netsnmp_assert(NULL != rowreq_ctx);
-
+
rowreq_ctx->column_set_flags = 0;
for(;requests; requests = requests->next) {
/*
@@ -1081,7 +1081,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_set_values(netsnmp_mib_handler *handler,
tri = netsnmp_extract_table_info(requests);
if(NULL == tri)
continue;
-
+
rc = _eocCBATCardMACCNUIsolationTable_set_column(rowreq_ctx,
requests->requestvb, tri->colnum);
if(MFD_SUCCESS != rc) {
@@ -1116,7 +1116,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_commit(netsnmp_mib_handler *handler,
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_commit","called\n"));
netsnmp_assert(NULL != rowreq_ctx);
-
+
rc = eocCBATCardMACCNUIsolationTable_commit(rowreq_ctx);
if (MFD_SUCCESS != rc) {
DEBUGMSGTL(("eocCBATCardMACCNUIsolationTable:mfd","error %d from "
@@ -1189,7 +1189,7 @@ _eocCBATCardMACCNUIsolationTable_undo_column( eocCBATCardMACCNUIsolationTable_ro
netsnmp_variable_list *var, int column )
{
int rc = SNMPERR_SUCCESS;
-
+
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_eocCBATCardMACCNUIsolationTable_undo_column",
"called for %d\n", column));
@@ -1197,7 +1197,7 @@ _eocCBATCardMACCNUIsolationTable_undo_column( eocCBATCardMACCNUIsolationTable_ro
switch(column) {
- /* eocCBATCardMACCNUIsolationEN(2)/TruthValue/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
+ /* eocCBATCardMACCNUIsolationEN(2)/INTEGER/ASN_INTEGER/long(u_long)//l/A/W/E/r/d/h */
case COLUMN_EOCCBATCARDMACCNUISOLATIONEN:
rc = eocCBATCardMACCNUIsolationEN_undo(rowreq_ctx);
break;
@@ -1224,7 +1224,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_undo_values(netsnmp_mib_handler *handler,
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_undo_values","called\n"));
netsnmp_assert(NULL != rowreq_ctx);
-
+
rc = eocCBATCardMACCNUIsolationTable_undo(rowreq_ctx);
if (MFD_SUCCESS != rc) {
/*
@@ -1233,7 +1233,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_undo_values(netsnmp_mib_handler *handler,
DEBUGMSGTL(("eocCBATCardMACCNUIsolationTable:mfd","error %d from "
"eocCBATCardMACCNUIsolationTable_undo\n", rc));
}
-
+
for(;requests; requests = requests->next) {
/*
* set column data
@@ -1241,7 +1241,7 @@ _mfd_eocCBATCardMACCNUIsolationTable_undo_values(netsnmp_mib_handler *handler,
tri = netsnmp_extract_table_info(requests);
if(NULL == tri)
continue;
-
+
rc = _eocCBATCardMACCNUIsolationTable_undo_column(rowreq_ctx, requests->requestvb,
tri->colnum);
if (MFD_SUCCESS != rc) {
@@ -1273,11 +1273,11 @@ _mfd_eocCBATCardMACCNUIsolationTable_irreversible_commit(netsnmp_mib_handler *ha
{
eocCBATCardMACCNUIsolationTable_rowreq_ctx *rowreq_ctx =
netsnmp_container_table_row_extract(requests);
-
+
DEBUGMSGTL(("internal:eocCBATCardMACCNUIsolationTable:_mfd_eocCBATCardMACCNUIsolationTable_irreversible:commit","called\n"));
-
+
netsnmp_assert(NULL != rowreq_ctx);
-
+
/*
* check for and handle row creation/deletion
* and update column exist flags...
@@ -1317,7 +1317,7 @@ _cache_load(netsnmp_cache *cache, void *vmagic)
/** should only be called for an invalid or expired cache */
netsnmp_assert((0 == cache->valid) || (1 == cache->expired));
-
+
/*
* call user code
*/
@@ -1375,7 +1375,7 @@ _container_free(netsnmp_container *container)
* call user code
*/
eocCBATCardMACCNUIsolationTable_container_free(container);
-
+
/*
* free all items. inefficient, but easy.
*/