]> git.puffer.fish Git - matthieu/frr.git/commitdiff
Use ifp->mtu6 in ospf6d and ripngd.
authorhasso <hasso>
Fri, 23 Jul 2004 21:34:27 +0000 (21:34 +0000)
committerhasso <hasso>
Fri, 23 Jul 2004 21:34:27 +0000 (21:34 +0000)
ospf6d/ChangeLog
ospf6d/ospf6_interface.c
ospf6d/ospf6_zebra.c
ripngd/ChangeLog
ripngd/ripng_interface.c
ripngd/ripng_nexthop.c

index 9e8ff461c8a3730d60f1bfc68223a72bc0a718f3..f0df6b95f68f43d66fe8a5c3f6560792af5ef7d4 100644 (file)
@@ -1,3 +1,8 @@
+2004-07-23  Hasso Tepper  <hasso@estpak.ee>
+
+       * ospf6_interface.c, ospf6_zebra.c: use ifp->mtu6 instead of
+         ifp->mtu.
+
 2004-07-23 Paul Jakma <paul@dishone.st>
 
        * ospf6_main.c: Delete LOG_PERROR, not portable.
index aea5f42df747f6d127fdf7dc42e8ba2d33d64d48..3fb3290ad6a0ba8094baa4daa30b37bb03797064 100644 (file)
@@ -142,8 +142,8 @@ ospf6_interface_create (struct interface *ifp)
   oi->flag = 0;
 
   /* Try to adjust I/O buffer size with IfMtu */
-  oi->ifmtu = ifp->mtu;
-  iobuflen = ospf6_iobuf_size (ifp->mtu);
+  oi->ifmtu = ifp->mtu6;
+  iobuflen = ospf6_iobuf_size (ifp->mtu6);
   if (oi->ifmtu > iobuflen)
     {
       zlog_info ("Interface %s: IfMtu is adjusted to I/O buffer size: %d.",
@@ -271,8 +271,8 @@ ospf6_interface_if_add (struct interface *ifp)
 
   /* Try to adjust I/O buffer size with IfMtu */
   if (oi->ifmtu == 0)
-    oi->ifmtu = ifp->mtu;
-  iobuflen = ospf6_iobuf_size (ifp->mtu);
+    oi->ifmtu = ifp->mtu6;
+  iobuflen = ospf6_iobuf_size (ifp->mtu6);
   if (oi->ifmtu > iobuflen)
     {
       zlog_info ("Interface %s: IfMtu is adjusted to I/O buffer size: %d.",
@@ -822,7 +822,7 @@ ospf6_interface_show (struct vty *vty, struct interface *ifp)
   if (oi->area)
     {
       vty_out (vty, "  Instance ID %d, Interface MTU %d (autodetect: %d)%s",
-              oi->instance_id, oi->ifmtu, ifp->mtu, VTY_NEWLINE);
+              oi->instance_id, oi->ifmtu, ifp->mtu6, VTY_NEWLINE);
       inet_ntop (AF_INET, &oi->area->area_id,
                  strbuf, sizeof (strbuf));
       vty_out (vty, "  Area ID %s, Cost %hu%s", strbuf, oi->cost,
@@ -1068,10 +1068,10 @@ DEFUN (ipv6_ospf6_ifmtu,
   if (oi->ifmtu == ifmtu)
     return CMD_SUCCESS;
 
-  if (ifp->mtu != 0 && ifp->mtu < ifmtu)
+  if (ifp->mtu6 != 0 && ifp->mtu6 < ifmtu)
     {
       vty_out (vty, "%s's ospf6 ifmtu cannot go beyond physical mtu (%d)%s",
-               ifp->name, ifp->mtu, VTY_NEWLINE);
+               ifp->name, ifp->mtu6, VTY_NEWLINE);
       return CMD_WARNING;
     }
 
@@ -1452,7 +1452,7 @@ config_write_ospf6_interface (struct vty *vty)
       if (ifp->desc)
         vty_out (vty, " description %s%s", ifp->desc, VTY_NEWLINE);
 
-      if (ifp->mtu != oi->ifmtu)
+      if (ifp->mtu6 != oi->ifmtu)
         vty_out (vty, " ipv6 ospf6 ifmtu %d%s", oi->ifmtu, VTY_NEWLINE);
       vty_out (vty, " ipv6 ospf6 cost %d%s",
                oi->cost, VTY_NEWLINE);
index b622086651229dad0c0412b60b42e4dab8a343e5..88211bb24fa2a799dac5c25ebe4d6834eb5defa8 100644 (file)
@@ -73,7 +73,7 @@ ospf6_zebra_if_add (int command, struct zclient *zclient, zebra_size_t length)
   ifp = zebra_interface_add_read (zclient->ibuf);
   if (IS_OSPF6_DEBUG_ZEBRA (RECV))
     zlog_info ("Zebra Interface add: %s index %d mtu %d",
-               ifp->name, ifp->ifindex, ifp->mtu);
+               ifp->name, ifp->ifindex, ifp->mtu6);
   ospf6_interface_if_add (ifp);
   return 0;
 }
@@ -87,7 +87,7 @@ ospf6_zebra_if_del (int command, struct zclient *zclient, zebra_size_t length)
   ifp = zebra_interface_delete_read (zclient->ibuf);
   if (IS_OSPF6_DEBUG_ZEBRA (RECV))
     zlog_info ("Zebra Interface delete: %s index %d mtu %d",
-               ifp->name, ifp->ifindex, ifp->mtu);
+               ifp->name, ifp->ifindex, ifp->mtu6);
 
   ospf6_interface_if_del (ifp);
 #endif /*0*/
@@ -104,7 +104,7 @@ ospf6_zebra_if_state_update (int command, struct zclient *zclient,
   if (IS_OSPF6_DEBUG_ZEBRA (RECV))
     zlog_info ("Zebra Interface state change: "
                  "%s index %d flags %ld metric %d mtu %d",
-               ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu);
+               ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu6);
 
   ospf6_interface_state_update (ifp);
   return 0;
index 059ee7571f4cf8f3d252c612357b77da546ebf5a..6b05f3de4d0fb8e73e960fa863782f361f15bf6e 100644 (file)
@@ -1,3 +1,8 @@
+2004-07-23  Hasso Tepper  <hasso@estpak.ee>
+
+       * ripng_interface.c, ripng_nexthop.c: use ifp->mtu6 instead of
+         ifp->mtu.
+
 2004-07-01  Greg Troxel  <gdt@fnord.ir.bbn.com>
 
        * ripng_interface.c (ripng_multicast_join): Use privs to do join,
index d4d1e6426c6e4a110cd789a86311ef752b67da86..92067a7a3d1841a6fb3deeecb5c53a5823f16da6 100644 (file)
@@ -166,8 +166,8 @@ ripng_check_max_mtu ()
   for (node = listhead (iflist); node; nextnode (node))
     {
       ifp = getdata (node);
-      if (mtu < ifp->mtu)
-       mtu = ifp->mtu;
+      if (mtu < ifp->mtu6)
+       mtu = ifp->mtu6;
     }
   return mtu;
 }
@@ -243,7 +243,7 @@ ripng_interface_up (int command, struct zclient *zclient, zebra_size_t length)
 
   if (IS_RIPNG_DEBUG_ZEBRA)
     zlog_info ("interface up %s index %d flags %ld metric %d mtu %d",
-              ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu);
+              ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu6);
 
   /* Check if this interface is RIPng enabled or not. */
   ripng_enable_apply (ifp);
