Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/hp300/stand Fix inappropriate error messages when n...



details:   https://anonhg.NetBSD.org/src/rev/804567b65348
branches:  trunk
changeset: 1009609:804567b65348
user:      tsutsui <tsutsui%NetBSD.org@localhost>
date:      Tue Apr 28 14:45:23 2020 +0000

description:
Fix inappropriate error messages when nfs_mount() fails.

Noticed by Chris Hanson and his HP330 and confirmed on my HP425e.
Also bump revisions to denote visible changes.
Worth to pull up to netbsd-9.

diffstat:

 sys/arch/hp300/stand/common/netio.c |  8 ++++----
 sys/arch/hp300/stand/inst/version   |  3 ++-
 sys/arch/hp300/stand/uboot/version  |  3 ++-
 3 files changed, 8 insertions(+), 6 deletions(-)

diffs (56 lines):

diff -r 19fea2607678 -r 804567b65348 sys/arch/hp300/stand/common/netio.c
--- a/sys/arch/hp300/stand/common/netio.c       Tue Apr 28 14:27:41 2020 +0000
+++ b/sys/arch/hp300/stand/common/netio.c       Tue Apr 28 14:45:23 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: netio.c,v 1.16 2016/06/11 06:20:11 dholland Exp $      */
+/*     $NetBSD: netio.c,v 1.17 2020/04/28 14:45:23 tsutsui Exp $       */
 
 /*-
  * Copyright (c) 1996, 1997 The NetBSD Foundation, Inc.
@@ -158,7 +158,6 @@
 int
 netmountroot(struct open_file *f, char *devname)
 {
-       int error;
        struct iodesc *d;
 
 #ifdef DEBUG
@@ -260,7 +259,8 @@
 
  do_nfs_mount:
        /* Get the NFS file handle (mount). */
-       error = nfs_mount(netdev_sock, rootip, rootpath);
+       if (nfs_mount(netdev_sock, rootip, rootpath))
+               return errno;
 
-       return error;
+       return 0;
 }
diff -r 19fea2607678 -r 804567b65348 sys/arch/hp300/stand/inst/version
--- a/sys/arch/hp300/stand/inst/version Tue Apr 28 14:27:41 2020 +0000
+++ b/sys/arch/hp300/stand/inst/version Tue Apr 28 14:45:23 2020 +0000
@@ -1,4 +1,4 @@
-$NetBSD: version,v 1.13 2016/01/17 08:05:20 tsutsui Exp $
+$NetBSD: version,v 1.14 2020/04/28 14:45:24 tsutsui Exp $
 
 1.1:   Initial version
 1.2:   Added support for HP-IB cartridge tapes
@@ -13,3 +13,4 @@
 1.11:  Add support for framebuffers on HP362 and HP382.
 1.12:  Add and fix support for HP425e mcclock, sti framebuffer, apci and dnkbd.
 1.13:  Disable slow gunzip CRC32 calculation.
+1.14:  Fix wrong errno when nfs_mount() fails.
diff -r 19fea2607678 -r 804567b65348 sys/arch/hp300/stand/uboot/version
--- a/sys/arch/hp300/stand/uboot/version        Tue Apr 28 14:27:41 2020 +0000
+++ b/sys/arch/hp300/stand/uboot/version        Tue Apr 28 14:45:23 2020 +0000
@@ -1,4 +1,4 @@
-$NetBSD: version,v 1.20 2016/01/17 08:05:20 tsutsui Exp $
+$NetBSD: version,v 1.21 2020/04/28 14:45:24 tsutsui Exp $
 
 1.1:   Initial version
 1.2:   Added support for network booting
@@ -20,3 +20,4 @@
 1.18:  Add support for framebuffers on HP362 and HP382.
 1.19:  Add and fix support for HP425e mcclock, sti framebuffer, apci and dnkbd.
 1.20:  Disable slow gunzip CRC32 calculation.
+1.21:  Fix wrong errno when nfs_mount() fails.



Home | Main Index | Thread Index | Old Index