tux in Fedora Core
Alex Kiernan
alex.kiernan at thus.net
Tue Apr 13 15:51:51 UTC 2004
Dave Jones <davej at redhat.com> writes:
> On Tue, 2004-04-13 at 10:05, Alex Kiernan wrote:
> > Is tux in or out of FC?
> >
> > https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=115418
>
> That was somewhat premature. It was included in FC2 kernel about the
> same time that someone nuked the userspace package 8-) It then got
> reinstated afaik.
>
So its in, for now?
> > doesn't seem to make things clearer (I'm assuming that rawhide is what
> > will become RHEL?)
>
> rawhide == what will be Fedora Core 2.
>
Ah ta.
> > I've patched up kernel-2.6.5-1.315 to support tux on x86-64, but I'm
> > not sure whether I should put patches in bugzilla for FC or send them
> > onto the tux mailing list.
>
> *puzzled*, that kernel should already have tux patched in.
>
It does, its just the glue to enable it on x86_64 which is missing -
this is what I'm using (which seems to work, but may be hopelessly
wrong as this is the first I've ever looked at the x86_64 kernel):
diff -ur kernel-2.6.5.redhat/linux-2.6.5/arch/x86_64/kernel/x8664_ksyms.c kernel-2.6.5/linux-2.6.5/arch/x86_64/kernel/x8664_ksyms.c
--- kernel-2.6.5.redhat/linux-2.6.5/arch/x86_64/kernel/x8664_ksyms.c 2004-04-11 18:53:12.000000000 +0100
+++ kernel-2.6.5/linux-2.6.5/arch/x86_64/kernel/x8664_ksyms.c 2004-04-13 04:51:20.506994864 +0100
@@ -30,6 +30,7 @@
#include <asm/pgalloc.h>
#include <asm/nmi.h>
#include <asm/kdebug.h>
+#define __KERNEL_SYSCALLS__
#include <asm/unistd.h>
#include <asm/delay.h>
#include <asm/tlbflush.h>
@@ -226,3 +227,8 @@
EXPORT_SYMBOL(memcpy_toio);
EXPORT_SYMBOL(memcpy_fromio);
+
+EXPORT_SYMBOL(execve);
+EXPORT_SYMBOL(sys_write);
+EXPORT_SYMBOL(sys_chroot);
+EXPORT_SYMBOL(sys_chdir);
diff -ur kernel-2.6.5.redhat/linux-2.6.5/include/asm-x86_64/unistd.h kernel-2.6.5/linux-2.6.5/include/asm-x86_64/unistd.h
--- kernel-2.6.5.redhat/linux-2.6.5/include/asm-x86_64/unistd.h 2004-04-04 04:37:36.000000000 +0100
+++ kernel-2.6.5/linux-2.6.5/include/asm-x86_64/unistd.h 2004-04-12 16:13:34.000000000 +0100
@@ -424,7 +424,13 @@
__SYSCALL(__NR_afs_syscall, sys_ni_syscall)
#define __NR_tuxcall 184 /* reserved for tux */
+#ifdef CONFIG_TUX
+__SYSCALL(__NR_tuxcall, __sys_tux)
+#elif defined(CONFIG_TUX_MODULE)
+__SYSCALL(__NR_tuxcall, sys_tux)
+#else
__SYSCALL(__NR_tuxcall, sys_ni_syscall)
+#endif
#define __NR_security 185
__SYSCALL(__NR_security, sys_ni_syscall)
@@ -542,6 +548,7 @@
#define __syscall_clobber "r11","rcx","memory"
+#ifndef __KERNEL_SYSCALLS_NO_ERRNO__
#define __syscall_return(type, res) \
do { \
if ((unsigned long)(res) >= (unsigned long)(-127)) { \
@@ -550,6 +557,9 @@
} \
return (type) (res); \
} while (0)
+#else
+# define __syscall_return(type, res) return (type) (res)
+#endif
#ifndef __KERNEL_SYSCALLS__
@@ -696,6 +706,16 @@
return sys_wait4(pid, wait_stat, flags, NULL);
}
+static inline long chroot(const char *filename)
+{
+ return sys_chroot(filename);
+}
+
+static inline long chdir(const char *filename)
+{
+ return sys_chdir(filename);
+}
+
extern long sys_mmap(unsigned long addr, unsigned long len,
unsigned long prot, unsigned long flags,
unsigned long fd, unsigned long off);
--
Alex Kiernan, Principal Engineer, Development, THUS plc
More information about the fedora-devel-list
mailing list