From: chas williams <chas@cmf.nrl.navy.mil>
To: linux-ia64@vger.kernel.org
Subject: [Linux-ia64] still patching syscall into module
Date: Tue, 31 Jul 2001 10:57:15 +0000 [thread overview]
Message-ID: <marc-linux-ia64-105590693005967@msgid-missing> (raw)
i solved my problem for the time being by linking directly with the
kernel. i am again looking at trying to make patch the syscall
table to call a module.
the following does what i want:
GLOBAL_ENTRY(afs_syscall)
movl r15=0xa0000000001749e0;;
ld8 r16=[r15],8
mov r14=gp;;
ld8 gp=[r15]
mov b6=r16;;
br.few b6
END(afs_syscall)
however, its rather inconvenient to use 0xa0000000001749e0 since the
correct value changes somewhat. normally i suspect one would write:
addl r15=@ltoff(@fptr(real_afs_syscall#)),gp
but this would be wrong in this case since when the syscall occurred
i would using the kernel's gp and not the module's gp. so i thought
i would write:
.globl afs_syscall_fptr
afs_syscall_fptr:
data8 0x0
data8 0x0
GLOBAL_ENTRY(afs_syscall)
movl r15¯s_syscall_fptr
and the module could fill in afs_syscall_fptr during init. when i load
this though i get the following:
insmod: obj_ia64.c:258: obj_ia64_ins_imm64: Assertion `slot = 1' failed.
after looking the modutil code i guess that insmod is unable to insert
the relocation for my 64-bit absolute reference? how should i write this?
next reply other threads:[~2001-07-31 10:57 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-07-31 10:57 chas williams [this message]
2001-08-01 11:43 ` [Linux-ia64] still patching syscall into module chas williams
2001-08-01 20:59 ` chas williams
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=marc-linux-ia64-105590693005967@msgid-missing \
--to=chas@cmf.nrl.navy.mil \
--cc=linux-ia64@vger.kernel.org \
/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.