]> git.proxmox.com Git - mirror_frr.git/commitdiff
*: Rename quagga_timestamp with frr_timestamp
authorDonald Sharp <sharpd@nvidia.com>
Thu, 11 Nov 2021 19:33:41 +0000 (14:33 -0500)
committerDonald Sharp <sharpd@nvidia.com>
Thu, 11 Nov 2021 19:41:27 +0000 (14:41 -0500)
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
bgpd/bgp_fsm.c
bgpd/bgp_route.c
lib/log.c
lib/log.h
lib/vty.c
vtysh/vtysh.c
zebra/interface.c
zebra/interface.h

index 5b997867e0e4d2dfc34870a219ce51e7a3ac3503..91265ed358533ee991beb854e1d3595f6ffd7761 100644 (file)
@@ -756,8 +756,8 @@ void bgp_update_delay_end(struct bgp *bgp)
        bgp->implicit_eors = 0;
        bgp->explicit_eors = 0;
 
-       quagga_timestamp(3, bgp->update_delay_end_time,
-                        sizeof(bgp->update_delay_end_time));
+       frr_timestamp(3, bgp->update_delay_end_time,
+                     sizeof(bgp->update_delay_end_time));
 
        /*
         * Add an end-of-initial-update marker to the main process queues so
@@ -804,8 +804,8 @@ void bgp_start_routeadv(struct bgp *bgp)
        if (bgp->main_peers_update_hold)
                return;
 
-       quagga_timestamp(3, bgp->update_delay_peers_resume_time,
-                        sizeof(bgp->update_delay_peers_resume_time));
+       frr_timestamp(3, bgp->update_delay_peers_resume_time,
+                     sizeof(bgp->update_delay_peers_resume_time));
 
        for (ALL_LIST_ELEMENTS(bgp->peer, node, nnode, peer)) {
                if (!peer_established(peer))
@@ -1057,8 +1057,8 @@ static void bgp_update_delay_begin(struct bgp *bgp)
                thread_add_timer(bm->master, bgp_establish_wait_timer, bgp,
                                 bgp->v_establish_wait, &bgp->t_establish_wait);
 
-       quagga_timestamp(3, bgp->update_delay_begin_time,
-                        sizeof(bgp->update_delay_begin_time));
+       frr_timestamp(3, bgp->update_delay_begin_time,
+                     sizeof(bgp->update_delay_begin_time));
 }
 
 static void bgp_update_delay_process_status_change(struct peer *peer)
index fdaee9b600e9c5b2a2250c1050dc834a104c7e76..962a35a4adfc3d4a17f03dd45df8ae45901979ba 100644 (file)
@@ -2775,8 +2775,8 @@ static void bgp_process_main_one(struct bgp *bgp, struct bgp_dest *dest,
        }
        /* Is it end of initial update? (after startup) */
        if (!dest) {
-               quagga_timestamp(3, bgp->update_delay_zebra_resume_time,
-                                sizeof(bgp->update_delay_zebra_resume_time));
+               frr_timestamp(3, bgp->update_delay_zebra_resume_time,
+                             sizeof(bgp->update_delay_zebra_resume_time));
 
                bgp->main_zebra_update_hold = 0;
                FOREACH_AFI_SAFI (afi, safi) {
index 8be171613e8e4bc5694ef0049a62e2ab37717810..fb12c08aae12abaa7f669634e2f46c244443a7f5 100644 (file)
--- a/lib/log.c
+++ b/lib/log.c
@@ -64,7 +64,7 @@ const char *lookup_msg(const struct message *mz, int kz, const char *nf)
 }
 
 /* For time string format. */
-size_t quagga_timestamp(int timestamp_precision, char *buf, size_t buflen)
+size_t frr_timestamp(int timestamp_precision, char *buf, size_t buflen)
 {
        static struct {
                time_t last;
index 59f1742d01e16acaa79277a19f8c58b276dd503a..3011fa9a994187db7ef797ee9247bd5bfc449dd3 100644 (file)
--- a/lib/log.h
+++ b/lib/log.h
@@ -102,9 +102,9 @@ extern void zlog_backtrace_sigsafe(int priority, void *program_counter);
    It caches the most recent localtime result and can therefore
    avoid multiple calls within the same second.  If buflen is too small,
    *buf will be set to '\0', and 0 will be returned. */
-#define QUAGGA_TIMESTAMP_LEN 40
-extern size_t quagga_timestamp(int timestamp_precision /* # subsecond digits */,
-                              char *buf, size_t buflen);
+#define FRR_TIMESTAMP_LEN 40
+extern size_t frr_timestamp(int timestamp_precision /* # subsecond digits */,
+                           char *buf, size_t buflen);
 
 extern void zlog_hexdump(const void *mem, size_t len);
 extern const char *zlog_sanitize(char *buf, size_t bufsz, const void *in,
@@ -135,8 +135,8 @@ struct timestamp_control {
        size_t len;                     /* length of rendered timestamp */
        int precision;                  /* configuration parameter */
        int already_rendered;           /* should be initialized to 0 */
-       char buf[QUAGGA_TIMESTAMP_LEN]; /* will contain the rendered timestamp
-                                          */
+       char buf[FRR_TIMESTAMP_LEN];    /* will contain the rendered timestamp
+                                        */
 };
 
 /* Defines for use in command construction: */
index 388af8ebaf4e9ef9d0d15f55180fe9f05802120e..b702fa7850c7cddb220a91672c1f1f298efa8655 100644 (file)
--- a/lib/vty.c
+++ b/lib/vty.c
@@ -283,10 +283,10 @@ done:
 /* Output current time to the vty. */
 void vty_time_print(struct vty *vty, int cr)
 {
-       char buf[QUAGGA_TIMESTAMP_LEN];
+       char buf[FRR_TIMESTAMP_LEN];
 
-       if (quagga_timestamp(0, buf, sizeof(buf)) == 0) {
-               zlog_info("quagga_timestamp error");
+       if (frr_timestamp(0, buf, sizeof(buf)) == 0) {
+               zlog_info("frr_timestamp error");
                return;
        }
        if (cr)
index 53349452e6ac4272741f5ca376c02b4c2ca19885..2537ff45718692bb9f15f91f080310868903d49d 100644 (file)
@@ -484,7 +484,7 @@ static int vtysh_execute_func(const char *line, int pager)
        if (vtysh_add_timestamp && strncmp(line, "exit", 4)) {
                char ts[48];
 
-               (void)quagga_timestamp(3, ts, sizeof(ts));
+               (void)frr_timestamp(3, ts, sizeof(ts));
                vty_out(vty, "%% %s\n\n", ts);
        }
 
index 6479dbb58a3f1d676fd5683fd0dca38568b66279..49a1e4917546fe52cfc383cb3bf82f3eb089f7f0 100644 (file)
@@ -1026,7 +1026,7 @@ void if_up(struct interface *ifp)
 
        zif = ifp->info;
        zif->up_count++;
-       quagga_timestamp(2, zif->up_last, sizeof(zif->up_last));
+       frr_timestamp(2, zif->up_last, sizeof(zif->up_last));
 
        /* Notify the protocol daemons. */
        if (ifp->ptm_enable && (ifp->ptm_status == ZEBRA_PTM_STATUS_DOWN)) {
@@ -1090,7 +1090,7 @@ void if_down(struct interface *ifp)
 
        zif = ifp->info;
        zif->down_count++;
-       quagga_timestamp(2, zif->down_last, sizeof(zif->down_last));
+       frr_timestamp(2, zif->down_last, sizeof(zif->down_last));
 
        if_down_nhg_dependents(ifp);
 
index 23e22bdda8976fad88a9912f5c12fd4229bcd5d7..771398b54762fae9ef5697484fb009232bd33fee 100644 (file)
@@ -340,9 +340,9 @@ struct zebra_if {
 
        /* Information about up/down changes */
        unsigned int up_count;
-       char up_last[QUAGGA_TIMESTAMP_LEN];
+       char up_last[FRR_TIMESTAMP_LEN];
        unsigned int down_count;
-       char down_last[QUAGGA_TIMESTAMP_LEN];
+       char down_last[FRR_TIMESTAMP_LEN];
 
 #if defined(HAVE_RTADV)
        struct rtadvconf rtadv;