lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Mon,  5 Dec 2016 13:41:36 +0100
From:   Jiri Slaby <jslaby@...e.cz>
To:     jpoimboe@...hat.com
Cc:     linux-kernel@...r.kernel.org, Jiri Slaby <jslaby@...e.cz>
Subject: [PATCH] objtool fix bytes check

Signed-off-by: Jiri Slaby <jslaby@...e.cz>
---
Feel free to stash both of them into your objtool-dwarf branch. They
are on the top of the upstream fix I have sent earlier today.

 tools/objtool/arch/x86/decode.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/tools/objtool/arch/x86/decode.c b/tools/objtool/arch/x86/decode.c
index 98eac1bb106f..ca4ede5ddd8c 100644
--- a/tools/objtool/arch/x86/decode.c
+++ b/tools/objtool/arch/x86/decode.c
@@ -206,7 +206,7 @@ int arch_decode_instruction(struct elf *elf, struct section *sec,
 		break;
 
 	case 0x89:
-		if (insn.rex_prefix.nbytes && insn.modrm.bytes &&
+		if (insn.rex_prefix.nbytes && insn.modrm.nbytes &&
 		    insn.rex_prefix.bytes[0] == 0x48 &&
 		    insn.modrm.bytes[0] == 0xe5) {
 
@@ -277,7 +277,7 @@ int arch_decode_instruction(struct elf *elf, struct section *sec,
 		break;
 
 	case 0x8d:
-		if (insn.rex_prefix.nbytes && insn.modrm.bytes &&
+		if (insn.rex_prefix.nbytes && insn.modrm.nbytes &&
 		    insn.rex_prefix.bytes[0] == 0x48 &&
 		    insn.modrm.bytes[0] == 0x65) {
 
@@ -291,8 +291,8 @@ int arch_decode_instruction(struct elf *elf, struct section *sec,
 			break;
 		}
 
-		if (insn.rex_prefix.bytes && insn.modrm.bytes &&
-		    insn.sib.bytes && insn.rex_prefix.bytes[0] == 0x4c &&
+		if (insn.rex_prefix.nbytes && insn.modrm.nbytes &&
+		    insn.sib.nbytes && insn.rex_prefix.bytes[0] == 0x4c &&
 		    insn.modrm.bytes[0] == 0x54 && insn.sib.bytes[0] == 0x24 &&
 		    insn.displacement.value == 8) {
 
@@ -312,7 +312,7 @@ int arch_decode_instruction(struct elf *elf, struct section *sec,
 			break;
 		}
 
-		if (drap && insn.rex_prefix.bytes && insn.modrm.bytes &&
+		if (drap && insn.rex_prefix.nbytes && insn.modrm.nbytes &&
 		    insn.rex_prefix.bytes[0] == 0x49 &&
 		    insn.modrm.bytes[0] == 0x62 &&
 		    insn.displacement.value == -8) {
-- 
2.11.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