Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/net Don't return ENETRESET when ioctl SIOCSIFMTU



details:   https://anonhg.NetBSD.org/src/rev/3d66f803851e
branches:  trunk
changeset: 797534:3d66f803851e
user:      ozaki-r <ozaki-r%NetBSD.org@localhost>
date:      Sun Jul 20 16:40:34 2014 +0000

description:
Don't return ENETRESET when ioctl SIOCSIFMTU

Otherwise, just changing MTU with ifconfig shows
a confusable error message.

RP kern/48996

diffstat:

 sys/net/if_bridge.c |  9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diffs (30 lines):

diff -r 2a628c9689a1 -r 3d66f803851e sys/net/if_bridge.c
--- a/sys/net/if_bridge.c       Sun Jul 20 16:04:48 2014 +0000
+++ b/sys/net/if_bridge.c       Sun Jul 20 16:40:34 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_bridge.c,v 1.87 2014/07/14 02:34:36 ozaki-r Exp $   */
+/*     $NetBSD: if_bridge.c,v 1.88 2014/07/20 16:40:34 ozaki-r Exp $   */
 
 /*
  * Copyright 2001 Wasabi Systems, Inc.
@@ -80,7 +80,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_bridge.c,v 1.87 2014/07/14 02:34:36 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_bridge.c,v 1.88 2014/07/20 16:40:34 ozaki-r Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_bridge_ipf.h"
@@ -648,6 +648,11 @@
                }
                break;
 
+       case SIOCSIFMTU:
+               if ((error = ifioctl_common(ifp, cmd, data)) == ENETRESET)
+                       error = 0;
+               break;
+
        default:
                error = ifioctl_common(ifp, cmd, data);
                break;



Home | Main Index | Thread Index | Old Index