qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] syscall uselib
@ 2007-02-19 13:44 Kirill A. Shutemov
  2007-02-19 14:20 ` Kirill A. Shutemov
  0 siblings, 1 reply; 2+ messages in thread
From: Kirill A. Shutemov @ 2007-02-19 13:44 UTC (permalink / raw)
  To: qemu-devel

[-- Attachment #1: Type: text/plain, Size: 138 bytes --]

Fixed Debian patch in the attachment. uselib is deprecated, but I think it
should be implemented by qemu, because it's in the kernel yet.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] [PATCH] syscall uselib
  2007-02-19 13:44 [Qemu-devel] [PATCH] syscall uselib Kirill A. Shutemov
@ 2007-02-19 14:20 ` Kirill A. Shutemov
  0 siblings, 0 replies; 2+ messages in thread
From: Kirill A. Shutemov @ 2007-02-19 14:20 UTC (permalink / raw)
  To: qemu-devel


[-- Attachment #1.1: Type: text/plain, Size: 214 bytes --]

On [Mon, 19.02.2007 16:44], Kirill A. Shutemov wrote:
> Fixed Debian patch in the attachment. uselib is deprecated, but I think it
> should be implemented by qemu, because it's in the kernel yet.

Sorry, attached.

[-- Attachment #1.2: 31_syscall_uselib.patch --]
[-- Type: text/plain, Size: 808 bytes --]

--- linux-user/syscall.c.orig	2006-11-05 07:07:19.000000000 +0200
+++ linux-user/syscall.c	2006-11-05 07:07:25.000000000 +0200
@@ -173,6 +175,7 @@ extern int getresuid(uid_t *, uid_t *, u
 extern int setresgid(gid_t, gid_t, gid_t);
 extern int getresgid(gid_t *, gid_t *, gid_t *);
 extern int setgroups(int, gid_t *);
+extern int uselib(const char*);
 
 static inline long get_errno(long ret)
 {
@@ -2742,7 +2745,11 @@ long do_syscall(void *cpu_env, int num, 
         }
         break;
     case TARGET_NR_uselib:
-        goto unimplemented;
+        p = lock_user_string(arg1);
+        ret = get_errno(uselib(path(p)));
+        unlock_user(p, arg1, 0);
+        break;
+
     case TARGET_NR_swapon:
         p = lock_user_string(arg1);
         ret = get_errno(swapon(p, arg2));

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-02-19 15:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-02-19 13:44 [Qemu-devel] [PATCH] syscall uselib Kirill A. Shutemov
2007-02-19 14:20 ` Kirill A. Shutemov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).