Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/ic In lance_mediachange(), if there is no callback t...



details:   https://anonhg.NetBSD.org/src/rev/8301347e8cfb
branches:  trunk
changeset: 472498:8301347e8cfb
user:      thorpej <thorpej%NetBSD.org@localhost>
date:      Fri Apr 30 18:15:04 1999 +0000

description:
In lance_mediachange(), if there is no callback to the front-end, just
return 0 instead of EINVAL.  In this case, there will only be one media
type, and the upper-level if_media code will ensure that the user is setting
to that type.

In other words, don't require the front-end to provide the no-op.

diffstat:

 sys/dev/ic/lance.c |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (18 lines):

diff -r f270c9b5de2c -r 8301347e8cfb sys/dev/ic/lance.c
--- a/sys/dev/ic/lance.c        Fri Apr 30 17:54:17 1999 +0000
+++ b/sys/dev/ic/lance.c        Fri Apr 30 18:15:04 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: lance.c,v 1.7 1999/02/28 17:10:53 explorer Exp $       */
+/*     $NetBSD: lance.c,v 1.8 1999/04/30 18:15:04 thorpej Exp $        */
 
 /*-
  * Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
@@ -555,7 +555,7 @@
 
        if (sc->sc_mediachange)
                return ((*sc->sc_mediachange)(sc));
-       return (EINVAL);
+       return (0);
 }
 
 void



Home | Main Index | Thread Index | Old Index