[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200612111152.56945.dada1@cosmosbay.com>
Date: Mon, 11 Dec 2006 11:52:56 +0100
From: Eric Dumazet <dada1@...mosbay.com>
To: Andrew Morton <akpm@...l.org>
Cc: Andi Kleen <ak@...e.de>,
linux-kernel <linux-kernel@...r.kernel.org>
Subject: [PATCH] get rid of ARCH_HAVE_XTIME_LOCK
As suggested by Andrew, we can use __attribute__((weak)) to get rid of
ARCH_HAVE_XTIME_LOCK
Please note I compiled, and boot tested on ia32 this patch, and it seems OK.
I compiled on x86_64 and got same resulting vmlinux image.
But I suspect some tools might have problems because vmlinux have its
first 'weak data symbol' defined. AFAIK __attribute__((weak)) was only used
on text symbols.
# nm vmlinux | grep ' V '
c03b01c0 V xtime_lock
[PATCH] get rid of ARCH_HAVE_XTIME_LOCK
ARCH_HAVE_XTIME_LOCK is used by x86_64 arch . This arch needs to place a read
only copy of xtime_lock into vsyscall page. This read only copy is named
__xtime_lock, and xtime_lock is defined in arch/x86_64/kernel/vmlinux.lds.S
as an alias. So the declaration of xtime_lock in kernel/timer.c was guarded
by ARCH_HAVE_XTIME_LOCK define, defined to true on x86_64.
We can get same result with _attribute__((weak)) in the declaration. linker
should do the job.
Signed-off-by: Eric Dumazet <dada1@...mosbay.com>
View attachment "ARCH_HAVE_XTIME_LOCK.patch" of type "text/plain" (1424 bytes)
Powered by blists - more mailing lists