From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22225 invoked by alias); 1 Aug 2012 18:43:53 -0000 Received: (qmail 22216 invoked by uid 22791); 1 Aug 2012 18:43:52 -0000 X-SWARE-Spam-Status: No, hits=-2.2 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from toast.topped-with-meat.com (HELO topped-with-meat.com) (204.197.218.159) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 01 Aug 2012 18:43:39 +0000 Received: by topped-with-meat.com (Postfix, from userid 5281) id 4990A2C0B6; Wed, 1 Aug 2012 11:43:38 -0700 (PDT) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit From: Roland McGrath To: libc-ports@sourceware.org Subject: [PATCH roland/arm-dl-machine-clear-cache] Move Linuxism out of sysdeps/arm/dl-machine.h Message-Id: <20120801184338.4990A2C0B6@topped-with-meat.com> Date: Wed, 01 Aug 2012 18:43:00 -0000 X-CMAE-Score: 0 X-CMAE-Analysis: v=2.0 cv=e8d9udV/ c=1 sm=1 a=qkMy17MtLyUA:10 a=Z6MIti7PxpgA:10 a=kj9zAlcOel0A:10 a=hOe2yjtxAAAA:8 a=14OXPxybAAAA:8 a=mDV3o1hIAAAA:8 a=pV6f4guGUDNXB9pWeX8A:9 a=CjuIK1q_8ugA:10 a=WkljmVdYkabdwxfqvArNOQ==:117 X-IsSubscribed: yes Mailing-List: contact libc-ports-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: libc-ports-owner@sourceware.org X-SW-Source: 2012-08/txt/msg00003.txt.bz2 A sysdeps/MACHINE file should not have anything that is OS-specific in it. Ok? (Just merge my branch if you like, or I can do it on approval.) Thanks, Roland ports/ChangeLog.arm 2012-08-01 Roland McGrath * sysdeps/arm/dl-machine.h (CLEAR_CACHE): Don't define it. Instead, #error if it's not defined. * sysdeps/unix/sysv/linux/arm/dl-machine.h: New file. diff --git a/ports/sysdeps/arm/dl-machine.h b/ports/sysdeps/arm/dl-machine.h index 8d905e8..442fc3d 100644 --- a/ports/sysdeps/arm/dl-machine.h +++ b/ports/sysdeps/arm/dl-machine.h @@ -1,6 +1,5 @@ /* Machine-dependent ELF dynamic relocation inline functions. ARM version. - Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005, - 2006, 2009, 2010, 2011 Free Software Foundation, Inc. + Copyright (C) 1995-2012 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 @@ -27,8 +26,9 @@ #include #include -#define CLEAR_CACHE(BEG,END) \ - INTERNAL_SYSCALL_ARM (cacheflush, , 3, (BEG), (END), 0) +#ifndef CLEAR_CACHE +# error CLEAR_CACHE definition required to handle TEXTREL +#endif /* Return nonzero iff ELF header is compatible with the running host. */ static inline int __attribute__ ((unused)) diff --git a/ports/sysdeps/unix/sysv/linux/arm/dl-machine.h b/ports/sysdeps/unix/sysv/linux/arm/dl-machine.h new file mode 100644 index 0000000..7c96cb7 --- /dev/null +++ b/ports/sysdeps/unix/sysv/linux/arm/dl-machine.h @@ -0,0 +1,28 @@ +/* Machine-dependent ELF dynamic relocation inline functions. ARM/Linux version + Copyright (C) 1995-2012 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, see + . */ + +#ifndef dl_machine_h + +/* This definition is Linux-specific. */ +#define CLEAR_CACHE(BEG,END) \ + INTERNAL_SYSCALL_ARM (cacheflush, , 3, (BEG), (END), 0) + +/* The rest is just machine-specific. */ +#include + +#endif