Date: Thu, 2 Jul 2020 07:15:48 +0000 (UTC) From: Toomas Soome <tsoome@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r362884 - head/stand/libsa/zfs Message-ID: <202007020715.0627FmYF077553@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: tsoome Date: Thu Jul 2 07:15:48 2020 New Revision: 362884 URL: https://svnweb.freebsd.org/changeset/base/362884 Log: loader: zfs reader does not need BOOT2 bits After switching zfsloader to use full libsa, we do not need spa_get_primary() and spa_get_primary_vdev() any more. Sponsored by: Netflix, Klara Inc. Modified: head/stand/libsa/zfs/zfsimpl.c Modified: head/stand/libsa/zfs/zfsimpl.c ============================================================================== --- head/stand/libsa/zfs/zfsimpl.c Thu Jul 2 07:03:15 2020 (r362883) +++ head/stand/libsa/zfs/zfsimpl.c Thu Jul 2 07:15:48 2020 (r362884) @@ -1336,34 +1336,6 @@ spa_find_by_name(const char *name) return (NULL); } -#ifdef BOOT2 -static spa_t * -spa_get_primary(void) -{ - - return (STAILQ_FIRST(&zfs_pools)); -} - -static vdev_t * -spa_get_primary_vdev(const spa_t *spa) -{ - vdev_t *vdev; - vdev_t *kid; - - if (spa == NULL) - spa = spa_get_primary(); - if (spa == NULL) - return (NULL); - vdev = spa->spa_root_vdev; - if (vdev == NULL) - return (NULL); - for (kid = STAILQ_FIRST(&vdev->v_children); kid != NULL; - kid = STAILQ_FIRST(&vdev->v_children)) - vdev = kid; - return (vdev); -} -#endif - static spa_t * spa_create(uint64_t guid, const char *name) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202007020715.0627FmYF077553>