Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/fs/msdosfs If getdisksize() fails (happens e.g. on fss b...
details: https://anonhg.NetBSD.org/src/rev/ebb9e69fb103
branches: trunk
changeset: 753891:ebb9e69fb103
user: pooka <pooka%NetBSD.org@localhost>
date: Tue Apr 13 10:11:08 2010 +0000
description:
If getdisksize() fails (happens e.g. on fss block devices), don't
give up if we don't really need the information provided by it.
diffstat:
sys/fs/msdosfs/msdosfs_vfsops.c | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
diffs (33 lines):
diff -r 3f462188d701 -r ebb9e69fb103 sys/fs/msdosfs/msdosfs_vfsops.c
--- a/sys/fs/msdosfs/msdosfs_vfsops.c Tue Apr 13 10:06:43 2010 +0000
+++ b/sys/fs/msdosfs/msdosfs_vfsops.c Tue Apr 13 10:11:08 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: msdosfs_vfsops.c,v 1.83 2010/04/11 10:26:25 mlelstv Exp $ */
+/* $NetBSD: msdosfs_vfsops.c,v 1.84 2010/04/13 10:11:08 pooka Exp $ */
/*-
* Copyright (C) 1994, 1995, 1997 Wolfgang Solfrank.
@@ -48,7 +48,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: msdosfs_vfsops.c,v 1.83 2010/04/11 10:26:25 mlelstv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: msdosfs_vfsops.c,v 1.84 2010/04/13 10:11:08 pooka Exp $");
#if defined(_KERNEL_OPT)
#include "opt_compat_netbsd.h"
@@ -489,8 +489,12 @@
goto error_exit;
error = getdisksize(devvp, &psize, &secsize);
- if (error)
- goto error_exit;
+ if (error) {
+ if (argp->flags & MSDOSFSMNT_GEMDOSFS)
+ goto error_exit;
+ secsize = DEV_BSIZE;
+ psize = 0;
+ }
if (argp->flags & MSDOSFSMNT_GEMDOSFS) {
bsize = secsize;
Home |
Main Index |
Thread Index |
Old Index