9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: cinap_lenrek@gmx.de
To: 9fans@9fans.net
Subject: Re: [9fans] mozilla on linuxemu3 gives "ulimit not implemented"
Date: Sat, 11 Jul 2009 22:27:58 +0200	[thread overview]
Message-ID: <f7516f5e5fdaebcc56d1279387ae1b67@gmx.de> (raw)
In-Reply-To: <b9fce3fb60ad3dc726e54b0ffaa2f113@9netics.com>

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

no, the syscall just returns -EIMPL because its not implemented... you can
run linuxemu with -d option wich will log all syscalls and other debugging
to strerr, or when something crashes attach acid to the broken process
with the linuxemu.acid file and run utrace(Current()) and look if we hit
unimplemented syscalls. but sys_ulimit() should be pretty harmless.

you can implement that syscall if you want. i should make a small tutorial
about how to add syscalls...

1. find out what the parameters of the syscall is (linuxassembly.org, lxr...)
2. add your syscall function prototype in fns.h like:

int sys_mysyscall(int arg1, void *arg2);

if structs are passed use void * and declare the struct near your
implementation and cast the void* in it. for some complicated syscalls
you can access the registers where arguments are passed in linux
with current->ureg->reg but it should be avoided. the automatic
convertion of syscalls to plan9 function passing allows the later
implementation of for example a bsd syscall emulator. (bsd uses
the traditional stack based argument passing)

3. add your syscalll to the linuxcalltab file like this:

123    2    mysyscall                         sys_mysyscall

the first column is the syscall number, the 2nd is the number of arguments
for the syscall function. the comes just a name and the last one is the
function that will be called.

4. implement your function somewhere

--
cinap

[-- Attachment #2: Type: message/rfc822, Size: 1984 bytes --]

From: Skip Tavakkolian <9nut@9netics.com>
To: 9fans@9fans.net
Subject: [9fans] mozilla on linuxemu3 gives "ulimit not implemented"
Date: Sat, 11 Jul 2009 11:16:31 -0700
Message-ID: <b9fce3fb60ad3dc726e54b0ffaa2f113@9netics.com>

i don't have the exact message; the machine is remote and currently
powered off.  is it my setup?

  reply	other threads:[~2009-07-11 20:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-11 18:16 Skip Tavakkolian
2009-07-11 20:27 ` cinap_lenrek [this message]
2009-07-11 21:42   ` Skip Tavakkolian
2009-07-11 22:50     ` cinap_lenrek
2009-07-11 23:41       ` Federico G. Benavento

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=f7516f5e5fdaebcc56d1279387ae1b67@gmx.de \
    --to=cinap_lenrek@gmx.de \
    --cc=9fans@9fans.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;
as well as URLs for NNTP newsgroup(s).