@@ -276,7 +276,7 @@ ripng_interface_down (int command, struct zclient *zclient,
 
   if (IS_RIPNG_DEBUG_ZEBRA)
     zlog_info ("interface down %s index %d flags %ld metric %d mtu %d",
-              ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu);
+              ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu6);
 
   return 0;
 }
@@ -291,7 +291,7 @@ ripng_interface_add (int command, struct zclient *zclient, zebra_size_t length)
 
   if (IS_RIPNG_DEBUG_ZEBRA)
     zlog_info ("RIPng interface add %s index %d flags %ld metric %d mtu %d",
-              ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu);
+              ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu6);
 
   /* Check is this interface is RIP enabled or not.*/
   ripng_enable_apply (ifp);
@@ -324,7 +324,7 @@ ripng_interface_delete (int command, struct zclient *zclient,
   }
 
   zlog_info("interface delete %s index %d flags %ld metric %d mtu %d",
-            ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu);
+            ifp->name, ifp->ifindex, ifp->flags, ifp->metric, ifp->mtu6);
 
   /* To support pseudo interface do not free interface structure.  */
   /* if_delete(ifp); */
index 2c5d45cde0daf2b6e78459234643396939d6f6e6..04b13c50dd9bc9a231c941a04ec9a5ce2311c3c2 100644 (file)
@@ -144,7 +144,7 @@ ripng_rte_send(struct list *ripng_rte_list, struct interface *ifp,
   stream_reset (s);
   num = 0;
 
-  mtu = ifp->mtu;
+  mtu = ifp->mtu6;
   if (mtu < 0)
     mtu = IFMINMTU;