Date: Sun, 3 Dec 2017 04:55:33 +0000 (UTC) From: Warner Losh <imp@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r326494 - in head: stand/zfs sys/cddl/boot/zfs Message-ID: <201712030455.vB34tXEP056571@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: imp Date: Sun Dec 3 04:55:33 2017 New Revision: 326494 URL: https://svnweb.freebsd.org/changeset/base/326494 Log: Mark two things as unused (since they are only sometimes used) and toss in a DECONST to remove a const in some tricky code that would require too extensive a change to unwind otherwise. Sponsored by: Netflix Modified: head/stand/zfs/zfsimpl.c head/sys/cddl/boot/zfs/zfssubr.c Modified: head/stand/zfs/zfsimpl.c ============================================================================== --- head/stand/zfs/zfsimpl.c Sun Dec 3 04:55:28 2017 (r326493) +++ head/stand/zfs/zfsimpl.c Sun Dec 3 04:55:33 2017 (r326494) @@ -43,7 +43,7 @@ struct zfsmount { objset_phys_t objset; uint64_t rootobj; }; -static struct zfsmount zfsmount; +static struct zfsmount zfsmount __unused; /* * List of all vdevs, chained through v_alllink. Modified: head/sys/cddl/boot/zfs/zfssubr.c ============================================================================== --- head/sys/cddl/boot/zfs/zfssubr.c Sun Dec 3 04:55:28 2017 (r326493) +++ head/sys/cddl/boot/zfs/zfssubr.c Sun Dec 3 04:55:33 2017 (r326494) @@ -250,7 +250,7 @@ zio_checksum_template_init(enum zio_checksum checksum, * all of the checksum context templates and deallocates any that were * initialized using the algorithm-specific template init function. */ -static void +static void __unused zio_checksum_templates_free(spa_t *spa) { for (enum zio_checksum checksum = 0; @@ -284,7 +284,7 @@ zio_checksum_verify(const spa_t *spa, const blkptr_t * return (EINVAL); if (spa != NULL) { - zio_checksum_template_init(checksum, (spa_t *) spa); + zio_checksum_template_init(checksum, __DECONST(spa_t *,spa)); ctx = spa->spa_cksum_tmpls[checksum]; }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201712030455.vB34tXEP056571>