Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Jun 2015 11:48:01 +0000 (UTC)
From:      Andriy Gapon <avg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org
Subject:   svn commit: r284510 - stable/9/sys/boot/zfs
Message-ID:  <201506171148.t5HBm1NM042253@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: avg
Date: Wed Jun 17 11:48:00 2015
New Revision: 284510
URL: https://svnweb.freebsd.org/changeset/base/284510

Log:
  MFC r284025,284032: dnode_read: handle hole blocks in zfs boot code
  
  PR:		199804

Modified:
  stable/9/sys/boot/zfs/zfsimpl.c
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/boot/   (props changed)

Modified: stable/9/sys/boot/zfs/zfsimpl.c
==============================================================================
--- stable/9/sys/boot/zfs/zfsimpl.c	Wed Jun 17 11:47:06 2015	(r284509)
+++ stable/9/sys/boot/zfs/zfsimpl.c	Wed Jun 17 11:48:00 2015	(r284510)
@@ -1220,6 +1220,10 @@ dnode_read(const spa_t *spa, const dnode
 			ibn = bn >> ((nlevels - i - 1) * ibshift);
 			ibn &= ((1 << ibshift) - 1);
 			bp = indbp[ibn];
+			if (BP_IS_HOLE(&bp)) {
+				memset(dnode_cache_buf, 0, bsize);
+				break;
+			}
 			rc = zio_read(spa, &bp, dnode_cache_buf);
 			if (rc)
 				return (rc);



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