Blame SOURCES/kvm-Fix-typo-in-variable-name-found-and-fixed-by-codespe.patch

5d360b
From aabe8208c6a3989910d5ab210eba9b7938bdf526 Mon Sep 17 00:00:00 2001
5d360b
From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= <marcandre.lureau@redhat.com>
5d360b
Date: Wed, 13 Dec 2017 13:39:09 +0100
5d360b
Subject: [PATCH 38/41] Fix typo in variable name (found and fixed by
5d360b
 codespell)
5d360b
MIME-Version: 1.0
5d360b
Content-Type: text/plain; charset=UTF-8
5d360b
Content-Transfer-Encoding: 8bit
5d360b
5d360b
RH-Author: Marc-André Lureau <marcandre.lureau@redhat.com>
5d360b
Message-id: <20171213133912.26176-39-marcandre.lureau@redhat.com>
5d360b
Patchwork-id: 78388
5d360b
O-Subject: [RHEL-7.5 qemu-kvm PATCH v3 38/41] Fix typo in variable name (found and fixed by codespell)
5d360b
Bugzilla: 1411490
5d360b
RH-Acked-by: Laszlo Ersek <lersek@redhat.com>
5d360b
RH-Acked-by: Michael S. Tsirkin <mst@redhat.com>
5d360b
RH-Acked-by: Miroslav Rezanina <mrezanin@redhat.com>
5d360b
5d360b
From: Stefan Weil <sw@weilnetz.de>
5d360b
5d360b
Signed-off-by: Stefan Weil <sw@weilnetz.de>
5d360b
Reviewed-by: Fam Zheng <famz@redhat.com>
5d360b
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
5d360b
5d360b
(cherry picked from commit 1d817db3a07774999606f62aa2d8772a82363551)
5d360b
5d360b
RHEL: backported to avoid conflicts in following patch
5d360b
5d360b
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
5d360b
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
5d360b
---
5d360b
 scripts/dump-guest-memory.py | 64 ++++++++++++++++++++++----------------------
5d360b
 1 file changed, 32 insertions(+), 32 deletions(-)
5d360b
5d360b
diff --git a/scripts/dump-guest-memory.py b/scripts/dump-guest-memory.py
5d360b
index 308cfca..03d692d 100644
5d360b
--- a/scripts/dump-guest-memory.py
5d360b
+++ b/scripts/dump-guest-memory.py
5d360b
@@ -56,44 +56,44 @@ class ELF(object):
5d360b
         self.notes = []
5d360b
         self.segments = []
5d360b
         self.notes_size = 0
5d360b
-        self.endianess = None
5d360b
+        self.endianness = None
5d360b
         self.elfclass = ELFCLASS64
5d360b
 
5d360b
         if arch == 'aarch64-le':
5d360b
-            self.endianess = ELFDATA2LSB
5d360b
+            self.endianness = ELFDATA2LSB
5d360b
             self.elfclass = ELFCLASS64
5d360b
-            self.ehdr = get_arch_ehdr(self.endianess, self.elfclass)
5d360b
+            self.ehdr = get_arch_ehdr(self.endianness, self.elfclass)
5d360b
             self.ehdr.e_machine = EM_AARCH
5d360b
 
5d360b
         elif arch == 'aarch64-be':
5d360b
-            self.endianess = ELFDATA2MSB
5d360b
-            self.ehdr = get_arch_ehdr(self.endianess, self.elfclass)
5d360b
+            self.endianness = ELFDATA2MSB
5d360b
+            self.ehdr = get_arch_ehdr(self.endianness, self.elfclass)
5d360b
             self.ehdr.e_machine = EM_AARCH
5d360b
 
5d360b
         elif arch == 'X86_64':
5d360b
-            self.endianess = ELFDATA2LSB
5d360b
-            self.ehdr = get_arch_ehdr(self.endianess, self.elfclass)
5d360b
+            self.endianness = ELFDATA2LSB
5d360b
+            self.ehdr = get_arch_ehdr(self.endianness, self.elfclass)
5d360b
             self.ehdr.e_machine = EM_X86_64
