From: Franck Bui-Huu <vagabon.xyz@gmail.com>
To: Thiemo Seufer <ths@networkno.de>
Cc: Ralf Baechle <ralf@linux-mips.org>,
linux-mips <linux-mips@linux-mips.org>
Subject: Re: [PATCH] Introduce __fill_user() and kill __bzero()
Date: Wed, 14 Nov 2007 09:24:22 +0100 [thread overview]
Message-ID: <473AB0B6.2070208@gmail.com> (raw)
In-Reply-To: <20071111130130.GB8363@networkno.de>
Thiemo Seufer wrote:
> Franck Bui-Huu wrote:
>> /*
>> - * memset(void *s, int c, size_t n)
>> + * An outline version of memset, which should be used either by gcc or
>> + * by assembly code.
>> + */
>> +NESTED(memset, 24, ra)
>> + PTR_ADDU sp, sp, -24
>> + LONG_S a0, 16(sp)
>> + LONG_S ra, 20(sp)
>> + jal __fill_user
>> + LONG_L v0, 16(sp)
>> + LONG_L ra, 20(sp)
>> + PTR_ADDU sp, sp, 24
>> + jr ra
>> +END(memset)
>
> This will break on 64bit kernels.
>
Is the following correct ?
NESTED(memset, 16, ra)
PTR_ADDU sp, sp, -16
LONG_S a0, 8(sp)
LONG_S ra, 16(sp)
jal __fill_user
LONG_L v0, 8(sp)
LONG_L ra, 16(sp)
PTR_ADDU sp, sp, 16
jr ra
END(memset)
I know it doesn't respect any mips ABI but in this case do
we really care ?
thanks.
Franck
next prev parent reply other threads:[~2007-11-14 8:26 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-11 8:48 [PATCH] Introduce __fill_user() and kill __bzero() Franck Bui-Huu
2007-11-11 13:01 ` Thiemo Seufer
2007-11-11 13:57 ` Franck Bui-Huu
2007-11-14 8:24 ` Franck Bui-Huu [this message]
2007-11-14 11:58 ` Thiemo Seufer
2007-11-14 12:34 ` Franck Bui-Huu
2007-11-14 13:48 ` Thiemo Seufer
2007-11-14 15:13 ` Franck Bui-Huu
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=473AB0B6.2070208@gmail.com \
--to=vagabon.xyz@gmail.com \
--cc=linux-mips@linux-mips.org \
--cc=ralf@linux-mips.org \
--cc=ths@networkno.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.