Source-Changes-HG archive

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

[src/netbsd-7]: src/sys/fs/adosfs Pull up following revision(s) (requested by...



details:   https://anonhg.NetBSD.org/src/rev/bac643a67a3c
branches:  netbsd-7
changeset: 799719:bac643a67a3c
user:      bouyer <bouyer%NetBSD.org@localhost>
date:      Sun Nov 22 14:02:31 2015 +0000

description:
Pull up following revision(s) (requested by phx in ticket #1042):
        sys/fs/adosfs/advfsops.c: revision 1.75
Patch by hannken@ to fix a bug which has been introduced with 1.71.
The kernel crashed with uvm fault when mounting an ados file system.

diffstat:

 sys/fs/adosfs/advfsops.c |  11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diffs (41 lines):

diff -r 0e7c7dd06bd8 -r bac643a67a3c sys/fs/adosfs/advfsops.c
--- a/sys/fs/adosfs/advfsops.c  Wed Nov 18 08:56:05 2015 +0000
+++ b/sys/fs/adosfs/advfsops.c  Sun Nov 22 14:02:31 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: advfsops.c,v 1.71 2014/08/05 08:50:54 hannken Exp $    */
+/*     $NetBSD: advfsops.c,v 1.71.2.1 2015/11/22 14:02:31 bouyer Exp $ */
 
 /*
  * Copyright (c) 1994 Christian E. Hopps
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: advfsops.c,v 1.71 2014/08/05 08:50:54 hannken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: advfsops.c,v 1.71.2.1 2015/11/22 14:02:31 bouyer Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_netbsd.h"
@@ -369,9 +369,12 @@
 int
 adosfs_vget(struct mount *mp, ino_t an, struct vnode **vpp)
 {
+       u_long block;
        int error;
 
-       error = vcache_get(mp, &an, sizeof(an), vpp);
+       block = an;
+       KASSERT(block == an);
+       error = vcache_get(mp, &block, sizeof(block), vpp);
        if (error)
                return error;
        error = vn_lock(*vpp, LK_EXCLUSIVE);
@@ -394,7 +397,7 @@
        struct adosfsmount *amp;
        struct anode *ap;
        struct buf *bp;
-       ino_t an;
+       u_long an;
        char *nam, *tmp;
        int namlen, error;
 



Home | Main Index | Thread Index | Old Index