5d360b
 
5d360b
         elif arch == '386':
5d360b
-            self.endianess = ELFDATA2LSB
5d360b
+            self.endianness = ELFDATA2LSB
5d360b
             self.elfclass = ELFCLASS32
5d360b
-            self.ehdr = get_arch_ehdr(self.endianess, self.elfclass)
5d360b
+            self.ehdr = get_arch_ehdr(self.endianness, self.elfclass)
5d360b
             self.ehdr.e_machine = EM_386
5d360b
 
5d360b
         elif arch == 's390':
5d360b
-            self.endianess = ELFDATA2MSB
5d360b
-            self.ehdr = get_arch_ehdr(self.endianess, self.elfclass)
5d360b
+            self.endianness = ELFDATA2MSB
5d360b
+            self.ehdr = get_arch_ehdr(self.endianness, self.elfclass)
5d360b
             self.ehdr.e_machine = EM_S390
5d360b
 
5d360b
         elif arch == 'ppc64-le':
5d360b
-            self.endianess = ELFDATA2LSB
5d360b
-            self.ehdr = get_arch_ehdr(self.endianess, self.elfclass)
5d360b
+            self.endianness = ELFDATA2LSB
5d360b
+            self.ehdr = get_arch_ehdr(self.endianness, self.elfclass)
5d360b
             self.ehdr.e_machine = EM_PPC64
5d360b
 
5d360b
         elif arch == 'ppc64-be':
5d360b
-            self.endianess = ELFDATA2MSB
5d360b
-            self.ehdr = get_arch_ehdr(self.endianess, self.elfclass)
5d360b
+            self.endianness = ELFDATA2MSB
5d360b
+            self.ehdr = get_arch_ehdr(self.endianness, self.elfclass)
5d360b
             self.ehdr.e_machine = EM_PPC64
5d360b
 
5d360b
         else:
5d360b
@@ -107,7 +107,7 @@ class ELF(object):
5d360b
     def add_note(self, n_name, n_desc, n_type):
5d360b
         """Adds a note to the ELF."""
5d360b
 
5d360b
-        note = get_arch_note(self.endianess, len(n_name), len(n_desc))
5d360b
+        note = get_arch_note(self.endianness, len(n_name), len(n_desc))
5d360b
         note.n_namesz = len(n_name) + 1
5d360b
         note.n_descsz = len(n_desc)
5d360b
         note.n_name = n_name.encode()
5d360b
@@ -126,7 +126,7 @@ class ELF(object):
5d360b
     def add_segment(self, p_type, p_paddr, p_size):
5d360b
         """Adds a segment to the elf."""
5d360b
 
5d360b
-        phdr = get_arch_phdr(self.endianess, self.elfclass)
5d360b
+        phdr = get_arch_phdr(self.endianness, self.elfclass)
5d360b
         phdr.p_type = p_type
5d360b
         phdr.p_paddr = p_paddr
5d360b
         phdr.p_filesz = p_size
5d360b
@@ -158,10 +158,10 @@ class ELF(object):
5d360b
             elf_file.write(note)
5d360b
 
5d360b
 
5d360b
-def get_arch_note(endianess, len_name, len_desc):
5d360b
-    """Returns a Note class with the specified endianess."""
5d360b
+def get_arch_note(endianness, len_name, len_desc):
5d360b
+    """Returns a Note class with the specified endianness."""
5d360b
 
5d360b
-    if endianess == ELFDATA2LSB:
5d360b
+    if endianness == ELFDATA2LSB:
5d360b
         superclass = ctypes.LittleEndianStructure
5d360b
     else:
5d360b
         superclass = ctypes.BigEndianStructure
5d360b
@@ -193,20 +193,20 @@ class Ident(ctypes.Structure):
5d360b
                 ('ei_abiversion', ctypes.c_ubyte),
