⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ospf_mib_helper_update.c

📁 vxworks下ospf协议栈
💻 C
📖 第 1 页 / 共 5 页
字号:
/* ospf_mib_helper_update.c - helper routines for OSPF Management Interface *//* Copyright 1998-2003 Wind River Systems, Inc. */#include "copyright_wrs.h"/*modification history--------------------05n,17jul03,kc  Fixed SPR#88975 again - the ospf2MapiInitDone bool flag                must be set to FALSE in ospf2Mapi_shutdown() so that                susequent ospf restart will initialize the tOspfMapi                correctly.05m,17jul03,kc  Fixed SPR#88975 - made the ospf2Mapi_shutdown() public.05l,10jun03,mwv SPR#88878 fixed compiler warnings related to (char *) references05k,04jun03,asr Changed memory allocation calls such that OSPF memory gets allocated                from OSPF memory partition but all MAPI memory is allocated from the                system memory05j,02jun03,ram Changed native memory usage to OSPF memory partition05i,30may03,asr Renamed route_proto to route_protocol05h,09may03,kc  Fixed SPR#88389 - modified ospf2Mapi_extLsdb_create() to save                the route protocol ID extracted from the OSPF Link State                Database when processing the ospfExtLsdbCreateReqType in                 ospf2Mapi_request().05g,23may03,asr Changes to make OSPF virtual stack compatible05f,27may03,agi changed semTake() return value check from FALSE to ERROR05k,27may03,kc  Fixed SPR#88309 - modified mApi2Ospf_configGenGroup() to                force the mApi2Ospf_configRedistributeOpts() to read the                IP routing table when the ospfASBdrRtrStatus is TRUE.05j,27may03,kc  Fixed SPR#86625 - modified mApi2Ospf_updateStub() to invoke                ospf_dynamic_send_default_summary_lsa() if stubDefaultCost                has changed or if the stub rowStatus has transition to                notInService or notReady. Modified mApi2Ospf_updateArea()                to handle ospfAreaSummary changes correctly. Modified                mApi2Ospf_createArea() to use the proper stub default cost.05i,22may03,kkz SPR 88613 - correcting area aggregation code to advertise only                when necessary05h,27may03,kc  clean up DIAB compile warnings in ospf2Mapi_request ()05g,26may03,kc  Fixed SPR#87790 - changed mApi facility shutdown and restart                mechanism - Modified mApi2Ospf_configGenGroup() to shutdown                mApi facility before shutting down OSPF. mApi2Ospf_configGenGroup()                must also check if previous mApi shutdown is completed before                restarting OSPF. Changed ospf2Mapi_free_requests() to use                NO_WAIT when acquiring the counting semaphore. Fixed                ospf2Mapi_destroy() to delete the mApi task first before                all other clean up. Modified ospf2Mapi_shutdown() so that                it can be called directly by mApi2Ospf_configGenGroup().                Changed the tOspf2Mapi entry point ospf2MapiReceive() to                bail out if detecting mApi facility needs to be shutdown.                Also removed the ospfShutdownReqType.05f,21may03,mwv SPR 87472 during the ospfLsdbCreate we were not pointing to the                correct data structure when coping the LSA into the MAPI database05e,14may03,agi Changed RWOS semaphores to vxWorks semaphores05d,24mar03,mwv SPR 87053, change the MAPI task priority to 150 from 90.                MIPS 4KC got into a deadlock condition05c,21mar03,kc  Fixed SPR#87023 - increases the stack size allocated for tOspf2Mapi                task from 4K to 8K.05b,25feb03,kc  Fixed SPR#86385 - modified all mApi2Ospf_configXxx() routines to                return proper SNMPv2 error code using OSPF_MIB_ERROR_SET() macro.05a,20feb03,kc  Fixed SPR#86319 - modified mApi2Ospf_updateArea() and                 mApi2Ospf_createArea() to rename the inject_default_route_if_stub_area                 variable for stub area entry to inject_summary_lsa_into_stub_area.04z,20feb03,kc  Fixed SPR#86176 - modified ospf2Mapi_destroy() to set the boolean flag                ospfMapiShutdownInProgress to resolve the race condition between the                 OSPF shutdown and restart (was set in mApi2Ospf_configGenGroup()).04y,18feb03,kc  Fixed SPR#86135 - modified mApi2Ospf_updateArea() to handle stub                metric value changes correctly. Also modified mApi2Ospf_reinitIf()                to skip interface reconfiguration if the interface administrative                status is not enabled.04y,17feb02,ram	SPR 81808 Modified mib functions to use native memory allocation04x,07feb03,kc  Fixed SPR#86144 - modified all ospf2Mapi_xxx_create() routines by                removing the mApi request type parameter from the call to the                ospf_mApi_xxxHelperCreate() routine.04w,20nov02,kc  Modified mApi2Ospf_createIf() to check the interface UP flag using the                sysIfFlags from mib api (instead of invoking the check_if_status()                routine).  SPR 84478, 84485, 8448604v,19nov02,kc  Fixed mApi2Ospf_updateIf() - dynamically bring up the interface if the                interface state is still down when execution reaches the end of the                routine. SPR 84478, 84485, 8448604u,19nov02,mwv Merge TMS code SPR 8428404t,12nov02,kc  Fixed SPR#75884 - ospf2Mapi_nbr_flush() and ospf2Mapi_nbr_delete() need                to invoke ospf_mApi_nbrHelperDeregister() to de-register neighbor from                the attached interface.04s,08oct02,agi  Changed OSPF2MAPI_TASK_PRIORITY from 150 to 90 to avoid                 dead-lock04r,08oct02,agi Fixed compiler warnings04q,21aug02,kc  Modified ospf2Mapi_ifDelete() to invoke the application nvramDelRtn                callback routine with the correct index values.04p,19aug02,kc  Fixed SPR#79496 - Modified ospf2Mapi_area_update() and                ospf2MapiReceive() to convert checksumSum value to host order.04o,06aug02,kc  Fixed mApi2Ospf_deleteAreaAggregate() - moved break statement to                if-statement code block after the ospf_dynamic_destroy_area_range().04n,28jun02,kc  Fixed SPR #78381 - Modified ospf2Mapi_request() to read the summary                option. Modified mApi2Ospf_updateArea() and mApi2Ospf_createArea()                to correctly configure ospf for the summary option.04m,26jun02,kc  Fixed PR#2951 - Modified mApi2Ospf_createIf() to only dynamically                create an interface only if the interface UP flag is set. Also                modified mApi2Ospf_updateIf() to update the interface flag in OSPF.                Fixed up ospf_mApi_findIfIndex() to dynamically destroy the interface                from OSPF if interface is down (was previously done in ospf_sysctl.c:                ospf_sysctl_interfaceFlagChange).04l,06jun02,kc  Obsolete the routine ospf_mApi_flushExtLsas().04k,05jun02,kc  Fixed mApi2Ospf_configGenGroup() so that it is not going to                flush all external lsas when dynamically configure for                database overflow.04j,31may02,kc  Fixed PR #2078 - Modified ospf2Mapi_query_config() to correctly                configured the ospf opaque and redistribution options.04i,25may02,kc  Fixed PR #2700 - Added ospf2Mapi_ifDelete() routine. Added support                for ospfIfDeleteReqType ospf2MapiReqType_t to ospf2Mapi_request().04h,25may02,kc  Fixed PR #2767 - Added ospf_mApi_findIfIndex(), ospf2Mapi_ifChange()                routines. Added support for ospfIfChangeReqType ospf2MapiReqType_t                to ospf2Mapi_request().04g,21may02,kc  Fixed PR #2703 - Modified mApi2Ospf_updateIf() to force the                ospfIfStatus object to notInService (instead of notReady) when                setting the ospfIfAdminStat to disabled.04f,23apr02,kc  Fixed mApi2Ospf_createVirtIf() - set the interface cost for virtual                interface to zero. Removed callout to ospf_dynamic_destroy_virtIf()                in mApi2Ospf_configVirtIf() since ospf_dynamic_destroy_interface()                will now remove the virtual interface instance from the virtual                interface linked list.04e,18apr02,kc  Fixed SPR #74432 - Fixed mApi2Ospf_configGenGroup() to correctly                reconfigure ospf for the ospfASBdrRtrStatus changes.04d,18apr02,kc  Localize ospf2Mapi_destroy(). Fixed memory leak in ospf2Mapi_destroy()                - correctly free up the memory allocated for ospf2MapiRequest_t(),                then delete the "tOspfMapi" task. Added ospfMapiShutdownInProgress                bool flag to hold off ospf2Mapi_proto_register() request from ospf if                previous "tOspfMapi" task shutdown request is still in progress.04c,18apr02,kc  Added ospf2Mapi_nbr_flush() and ospf2Mapi_virtNbr_flush() routines                so that ospf2Mapi_shutdown() can clean up the ospfNbrTable and                ospfVirtNbrTable.04b,18apr02,kc  Fixed PR #2756 - Removed the redundant ospf2Mapi_destroy() in                ospf2Mapi_proto_deregister().04a,17apr02,kc  Added ospfMapiReqProcessed counter to ospf2MapiRequest_t structure                and increment such counter after a request is processed in                ospf2MapiReceive(). Display the value of the counter in                ospf2MapiShow().03z,17apr02,kc  Modified ospf2Mapi_createIf(), ospf2Mapi_updateIf(),                ospf2Mapi_createVirtIf() and ospf2Mapi_updateVirtIf() to ignore                the authentication keys from mib api if the authentication type                is not "none" but the authentication key length is zero.03y,14apr02.kc  Explictly validate given parameters in mApi2Ospf_initAuthKey.                Changed ospf2Mapi_createIf() and ospf2Mapi_createVirtIf() to                explicitly clear all authentication related data structure in ospf                if no authentication is configured. Added the                ospf2MapiFreePoolListInited and ospf2MapiRecvListInited bool flags                to ospf2MapiRequest_t. Reworked ospf2Mapi_free_requests(). Renamed                MAPI_NVM_SET to MAPI_COMMIT_NVM per mibApi.h update.03x,13apr02,kc  Fixed PR #2611 - Modified mApi2Ospf_initAuthKey() to copy the exact                length of the authentication key as specified by ospf rfc                specification. Also explicitly zero out all the allocated memory.03w,13apr02,kc  Use mApiOspfError() to display error message.03v,10apr02,kc  Remerged changes for unnumbered interface support. Modifed                ospf2Mapi_request() and ospfMapiReceive() to support the                wrnOspfIfCreateReqType request type.03u,06apr02,kc  Changed "tOspf2Mapi" task name to "tOspfMapi". Added missing                virtual interface priority configuration in mApi2Ospf_createVirtIf().03t,04apr02,kc  ospfGenGroupUpdateReqType request type no longer include the                ABR status.03s,02apr02,kc  Added ospf2Mapi_destroy() to ospf2Mapi_shutdown() to delete                the ospf2Mapi facility. Modified ospf2Mapi_destroy() to invoke                ospf2Mapi_free_requests(). Removed unnecessary semTake() and                semGive() from ospf2Mapi_lsdb_flush() and ospf2Mapi_extLsdb_flush().03r,25mar02,kc  Added ospf2MapiInitDone boolean flag to check if facility provided                by "tOspf2Mapi" task has been initialized. Modified                ospf2Mapi_proto_deregister() to invoke ospf2Mapi_destroy().03q,24mar02,kc  Modified ospf2Mapi_proto_register() to invoke ospf2Mapi_init() and                to return status code (instead of void). Explicitly initialize                the ospfStartupInvoked and ospfRestartCnt global variables so                that ospf2Mapi_init() doesn't have to do that any more. Modified                mApi2Ospf_configGenGroup() to check return status for ospf_startup().03p,13feb02,kc  Use mApiOspfError() macro to display error.03o,04feb02,kc  Modified ospf2Mapi_request() and ospf2MapiReceive() to retrieve and                process ospf redistribution configuration options.03n,17jan02,kc  Modified mApi2Ospf_configGenGroup() to delay awhile before restarting                ospf.03m,17jan02,kc  Fixed ospf2Mapi_query_config() to configure ospf for the router id if                necessary.03l.16jan02,kc  Added ospf2Mapi_lsdb_create() and ospf2Mapi_extLsdb_create(). Modified                ospf2Mapi_lsdb_update() and ospf2Mapi_extLsdb_update() to drop the                update if instance not found.03k,16jan02,kc  Added support for ospfLsdbCreateReqType,ospfExtLsdbCreateReqType,                wrnOspfLsdbCreateReqType, wrnOspfLocalLsdbCreateReqType and                wrnOspfExtLsdbCreateReqType ospf2MapiReqType_t to ospf2Mapi() in order                to fix the memory leak problem introduced by database update requests.03j,08jan02,kc  Explicitly set the stub_default bit in mApi2Ospf_updateArea if area is                configured as stub. Fixed stub area check in mApi2Ospf_updateStub().03i,07jan02,kc  Fixed semaphore leak in ospf2Mapi_query_config().03h,26dec01,kc  Added missing neighbor priority for ospfNbrUpdateReqType.03g,19dec01,kc  Removed protocol init check from mApi2Ospf_configxxx(). Simplified                ospf2Mapi_proto_register().03f,15dec01,kc  Reworked ospf2Mapi_shutdown(). Added ospf2Mapi_lsdb_flush(),                ospf2Mapi_extLsdb_flush() and ospf2Mapi_free_requests().03e,12dec01,kc  Added ospf2Mapi_bool2AggregateEffectGet() and fixed area aggregation                enum conversion in osfp2Mapi_areaAggregate_create().03d,12dec01,kc  Modified mApi2Ospf_createArea() to use default stub metric value if                area is created as stub but no stub instance defined.03c,11dec01,kc  Fixed ospfAreaCreateReqType in ospf2Mapi_request() to correctly set                the ospfAreaSummary to noAreaSummary(1).03b,10dec01,kc  Obsolete mApi2Ospf_ifReset(). Fixed mApi2Ospf_reinitIf() to                correctly handle interface area id change.03a,07dec01,kc  Fixed byte ordering problems in ospf2Mapi_lsdb_delete() and                ospf2Mapi_extLsdb_delete().02z,06dec01,kc  Changed semTake for semMapiMutex mutex to use timeout (was wait                forever) so that the overrun receive queue can be recovered.02y,06dec01,kc  Modified mApi2Ospf_updateIf() so that it will only reconfigure the                authentication key if it is different.02x,28nov01,kc  Fixed interface's state conversion problems in ospf2Mapi_ifStateGet().02w,28nov01,kc  Implemented dynamic reconfiguration for ospf host interface.02q,28nov01,kc  Changed memory allocation in ospf2Mapi_request() for all link state                database type to be pointer to char (was uchar_t).02p,28nov01,kc  Modified mApi2Ospf_configGenGroup() to bring up the ospf if required.02o,16nov01,kc  Fixed more byte ordering problem for ospf2Mapi_lsdb_update and                ospf2Mapi_extLsdb_create.02n,15nov01,kc  Added mApi2Ospf_ifReset() - must be called before forcing the                interface state machine to bring up the interface.02m,12nov01,kc  Added md5 support to ospfIfCreateReqType and ospfVirtIfCreateReq in                ospf2Mapi_request(). Modified ospf2Mapi_if_create() and                ospf2Mapi_virtIf_create() to handle md5 authentication type.02l,09nov01,kc  Fixed byte ordering problem for ospf2Mapi_lsdb_update and                ospf2Mapi_extLsdb_create.02k,09nov01,kc  Convert ospf interface type enum to mApiOspfIfType_t enum value.02j,09nov01,kc  Added ospfStartupInvoked boolean flag so that ospf2Mapi_query_config()                knows how to handle the (wrn) general group parameters configuration.02i,08nov01,kc  Modified ospf2Mapi_request() to discard opaque-specific updates if                opaque functionality is not supported.02h,08nov01,kc  Fixed ospf2Mapi_query_config() so that MIB API knows when to overwrite                the statically configured (wrn) general group parameters in ospf.02g,29oct01,kc  Added ospf2Mapi_nbrStateGet() and ospf2Mapi_ifStateGet().02f,29oct01,kc  Renamed ospf2Mapi_status2BoolGet() to ospf2Mapi_bool2StatusGet().02e,29oct01,kc  Checked pointer given by ospf in ospf2Mapi_request().02d,26oct01,kc  Fixed ospf2Mapi_query_config(). Set ospfAdminStat to enabled when                ospf registered to ospf and set it to false when ospf de-registered.02c,25oct01,kc  Fixed ospfAreaAggregateCreateReq request from ospf.02b,25oct01,kc  Ignore update request from ospf for link-state database if the                packet length obtained from the advertisement is 0 byte.02a,24oct01,kc  Added explicit typecast when assigning ulong_t to ushort_t.01z,23oct01,kc  Packet length for link state database must be ushort_t.01y,21oct01,kc  Added mApi2Ospf_forceIfInit() routine.01x,20oct01,kc  Added Area Aggregation support.01w,18oct01,kc  Added ospf2MapiBSemId semaphore for mutual exclusion.01v,17oct01,kc  Added mApi2Ospf_updateStub() routine.01u,17oct01,kc  Fixed lsdb, external lsdb and opaque lsa updates from ospf.01t,17oct01,kc  Added ospfProtoType_t argument to ospf2Mapi_proto_register().01s,16oct01,kc  Removed __WRN_OSPF_MIB__ preproc.01r,15oct01,kc  Changed all ospf2Mapi_xxx_update() to allow new node to be created if                max capacity has not been reached. No longer preallocate buffer pools                at init time.01q,15oct01,kc  Changed OSPF2MAPI_TASK_PRIORITY from 100 to 90 so that the tOspf2Mapi                task can keep up with the requests from Windnet OSPF.01p,13oct01,kc  Use OSPF_INTERFACE for ospfHostCreateReqType so that we can get                the mtu and netmask for host interface.01o,13oct01,kc  Added support for WRN OSPF Enterprise MIB delete from ospf.01n,13oct01,kc  Added support for WRN OSPF Enterprise MIB updates from ospf.01m,13oct01,kc  Moved ospf2MapiReqBuf_t structure defs to ospf_mApi_helper.h.01l,12oct01,kc  Added mApi2Ospf_reinitIf(), mApi2Ospf_updateArea(),                mApi2Ospf_createVirtIf() and mApi2Ospf_configVirtIf().01k,11oct01,kc  Added ospf2Mapi_proto_register().01j,07oct01,kc  Removed unnessary argument from ospf2Mapi_request().01i,07oct01,kc  Need to include ospf_mApi_helper.h before ospf_mib_api.h.01h,07oct01,kc  Made ospf2Mapi_destroy() public.01g,06oct01,kc  Added support ospfHostCreateReqType ospf2MapiReqType_t.01f,04oct01,kc  Added ospf2Mapi_xxx_create() routines.01e,20sep01,kc  Moved DEFAULT_OSPF_REQUEST_BUFFER_CNT define to ospf_mib_api.h.                Changed ospf2Mapi_init() so that the number of ospf request buffers                can be configurable via Tornado Project Facility.01d,18sep01,kc  Created separate task to handle ospf2Mapi updates.01c,15sep01,kc  Implemented ospf2Mapi_xxx routines to handle operational status and                stastical updates from ospf.01b,12sep01,kc  Implemented mApi2Ospf_xxx() routines to configure OSPF protocol01a,07sep01,kc  Initial file 4creation.*//*DESCRIPTIONThis module contains varios helper routines used by the OSPF ManagementInterface and the OSPF protocol. Method routines in this module serve as theintermediate agent by facilitating interoperability between WindNet OSPFv2 andthe management interface.The intention of this module is to encapsulate all the MIB access operations andimplementation detail from the application.In order to minimize disruptionn to the operational of the OSPF Protocol, theoperational status and statistics updates from the OSPF protocol to the OSPF MIBAPI is done asynchrously. A tOspf2Mapi receive task is created to process theupdate request from the OSPF protocol. This task is responsible for performingthe updates from the current operational status and statistics to the OSPF MIBAPI.*//* This include is here to get rid of the "empty file" compiler warning */#include <vxWorks.h>#if defined (__OSPF_MIB__)/* standard vxWorks includes */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -