This is the mail archive of the libc-ports@sources.redhat.com mailing list for the libc-ports project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Add ARM auditing support


This patch, with my previous patch for the architecture-independent bits,
allows tst-audit1 to pass for arm-none-linux-gnu.  This is the first of
three ARM patches needed to build HEAD glibc.

OK to apply?

Phil, for now I'm going to assume you'd still prefer to approve ARM patches. 
If you'd rather I just applied them myself, let me know.

-- 
Daniel Jacobowitz
CodeSourcery, LLC

2005-10-05  Daniel Jacobowitz  <dan@codesourcery.com>

	* sysdeps/arm/dl-machine.h (ARCH_LA_PLTENTER,
	ARCH_LA_PLTEXIT): Define.
	* sysdeps/arm/ldsodefs.h, sysdeps/arm/tst-audit.h: New files.

Index: glibc/ports/sysdeps/arm/dl-machine.h
===================================================================
--- glibc.orig/ports/sysdeps/arm/dl-machine.h	2005-10-03 18:16:19.000000000 -0400
+++ glibc/ports/sysdeps/arm/dl-machine.h	2005-10-05 11:38:06.000000000 -0400
@@ -243,6 +243,10 @@ elf_machine_plt_value (struct link_map *
    Prelinked libraries may use Elf32_Rela though.  */
 #define ELF_MACHINE_NO_RELA defined RTLD_BOOTSTRAP
 
+/* Names of the architecture-specific auditing callback functions.  */
+#define ARCH_LA_PLTENTER arm_gnu_pltenter
+#define ARCH_LA_PLTEXIT arm_gnu_pltexit
+
 #ifdef RESOLVE_MAP
 
 /* Deal with an out-of-range PC24 reloc.  */
Index: glibc/ports/sysdeps/arm/ldsodefs.h
===================================================================
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
+++ glibc/ports/sysdeps/arm/ldsodefs.h	2005-10-05 11:39:03.000000000 -0400
@@ -0,0 +1,41 @@
+/* Run-time dynamic linker data structures for loaded ELF shared objects.
+   Copyright (C) 2005 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, write to the Free
+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+   02111-1307 USA.  */
+
+#ifndef _ARM_LDSODEFS_H
+#define _ARM_LDSODEFS_H 1
+
+#include <elf.h>
+
+struct La_arm_regs;
+struct La_arm_retval;
+
+#define ARCH_PLTENTER_MEMBERS \
+    Elf32_Addr (*arm_gnu_pltenter) (Elf32_Sym *, unsigned int, uintptr_t *,  \
+				    uintptr_t *, struct La_arm_regs *,	     \
+				    unsigned int *, const char *,	     \
+				    long int *)
+
+#define ARCH_PLTEXIT_MEMBERS \
+    Elf32_Addr (*arm_gnu_pltexit) (Elf32_Sym *, unsigned int, uintptr_t *,   \
+				   uintptr_t *, struct La_arm_regs *,	     \
+				   struct La_arm_retval *, const char *)
+
+#include_next <ldsodefs.h>
+
+#endif
Index: glibc/ports/sysdeps/arm/tst-audit.h
===================================================================
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
+++ glibc/ports/sysdeps/arm/tst-audit.h	2005-10-05 11:38:28.000000000 -0400
@@ -0,0 +1,26 @@
+/* Definitions for testing PLT entry/exit auditing.  ARM version.
+
+   Copyright (C) 2005 Free Software Foundation, Inc.
+
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, write to the Free
+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+   02111-1307 USA.  */
+
+#define pltenter la_arm_gnu_pltenter
+#define pltexit la_arm_gnu_pltexit
+#define La_regs La_arm_regs
+#define La_retval La_arm_retval
+#define int_retval lrv_reg[0]


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]