public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrea Arcangeli <andrea@suse.de>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: Prasad <prasad_s@students.iiit.net>, lkml <linux-kernel@vger.kernel.org>
Subject: Re: Syscall from Kernel Space
Date: Thu, 20 Feb 2003 23:45:32 +0100	[thread overview]
Message-ID: <20030220224532.GE31480@x30.school.suse.de> (raw)
In-Reply-To: <20030220221730.GS9800@gtf.org>

On Thu, Feb 20, 2003 at 05:17:30PM -0500, Jeff Garzik wrote:
> On Thu, Feb 20, 2003 at 11:10:27PM +0100, Andrea Arcangeli wrote:
> > On Thu, Feb 20, 2003 at 12:40:43PM -0500, Jeff Garzik wrote:
> > > On Thu, Feb 20, 2003 at 11:04:37PM +0530, Prasad wrote:
> > > > 	Is there a way using which i could invoke a syscall in the kernel 
> > > > space?  The syscall is to be run disguised as another process.  The actual 
> > > 
> > > Call sys_<syscall>.  Look at the kernel code for examples.
> > > 
> > > Note that typically you don't want to do this... and you _really_ don't
> > > want to do this if the syscall is not one of the common file I/O
> > > syscalls (read/write/open/close, etc.)
> > 
> > you never want to do this, the only point of a syscall is to enter
> > kernel, if you're just in kernel you're wasting time in calling the
> > syscall (not to tell about the new non soft interrupt based syscall
> > instructions, btw this is also why I rejected the int 0x81 thing on
> > x86-64 for 64bit syscalls)
> 
> He is talking about directly calling the function behind the syscall,
> not actually executing a syscall itself.

this is not what I understood from your previous discussion also given
you suggest not to do that when he can call sys_read/sys_write instead
because they're just exported etc.. I just wanted to add a better
"never".

> syscalls should be made from userspace, not the kernel.

This is what I tried to say.

Andrea

  reply	other threads:[~2003-02-20 22:37 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-20 17:34 Syscall from Kernel Space Prasad
2003-02-20 17:40 ` Jeff Garzik
2003-02-20 17:49   ` Prasad
2003-02-20 22:10   ` Andrea Arcangeli
2003-02-20 22:17     ` Jeff Garzik
2003-02-20 22:45       ` Andrea Arcangeli [this message]
2003-02-21  4:39         ` Remote execution of syscalls (was Re: Syscall from Kernel Space) Prasad
2003-02-21 17:44           ` Livio Baldini Soares
2003-02-21 18:01             ` Prasad
2003-02-23 22:52               ` Pavel Machek
2003-02-25  1:34               ` H. Peter Anvin
2003-02-25  3:57                 ` Prasad

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030220224532.GE31480@x30.school.suse.de \
    --to=andrea@suse.de \
    --cc=jgarzik@pobox.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=prasad_s@students.iiit.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox