[rhel7/master/f21] getArch should return ppc64 or ppc64le (#1159271)

Brian C. Lane bcl at redhat.com
Tue Nov 4 19:57:20 UTC 2014


ppc64le is not the same as ppc64 so getArch should distinguish between
them.

Resolves: rhbz#1159271
---
 blivet/arch.py           | 3 ++-
 blivet/devicelibs/lvm.py | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/blivet/arch.py b/blivet/arch.py
index fe22028..810ec1c 100644
--- a/blivet/arch.py
+++ b/blivet/arch.py
@@ -338,7 +338,8 @@ def getArch():
     elif isPPC(bits=32):
         return 'ppc'
     elif isPPC(bits=64):
-        return 'ppc64'
+        # ppc64 and ppc64le are distinct architectures
+        return os.uname()[4]
     elif isAARCH64():
         return 'aarch64'
     elif isAlpha():
diff --git a/blivet/devicelibs/lvm.py b/blivet/devicelibs/lvm.py
index 09a4956..7672f5d 100644
--- a/blivet/devicelibs/lvm.py
+++ b/blivet/devicelibs/lvm.py
@@ -141,7 +141,7 @@ def getPossiblePhysicalExtents():
 
 def getMaxLVSize():
     """ Return the maximum size of a logical volume. """
-    if arch.getArch() in ("x86_64", "ppc64", "alpha", "ia64", "s390"): #64bit architectures
+    if arch.getArch() in ("x86_64", "ppc64", "ppc64le", "alpha", "ia64", "s390"): #64bit architectures
         return Size("8 EiB")
     else:
         return Size("16 TiB")
-- 
1.9.3



More information about the anaconda-patches mailing list