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>] [day] [month] [year] [list]
Message-Id: <20070522.012314.122830458.anemo@mba.ocn.ne.jp>
Date:	Tue, 22 May 2007 01:23:14 +0900 (JST)
From:	Atsushi Nemoto <anemo@....ocn.ne.jp>
To:	sam@...nborg.org
Cc:	linux-kernel@...r.kernel.org, ralf@...ux-mips.org
Subject: [PATCH] kbuild: fix and improve MIPS REL handling 

Add R_MIPS_32 relocation case.
And there is no need to do sign-extention on calculation of addend.

Signed-off-by: Atsushi Nemoto <anemo@....ocn.ne.jp>
---
This is a patch against kbuild-tree.

--- linux-kbuild/scripts/mod/modpost.c	2007-05-22 01:14:45.000000000 +0900
+++ linux/scripts/mod/modpost.c	2007-05-22 01:11:03.000000000 +0900
@@ -967,11 +967,14 @@ static int addend_mips_rel(struct elf_in
 	inst = TO_NATIVE(*location);
 	switch (r_typ) {
 	case R_MIPS_LO16:
-		r->r_addend = ((inst & 0xffff) ^ 0x8000) - 0x8000;
+		r->r_addend = inst & 0xffff;
 		break;
 	case R_MIPS_26:
 		r->r_addend = (inst & 0x03ffffff) << 2;
 		break;
+	case R_MIPS_32:
+		r->r_addend = inst;
+		break;
 	}
 	return 0;
 }
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