5d360b
                 ('ei_pad', ctypes.c_ubyte * 7)]
5d360b
 
5d360b
-    def __init__(self, endianess, elfclass):
5d360b
+    def __init__(self, endianness, elfclass):
5d360b
         self.ei_mag0 = 0x7F
5d360b
         self.ei_mag1 = ord('E')
5d360b
         self.ei_mag2 = ord('L')
5d360b
         self.ei_mag3 = ord('F')
5d360b
         self.ei_class = elfclass
5d360b
-        self.ei_data = endianess
5d360b
+        self.ei_data = endianness
5d360b
         self.ei_version = EV_CURRENT
5d360b
 
5d360b
 
5d360b
-def get_arch_ehdr(endianess, elfclass):
5d360b
-    """Returns a EHDR64 class with the specified endianess."""
5d360b
+def get_arch_ehdr(endianness, elfclass):
5d360b
+    """Returns a EHDR64 class with the specified endianness."""
5d360b
 
5d360b
-    if endianess == ELFDATA2LSB:
5d360b
+    if endianness == ELFDATA2LSB:
5d360b
         superclass = ctypes.LittleEndianStructure
5d360b
     else:
5d360b
         superclass = ctypes.BigEndianStructure
5d360b
@@ -231,12 +231,12 @@ def get_arch_ehdr(endianess, elfclass):
5d360b
 
5d360b
         def __init__(self):
5d360b
             super(superclass, self).__init__()
5d360b
-            self.e_ident = Ident(endianess, elfclass)
5d360b
+            self.e_ident = Ident(endianness, elfclass)
5d360b
             self.e_type = ET_CORE
5d360b
             self.e_version = EV_CURRENT
5d360b
             self.e_ehsize = ctypes.sizeof(self)
5d360b
             self.e_phoff = ctypes.sizeof(self)
5d360b
-            self.e_phentsize = ctypes.sizeof(get_arch_phdr(endianess, elfclass))
5d360b
+            self.e_phentsize = ctypes.sizeof(get_arch_phdr(endianness, elfclass))
5d360b
             self.e_phnum = 0
5d360b
 
5d360b
 
5d360b
@@ -260,12 +260,12 @@ def get_arch_ehdr(endianess, elfclass):
5d360b
 
5d360b
         def __init__(self):
5d360b
             super(superclass, self).__init__()
5d360b
-            self.e_ident = Ident(endianess, elfclass)
5d360b
+            self.e_ident = Ident(endianness, elfclass)
5d360b
             self.e_type = ET_CORE
5d360b
             self.e_version = EV_CURRENT
5d360b
             self.e_ehsize = ctypes.sizeof(self)
5d360b
             self.e_phoff = ctypes.sizeof(self)
5d360b
-            self.e_phentsize = ctypes.sizeof(get_arch_phdr(endianess, elfclass))
5d360b
+            self.e_phentsize = ctypes.sizeof(get_arch_phdr(endianness, elfclass))
5d360b
             self.e_phnum = 0
5d360b
 
5d360b
     # End get_arch_ehdr
5d360b
@@ -275,10 +275,10 @@ def get_arch_ehdr(endianess, elfclass):
5d360b
         return EHDR32()
5d360b
 
5d360b
 
5d360b
-def get_arch_phdr(endianess, elfclass):
5d360b
-    """Returns a 32 or 64 bit PHDR class with the specified endianess."""
5d360b
+def get_arch_phdr(endianness, elfclass):
5d360b
+    """Returns a 32 or 64 bit PHDR class with the specified endianness."""
5d360b
 
5d360b
-    if endianess == ELFDATA2LSB:
5d360b
+    if endianness == ELFDATA2LSB:
5d360b
         superclass = ctypes.LittleEndianStructure
5d360b
     else:
5d360b
         superclass = ctypes.BigEndianStructure
5d360b
-- 
5d360b
1.8.3.1
5d360b