From 2ae480983db31ef28463702bb2d60ce94e0768bf Mon Sep 17 00:00:00 2001
From: Aron Xu <aron@debian.org>
Date: Sun, 18 Aug 2013 12:58:30 +0800
Subject: [PATCH 1/2] Add check for sparc as well

Previously we only cared about kfreebsd so only kfreebsd-sparc is
checked, adding sparc for ZoL.
---
 lib/zfs-base.sh |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/zfs-base.sh b/lib/zfs-base.sh
index 0dc7602..b863ed8 100644
--- a/lib/zfs-base.sh
+++ b/lib/zfs-base.sh
@@ -60,7 +60,8 @@ pv_allowed () {
 	cd $dev
 
 	# sparc can not have ZFS starting at 0 or it will destroy the partition table
-	if [ "$(udpkg --print-architecture)" = kfreebsd-sparc ] && \
+	if ([ "$(udpkg --print-architecture)" = sparc ] || \
+	   [ "$(udpkg --print-architecture)" = kfreebsd-sparc ] && \
 	   [ "${id%%-*}" = 0 ]; then
 		return 1
 	fi
-- 
1.7.10.4

