summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2005-11-20[isisd] remove includes of common system headers.paul
2005-11-20 Paul Jakma <paul.jakma@sun.com> * (general) remove includes of very common system headers, these are already picked up by zebra.h. Further, including them before zebra.h messes up all our lovely (sarcasm) autoconf'd detecting of platform specific things. Recent addition of stdint.h to configure.ac and zebra.h appears particularly to throw up this problem.
2005-11-20- quagga.spec.in: Release sub-rev now release_rev macro, for rpmbuild -Dpaul
2005-11-16[ospfd] Standardize buffer sizes used for displaying timers.ajs
2005-11-16 Andrew J. Schorr <ajschorr@alumni.princeton.edu> * ospf_dump.h: Define OSPF_TIME_DUMP_SIZE as appropriate buffer size for use with ospf_timer_dump and ospf_timeval_dump. * ospf_vty.c: Change all buffer sizes used with ospf_timer_dump and ospf_timeval_dump to have size OSPF_TIME_DUMP_SIZE. (show_ip_ospf_interface_sub) Fix possible buffer overflow in call to ospf_timer_dump.
2005-11-16[ospfd] Make OSPF_ISM_TIMER_OFF macro safer.ajs
2005-11-16 Andrew J. Schorr <ajschorr@alumni.princeton.edu> * ospf_ism.h: (OSPF_ISM_TIMER_OFF) Improve macro syntax by enclosing in 'do {...} while(0)'.
2005-11-14[workqueue] Update workqueue users callbacks to additional argumentspaul
2005-11-14 Paul Jakma <paul.jakma@sun.com> * (general) pass struct work-queue to callback functions. * workqueue.h: (struct work_queue) move the state flag variables to end. Add an opaque pointer to spec, for user-data global to the queue. Pass reference to work_queue to all callbacks. * workqueue.c: (work_queue_item_remove) pass ref to workqueue to user callbacks. (work_queue_run) ditto.
2005-11-142005-11-14 Paul Jakma <paul.jakma@sun.com>paul
* zebra_rib.c: (rib_process) convert to new workqueue specs and shut up gcc, which complains about cast from void via function parameters, for some dumb reason. Do the cast inside the function instead. (rib_queue_qnode_del) ditto. (rib_queue_init) no need for the casts anymore.
2005-11-14[bug #231] check and include stdint.h, also add std=c99 to gcc CFLAGSpaul
2005-11-14 Paul Jakma <paul.jakma@sun.com> * configure.ac: Tell gcc we like C99. [bug #231] Check and test for stdint.h. * lib/zebra.h: [bug #231] include stdint, if its there.
2005-11-142005-11-14 Paul Jakma <paul.jakma@sun.com>paul
* (general) Add state to detect queue floods. There's no sense trying to be sparing of CPU resources, if the queue is flooding and using ever more memory resources. we should just get on with clearing the queue. The sense of delay and hold were wrong way around, fix. * workqueue.h: (struct work_queue) Add status bitfield. Add 'flood' integer to workqueue spec. Add runs_since_clear counter to workqueue. * workqueue.c: (work_queue_new) set defaults for delay, hold and flood. (work_queue_add) initial schedule should use delay, not hold. (show_work_queues) Print flood field, conserve whitespace. (work_queue_unplug) use delay, not hold. (work_queue_run) consecutive runs should be seperated by hold time, not delay. Keep track of number of consecutive runs, go into 'overdrive' if queue is being flooded, we can't avoid making heavy use of resources, better to use CPU than ever more RAM.
2005-11-14[ospfd] misc small fixes. Fix default stub router setting. no opaque compile.paul
2005-11-14 Paul Jakma <paul.jakma@sun.com> * ospfd.c: (ospf_new) stub-shutdown should just default to unconfigured, too strange otherwise. (ospf_finish_final) t_opaque_lsa_self TIMER_OFF should be preprocessor conditional on HAVE_OPAQUE_LSA. * ospfd.h: (struct ospf) remove the SHUTDOWN_DEFAULT define. no longer used, plus it wasn't in range that the command accepted. * ospf_zebra.h: Depends on vty.h, include it.
2005-11-12[solaris] Extra debug and cross-checks for kernel_socket, two Sol9 fixes.paul
2005-11-12 Alexander Gall <gall@switch.ch> * See [quagga-dev 1815] * kernel_socket.c: (rtm_write) Use SAROUNDUP when HAVE_SIN_LEN is not available. * rt_socket.c: (kernel_rtm_ipv6(_multipath)) set family to AF_INET6 on ipv6 routes. 2005-11-12 Paul Jakma <paul.jakma@sun.com> * kernel_socket.c: Add RTA_NAME_GET macro to extract name from sockaddr_dl. Add some more RTF_ flags. * (ifan_read) Add some debug messages. * (ifm_read) Add more debug messages. More robust cross-checks of index against name. Fall back to by-name lookup if the index lookup fails, future proofing more than anything else. (ifam_read_mesg) Read RTA_IFP. Add debug messages. (ifam_read) More debug. If there's an RTA_IFP and it isn't the name of the interface, save it as the label. (rtm_read_mesg) Read RTA_IFP. (rtm_read) allow name to be retrieved. (rtmsg_debug) expand on the debug message.
2005-11-12[lib] 'show route-map' should print call action seperate from exit policypaul
2005-11-12 Paul Jakma <paul.jakma@sun.com> * routemap.c: (vty_show_route_map_entry) call action is seperate from exit action, latter should still be printed regardless of whether a call is specified.
2005-11-11[ospfd] SPF ospf_canonical_nexthops_free bugfix.paul
2005-11-11[doc] quagga.info updated /again/ due to version bump, d'oh.paul
2005-11-112005-11-11 Paul Jakma <paul.jakma@sun.com>paul
* NEWS: Update. * configure.ac: Bump to 0.99.2
2005-11-11- commit the actual file..paul
2005-11-11[trivia] update quagga.info, auto-built filepaul
2005-11-11 Paul Jakma <paul.jakma@sun.com> * quagga.info: update auto-built file. Methinks it's time to remove from CVS..
2005-11-11[zebra] Fix warning and small connected-label changes merge error.paul
2005-11-11 Paul Jakma <paul.jakma@sun.com> * kernel_socket.c: (ifm_read) arithmetic on void pointer warning. (ifam_read) Fix error from connected-with-label merge, something crept in from the pending Solaris kernel_socket.c patch which shouldn't have.
2005-11-102005-11-10 Paul Jakma <paul.jakma@sun.com>paul
* HACKING: Add recommendation to provide a single Subject style description to the commit message. Add some recommendations for ChangeLog.
2005-11-07[doc] List snmptrap.texi as a source, so it gets included in distpaul
2005-11-07 Paul Jakma <paul.jakma@sun.com> * Makefile.am: snmptrap.texi needs to be listed as a source, not disted otherwise.
2005-11-05- Makefile.am: quagga.pam.stack should be in distspaul
- quagga.spec.in: introduce dist variable to allow for differences e.g in buildreqs, pam config files. etc.
2005-11-042005-11-04 Paul Jakma <paul.jakma@sun.com>paul
* quagga.info: Update auto-built file * ospf6d.texi: Add example config * bgpd.texi: Add example configs. Couple of cleanups of format and macros. * routemap.texi: Add an explanation of how route-maps work. Document the call and exit-policy commands.
2005-11-042005-11-04 Paul Jakma <paul.jakma@sun.com>paul
* snmptrap.texi: Contributed documentation, contributors name is lost (please get in touch). Configuring SNMP for logging traps. * snmp.texi: Minor formatting changes. * quagga.info: Update auto-built file
2005-11-042005-11-04 Paul Jakma <paul.jakma@sun.com>paul
* prototype.dev.in: lib/md5-gnu.h is now lib/md5.h
2005-11-042005-11-04 Paul Jakma <paul.jakma@sun.com>paul
* ospf_{dump,spf,vty}.c: Oops, use the internal tv_sub function rather than unportable timersub.
2005-11-04- quagga.pam: pam_stack.so module is deprecated, use 'include' instead.paul
- quagga.pam.stack: the old pam_stack way, kept to allow spec file to backwards compatible (changes to spec file pending local testing)
2005-11-03- bah, fix likkle typo.paul
2005-11-032005-11-03 Paul Jakma <paul.jakma@sun.com>paul
* memtypes.h: Update auto-built file.
2005-11-032005-11-03 Paul Jakma <paul.jakma@sun.com>paul
* bgp_damp.c: (bgp_reuse_timer) struct bgp can be retrieved via the struct bgp_damp_info, no need to guess by using bgp_get_default().
2005-11-032005-11-03 Paul Jakma <paul.jakma@sun.com>paul
* connected.{c,h}: Include memory.h (connected_add_ipv4) Use MTYPE for ifc label. (connected_add_ipv6) Also should accept label. Store it in ifp. (connected_del_ipv4) Taking label as argument is pointless. * rt_netlink.c: (netlink_interface_addr) update label usage for connected_{add,delete} functions. * if_ioctl.c: (if_getaddrs) NULL label for connected_add_ipv6. * if_ioctl_solaris.c: (interface_list_ioctl) Pass LIFC_NOXMIT so we also find out about NOXMIT interfaces like VNI. Bit of hackery to turn interface names into the primary interface name, later with routing socket messages we only will about primary interfaces anyway, so we must normalise the name. (if_get_addr) take label as argument, so it can be passed to connected_add. If label is provided, then it is interface name to issue the ioctl for address information on, not the ifp name. (interface_list) List AF_UNSPEC too, just in case. * if_proc.c: (ifaddr_proc_ipv6) label for connected_add_ipv6. * interface.c: (if_addr_wakeup) Some very bogus code - sets IFF_RUNNING - add comment. (if_refresh) (ip_address_install) Use MTYPE for ifc label. * ioctl_solaris.c: (if_mangle_up) New function. Hackery to make IFF_UP reflect whether any addresses are left on the interface, as we get signalled for IFF_UP flags change on the primary interface only. Logical interfaces dont generate IFINFO, but we do get an RTM_DELADDR. (if_get_flags) Call if_mangle_up before return. * kernel_socket.c: (ifam_read) Fixup calls to connected_{add,delete} to match above changes. Rename gate variable to brd, less confusing. Pass the interface name as a label, if it is not same name as ifp->name.
2005-11-032005-11-03 Paul Jakma <paul.jakma@sun.com>paul
* ospf_packet.c: Change level of some warnings to informational.
2005-11-032005-11-03 Paul Jakma <paul.jakma@sun.com>paul
* if.c: (connected_free) use MTYPE for connected label. memtypes.c: Add MTYPE_CONNECTED_LABEL
2005-11-032005-11-03 Paul Jakma <paul.jakma@sun.com>paul
* ospf_apiserver.c: (apiserver_sync_callback) stray semi-colon * ospf_packet.c: include checksum.h, remove the in_cksum extern * prototypes. * ospf_te.h: Add braces, quell warning.
2005-11-032005-11-03 Paul Jakma <paul.jakma@sun.com>paul
* zebra.h: BSD BYTE_ORDER define isn't available everywhere, define if needs be. * checksum.h: new file. checksum.c exports in_cksum, provide a header for it. * checksum.c: (in_cksum) callers shouldn't have to know it uses a u_short internally, change to void *. * Makefile.am: Add checksum.h * command.h: remove bogus trailling slash. * md5.c: (general) Update it for the twentieth century. ANSI declarations are widely supported now.. Don't include system headers, only include zebra.h. Use POSIX types (the alternative is to define u_int64_t in a portable way - rest of Quagga needs same cleanup). Make endian-conditional code be compiler conditional rather than preprocessor conditional, so that breakage gets noticed quicker. * md5.h: POSIX types. Get rid of the odd __P() non-ANSI capable compiler compatibility hack.
2005-10-302005-10-30 Andrew J. Schorr <ajschorr@alumni.princeton.edu>ajs
* ripd.c: (rip_response_process) Instead of calling rip_interface.c:if_valid_neighbor(), call the equivalent library function if_lookup_address(). * rip_interface.c: (if_valid_neighbor) Remove function, since it is essentially equivalent to the if_lookup_address() library function. * ripd.h: (if_valid_neighbor) Remove function declaration.
2005-10-292005-10-29 Paul Jakma <paul@dishone.st>paul
* ospfd.texi: Document the new spf and max-metric commands, and the additional form of dead-interval. Add documentation for various other commands. Cleanup misc stuff, citations, etc. Add some example configurations. * overview.texi: RFC3137 support added. * Makefile.am: Make quagga.pdf depend on the _TEXINFOS variable, this still doesn't fix the dependency though, sadly.
2005-10-292005-10-29 Paul Jakma <paul.jakma@sun.com>paul
* (general) RFC3137 stub-router support * ospfd.h: Add OSPF_OUTPUT_COST_INFINITE define. (struct ospf_master) Add a OSPF_MASTER_SHUTDOWN flag for options, to allow shutdown to distinguish between complete shutdown and shutdown of a subset of ospf instances. (struct ospf) Add stub_router_{startup,shutdown_}time, configuration of startup and shutdown time for stub-router. Add t_graceful_shutdown struct thread, timer for graceful shutdown, if needed. (struct ospf_area) Add stub_router_state - run time state of stub-router for an area. Add flags for ADMIN, IS and WAS states. Add t_stub_router, timer thread to resend router-lsa for an area. * ospf_lsa.c: (ospf_link_cost) new simple function to spit out either the given lnks cost or infinite cost if stub-router is in effect. (lsa_link_{ptop,broadcast,virtuallink,ptomp}_set) use previous function for transit-links. (ospf_stub_router_timer) timer thread for end of startup stub router. Change state as required for the area and setup re-origination of router-lsa. (ospf_stub_router_check) Check/do whether stub-router should be enabled, and whether it requires timer to be setup. (ospf_router_lsa_new) call previous function at top. (ospf_router_lsa_originate) no external callers, made static. * ospf_lsa.h: (ospf_router_lsa_originate) removed. * ospf_main.c: (sigint) make static. remove call to exit, as ospf_terminate now deals with exiting. * ospf_route.c: (ospf_terminate) removed, now in ospfd.c. * ospf_vty.c: (show_ip_ospf_area) print out state of stub-router, if active. (show_ip_ospf) print out configuration of stub-router support, and details of graceful-shutdown if the timer is active. ((no)?ospf_max_metric_router_lsa_{admin,startup,shutdown}) new commands to (de-)?configure stub-router support. (config_write_stub_router) write out config of stub-router. (ospf_config_write) call previous. (ospf_vty_init) install the new stub-router commands. * ospfd.c: various functions made static. (ospf_new) Set defaults for stub-router. Graceful shutdown is made to default on, just to be adventerous. (ospf_graceful_shutdown_finish) new function, final part of shutdown. (ospf_graceful_shutdown_timer) timer thread wrapper for graceful-shutdown. (ospf_graceful_shutdown_check) check whether to setup timer for shutdown or proceed directly to final shutdown. (ospf_terminate) moved here from ospf_route.c, call ospf_finish for each instance. (ospf_finish) renamed to ospf_finish_final and made static. (ospf_finish) new function, exported wrapper around ospf_graceful_shutdown_check. (ospf_finish_final) complete shutdown of an instance. Add missing TIMER_OFF's of two timer threads. (ospf_area_free) opaque self lsa timer should be turned off.
2005-10-282005-10-28 Paul Jakma <paul.jakma@sun.com>paul
* Makefile.am: Add rip_interface.h, or else it doesn't get included in dists.
2005-10-262005-10-26 Paul Jakma <paul.jakma@sun.com>paul
* command.c: Use MTYPE_HOST, MTYPE_STRVEC. Some other fixups, including fixing some likely leaks in config_write_file. * vty.c: memory macro usage fixes. (vty_read_config) fix leak where relative config file is specified.
2005-10-262005-10-26 Paul Jakma <paul.jakma@sun.com>paul
* (general) Cleanup a some calls to XFREE,strdup, etc. to use the memory.h macros. * memtypes.c: Add MTYPE_IF_RMAP_NAME, MTYPE_PQUEUE, MTYPE_PQUEUE_DATA and MTYPE_HOST. * memtypes.h: update auto-built file. * if_rmap.c: Use MTYPE_IF_RMAP_NAME. * pqueue.c: Use the two MTYPE_PQUEUE mtypes for allocations.
2005-10-252005-10-26 Paul Jakma <paul.jakma@sun.com>paul
* ripd.c: Update couple more functions to specify void explicitely.
2005-10-252005-10-26 Paul Jakma <paul.jakma@sun.com>paul
* (general) static/extern functions and definitions. * rip_interface.h: new file, export the public functions from rip_interface.c
2005-10-232005-10-23 Paul Jakma <paul.jakma@sun.com>paul
* ospf_apiserver.c: (ospf_apiserver_term) This function should not have side-effects (eg segv) if no apiserver instances are active, ie be robust.
2005-10-232005-10-23 Paul Jakma <paul.jakma@sun.com>paul
* ospf_vty.c: (show_ip_ospf) fix display of SPF timer if it has not yet been run.
2005-10-212005-10-21 Paul Jakma <paul.jakma@sun.com>paul
* ospf_dump.c: (ospf_timeval_dump) fix ms adjustment, thanks to Andrew Schorr. * ospf_vty.c: (ospf_config_write) fix write out of spf timers configuration.
2005-10-212005-10-21 Paul Jakma <paul.jakma@sun.com>paul
* (general) SPF millisecond resolution timer with adaptive, linear back-off holdtime. Prettification of ospf_timer_dump. * ospf_dump.c: (ospf_timeval_dump) new function. The guts of ospf_timer_dump, but made to be more dynamic in printing out the relative timeval, sliding the precision printed out according to the value. (ospf_timer_dump) guts moved to ospf_timeval_dump. * ospf_dump.h: export ospf_timeval_dump. * ospf_flood.c: (ospf_flood) remove gettimeofday, use the libzebra exported recent_time instead, as it's not terribly critical to have time exactly right - the dropped LSA will be retransmited to us if we don't ACK it. * ospf_packet.c: (ospf_ls_upd_timer) Ditto, but here we're not transmitting, just putting LSA back on update transmit list. * ospfd.h: delay and holdtimes should be unsigned. Add spf_max_holdtime and spf_hold_multiplier. Update default defines for delay and hold time to be in msec. (struct ospf) change the SPF timestamp to a struct timeval. Remove ospf_timers_spf_(un)?set. * ospfd.c: (ospf_timers_spf_{set,unset}) removed. (ospf_new) initialise spf_max_holdtime and spf_hold_multiplier * ospf_spf.c: (ospf_spf_calculate) SPF timestamp is a timeval now, update with gettimeofday. (ospf_spf_calculate_schedule) Change SPF timers to millisecond resolution. Make the holdtime be adaptive, with a linear increase in holdtime ever consecutive SPF run which occurs within holdtime of previous SPF, bounded by spf_max_holdtime. * ospf_vty.c: Update spf timers commands. (ospf_timers_spf_set) trivial helper. (ospf_timers_throttle_spf_cmd) new command to set SPF delay, initial hold and max hold times with millisecond resolution. (ospf_timers_spf_cmd) Deprecated. Accept the old values, convert to msec, truncate to new limits. (no_ospf_timers_throttle_spf_cmd) set timers to defaults. (no_ospf_timers_spf_cmd) deprecated form, same as previous. (show_ip_ospf_cmd) Display SPF parameters and times. (show_ip_ospf_neighbour_header) Centralise the 'sh ip os ne' header. (show_ip_ospf_neighbor_sub) Fix the field widths. Get rid of the multiple spaces which were making the lines even longer. (show_ip_ospf_neighbor_cmd) Use show_ip_ospf_neighbour_header (show_ip_ospf_neighbor_all_cmd) ditto and fix the field widths for NBMA neighbours. (show_ip_ospf_neighbor_int) Use header function. (show_ip_ospf_nbr_nbma_detail_sub) use sizeof for timebuf, local array - safer. (show_ip_ospf_neighbor_detail_sub) ditto (ospf_vty_init) install the new SPF throttle timer commands.
2005-10-212005-10-20 Andrew J. Schorr <ajschorr@alumni.princeton.edu>ajs
* sockopt.c: (setsockopt_multicast_ipv4) If IP_ADD_MEMBERSHIP fails with errno equal to EADDRINUSE, then issue an info message and try IP_DROP_MEMBERSHIP followed by IP_ADD_MEMBERSHIP.
2005-10-212005-10-21 Paul Jakma <paul.jakma@sun.com>paul
* (general) OSPF fast, sub-second hello and 1s dead-interval support. A warning fix. Millisec support for ospf_timer_dump. Change auto-cost ref-bandwidth to add a comment to write out of config, rather than printing annoying messages to vty on startup. * ospf_dump.c: (ospf_timer_dump) Print out milliseconds too. Callers typically specify a length of 9, so most see millisecs unless they specify the additional length. * ospf_interface.h: (struct ospf_interface) new interface param, fast_hello. * ospf_interface.c: (ospf_if_table_lookup) add brackets, gcc warning fix. (ospf_new_if_params) Initialise fast_hello param. (ospf_free_if_params) Check whether fast_hello is configured. (ospf_if_new_hook) set fast_hello to default. * ospf_ism.h: Wrap OSPF_ISM_TIMER_ON inside do {} while (0) to prevent funny side-effects from its if statement when this macro is used conditionally by other macros. (OSPF_ISM_TIMER_MSEC_ON) new macro, set in milliseconds. (OSPF_HELLO_TIMER_ON) new macro to set hello timer according to whether fast_hello is set. * ospf_ism.c: Update all setting of the hello timer to use either OSPF_ISM_TIMER_MSEC_ON or OSPF_HELLO_TIMER_ON. The former is used when hello is to be sent immediately. * ospf_nsm.c: ditto * ospf_packet.c: (ospf_hello) hello-interval is not checked for mismatch if fast_hello is set. (ospf_read) Annoying nit, fix "no ospf_interface" to be debug rather than a warning, as it can be perfectly normal to receive packets when logical subnets are used. (ospf_make_hello) Set hello-interval to 0 if fast-hellos are configured. * ospf_vty.c: (ospf_auto_cost_reference_bandwidth) annoying nit, don't vty_out if this command is given, it gets tired quick. (show_ip_ospf_interface_sub) Print the hello-interval according to whether fast-hello is set or not. Print the extra 5 millisec characters from (ospf_timer_dump) if fast-hello is configured. (ospf_vty_dead_interval_set) new function, common to all forms of dead-interval command, to set dead-interval and fast-hello correctly. If a dead-interval is given, unset fast-hello, else if a hello-multiplier is set, set dead-interval to 1 and fast-hello to given multiplier. (ip_ospf_dead_interval_addr_cmd) use ospf_vty_dead_interval_set(). (ip_ospf_dead_interval_minimal_addr_cmd) ditto. (no_ip_ospf_dead_interval) Unset fast-hello. (no_ip_ospf_hello_interval) Bug-fix, unset of hello-interval should set it to OSPF_HELLO_INTERVAL_DEFAULT, not OSPF_ROUTER_DEAD_INTERVAL_DEFAULT. (config_write_interface) Write out fast-hello. (ospf_config_write) Write a comment about "auto-cost reference-bandwidth" having to be equal on all routers. Hopefully just as noticeable as old practice of writing to vty, but less annoying. (ospf_vty_if_init) install the two new dead-interval commands. * ospfd.h: Add defines for OSPF_ROUTER_DEAD_INTERVAL_MINIMAL and OSPF_FAST_HELLO_DEFAULT.
2005-10-202005-10-20 Andrew J. Schorr <ajschorr@alumni.princeton.edu>ajs
* memory.c: (show_memory_vty) Omit zero statistics. Print separators only if some non-zero stats have been printed in between. (show_separator) New function to print a separator. (show_memory_all) Keep track of whether a separator is needed between the different memory statistics groups.
2005-10-192005-10-17 Vincent Jardin <vincent.jardin@6wind.com>jardin
* ripd.c: rip_create_socket() for each packet, it does not bind to the proper interfaces because we forget to use the from address when it is specified.
2005-10-182005-10-18 Andrew J. Schorr <ajschorr@alumni.princeton.edu>ajs
* memtypes.h: Add MTYPE_OSPF_VERTEX_PARENT (to match memtypes.c).