Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 1 May 2020 16:47:54 +0000 (UTC)
From:      Brandon Bergren <bdragon@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r360536 - head/stand/common
Message-ID:  <202005011647.041GlsY9020886@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bdragon
Date: Fri May  1 16:47:54 2020
New Revision: 360536
URL: https://svnweb.freebsd.org/changeset/base/360536

Log:
  Remove sparc relocation support from reloc_elf.c.
  
  It got missed in the sparc64 removal.

Modified:
  head/stand/common/reloc_elf.c

Modified: head/stand/common/reloc_elf.c
==============================================================================
--- head/stand/common/reloc_elf.c	Fri May  1 14:30:59 2020	(r360535)
+++ head/stand/common/reloc_elf.c	Fri May  1 16:47:54 2020	(r360536)
@@ -52,32 +52,7 @@ int
 __elfN(reloc)(struct elf_file *ef, symaddr_fn *symaddr, const void *reldata,
     int reltype, Elf_Addr relbase, Elf_Addr dataaddr, void *data, size_t len)
 {
-#ifdef __sparc__
-	Elf_Size w;
-	const Elf_Rela *a;
-
-	switch (reltype) {
-	case ELF_RELOC_RELA:
-		a = reldata;
-		 if (relbase + a->r_offset >= dataaddr &&
-		     relbase + a->r_offset < dataaddr + len) {
-			switch (ELF_R_TYPE(a->r_info)) {
-			case R_SPARC_RELATIVE:
-				w = relbase + a->r_addend;
-				bcopy(&w, (u_char *)data + (relbase +
-				    a->r_offset - dataaddr), sizeof(w));
-				break;
-			default:
-				printf("\nunhandled relocation type %u\n",
-				    (u_int)ELF_R_TYPE(a->r_info));
-				return (EFTYPE);
-			}
-		}
-		break;
-	}
-
-	return (0);
-#elif (defined(__i386__) || defined(__amd64__)) && __ELF_WORD_SIZE == 64
+#if (defined(__i386__) || defined(__amd64__)) && __ELF_WORD_SIZE == 64
 	Elf64_Addr *where, val;
 	Elf_Addr addend, addr;
 	Elf_Size rtype, symidx;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202005011647.041GlsY9020886>