Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/pci Fix a bug that read value of MII_EXTSR register ...



details:   https://anonhg.NetBSD.org/src/rev/9d825c79956b
branches:  trunk
changeset: 456167:9d825c79956b
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Fri Apr 26 04:58:40 2019 +0000

description:
Fix a bug that read value of MII_EXTSR register on TBI mode always fails.
This bug was added in rev. 1.169.

diffstat:

 sys/dev/pci/if_sip.c |  7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diffs (28 lines):

diff -r e449ef398d5c -r 9d825c79956b sys/dev/pci/if_sip.c
--- a/sys/dev/pci/if_sip.c      Fri Apr 26 04:33:00 2019 +0000
+++ b/sys/dev/pci/if_sip.c      Fri Apr 26 04:58:40 2019 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_sip.c,v 1.169 2019/01/22 03:42:27 msaitoh Exp $     */
+/*     $NetBSD: if_sip.c,v 1.170 2019/04/26 04:58:40 msaitoh Exp $     */
 
 /*-
  * Copyright (c) 2001, 2002 The NetBSD Foundation, Inc.
@@ -73,7 +73,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_sip.c,v 1.169 2019/01/22 03:42:27 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_sip.c,v 1.170 2019/04/26 04:58:40 msaitoh Exp $");
 
 
 
@@ -3295,7 +3295,8 @@
                         * register itself seems read back 0 on some
                         * boards.  Just hard-code the result.
                         */
-                       return (EXTSR_1000XFDX|EXTSR_1000XHDX);
+                       *val = (EXTSR_1000XFDX | EXTSR_1000XHDX);
+                       return 0;
 
                default:
                        return (0);



Home | Main Index | Thread Index | Old Index