Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 19 Oct 2017 12:55:11 +0000 (UTC)
From:      Ed Maste <emaste@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r324753 - head/sys/fs/msdosfs
Message-ID:  <201710191255.v9JCtBQ0043104@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: emaste
Date: Thu Oct 19 12:55:11 2017
New Revision: 324753
URL: https://svnweb.freebsd.org/changeset/base/324753

Log:
  msdosfs: fix build with MSDOSFS_DEBUG
  
  Inspired by a patch submission by longwitz@incore.de with many changes
  for ino64 in HEAD.
  
  PR:		199152
  MFC after:	2 weeks
  Sponsored by:	The FreeBSD Foundation

Modified:
  head/sys/fs/msdosfs/msdosfs_conv.c
  head/sys/fs/msdosfs/msdosfs_denode.c
  head/sys/fs/msdosfs/msdosfs_vfsops.c
  head/sys/fs/msdosfs/msdosfs_vnops.c

Modified: head/sys/fs/msdosfs/msdosfs_conv.c
==============================================================================
--- head/sys/fs/msdosfs/msdosfs_conv.c	Thu Oct 19 09:01:15 2017	(r324752)
+++ head/sys/fs/msdosfs/msdosfs_conv.c	Thu Oct 19 12:55:11 2017	(r324753)
@@ -594,7 +594,7 @@ winChkName(struct mbnambuf *nbp, const u_char *un, siz
 		return -1;
 
 #ifdef MSDOSFS_DEBUG
-	printf("winChkName(): un=%s:%d,d_name=%s:%d\n", un, unlen,
+	printf("winChkName(): un=%s:%zu,d_name=%s:%d\n", un, unlen,
 							dirbuf.d_name,
 							dirbuf.d_namlen);
 #endif

Modified: head/sys/fs/msdosfs/msdosfs_denode.c
==============================================================================
--- head/sys/fs/msdosfs/msdosfs_denode.c	Thu Oct 19 09:01:15 2017	(r324752)
+++ head/sys/fs/msdosfs/msdosfs_denode.c	Thu Oct 19 12:55:11 2017	(r324753)
@@ -590,8 +590,9 @@ msdosfs_inactive(struct vop_inactive_args *ap)
 	 * as empty.  (This may not be necessary for the dos filesystem.)
 	 */
 #ifdef MSDOSFS_DEBUG
-	printf("msdosfs_inactive(): dep %p, refcnt %ld, mntflag %x, MNT_RDONLY %x\n",
-	       dep, dep->de_refcnt, vp->v_mount->mnt_flag, MNT_RDONLY);
+	printf("msdosfs_inactive(): dep %p, refcnt %ld, mntflag %llx, MNT_RDONLY %llx\n",
+	    dep, dep->de_refcnt, (unsigned long long)vp->v_mount->mnt_flag,
+	    (unsigned long long)MNT_RDONLY);
 #endif
 	if (dep->de_refcnt <= 0 && (vp->v_mount->mnt_flag & MNT_RDONLY) == 0) {
 		error = detrunc(dep, (u_long) 0, 0, NOCRED);

Modified: head/sys/fs/msdosfs/msdosfs_vfsops.c
==============================================================================
--- head/sys/fs/msdosfs/msdosfs_vfsops.c	Thu Oct 19 09:01:15 2017	(r324752)
+++ head/sys/fs/msdosfs/msdosfs_vfsops.c	Thu Oct 19 12:55:11 2017	(r324753)
@@ -75,6 +75,10 @@
 #include <fs/msdosfs/fat.h>
 #include <fs/msdosfs/msdosfsmount.h>
 
+#ifdef MSDOSFS_DEBUG
+#include <sys/rwlock.h>
+#endif
+
 static const char msdosfs_lock_msg[] = "fatlk";
 
 /* Mount options that we support. */

Modified: head/sys/fs/msdosfs/msdosfs_vnops.c
==============================================================================
--- head/sys/fs/msdosfs/msdosfs_vnops.c	Thu Oct 19 09:01:15 2017	(r324752)
+++ head/sys/fs/msdosfs/msdosfs_vnops.c	Thu Oct 19 12:55:11 2017	(r324753)
@@ -348,10 +348,13 @@ msdosfs_setattr(struct vop_setattr_args *ap)
 	    (vap->va_bytes != VNOVAL) || (vap->va_gen != VNOVAL)) {
 #ifdef MSDOSFS_DEBUG
 		printf("msdosfs_setattr(): returning EINVAL\n");
-		printf("    va_type %d, va_nlink %x, va_fsid %lx, va_fileid %lx\n",
-		    vap->va_type, vap->va_nlink, vap->va_fsid, vap->va_fileid);
-		printf("    va_blocksize %lx, va_rdev %x, va_bytes %qx, va_gen %lx\n",
-		    vap->va_blocksize, vap->va_rdev, vap->va_bytes, vap->va_gen);
+		printf("    va_type %d, va_nlink %llx, va_fsid %llx, va_fileid %llx\n",
+		    vap->va_type, (unsigned long long)vap->va_nlink,
+		    (unsigned long long)vap->va_fsid,
+		    (unsigned long long)vap->va_fileid);
+		printf("    va_blocksize %lx, va_rdev %llx, va_bytes %llx, va_gen %lx\n",
+		    vap->va_blocksize, (unsigned long long)vap->va_rdev,
+		    (unsigned long long)vap->va_bytes, vap->va_gen);
 		printf("    va_uid %x, va_gid %x\n",
 		    vap->va_uid, vap->va_gid);
 #endif



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201710191255.v9JCtBQ0043104>