【问题标题】:Systemcalls that does not exist in systemcall table系统调用表中不存在的系统调用
【发布时间】:2013-11-10 03:08:18
【问题描述】:

我在 Fedora 16(32 位)中使用 STrace 跟踪了一些程序,并且我正在编写一些 python 脚本来解析这些跟踪。我从 Fedora 中获得了所有系统调用及其相关号码 arch/x86/include/asm/unistd_32.h

但是最后我发现了一些在这个表中不存在的系统调用,我想知道
1. 怎么可能?
2. 我应该如何为这些系统调用分配一个编号?

这是其中的一些系统调用:

set_th3_area (set_thread_area) 套接字(socketcall)
发送消息 (sendmmsg)
连接
绑定 (mbind)
获取套接字名称
发送至 recvmsg (recvmmsg)

其中一些在上面列表中的括号中具有类似的系统调用。

更新:我发现大部分都存在于 net/socket.c 中

int sys_socketcall(int call, unsigned long *args)

int sys_socket(int family, int type, int protocol) int sys_socketpair(int family, int type, int protocol, int usockvec[2])
...

但我仍然无法为这些分配一个数字...
最后我需要一个系统调用号序列

【问题讨论】:

    标签: linux linux-kernel fedora system-calls 32-bit


    【解决方案1】:

    我终于从 STrace 源代码中获得了完整的系统调用列表!

    http://sourceforge.net/p/strace/code/ci/master/tree/linux/i386/syscallent.h

    这解决了我的问题。一个有趣的问题是 set_thread_area 首先是由 "thread" 中的 "read" 翻译的,这就是我有 set_th3_area 的原因。

    【讨论】:

      猜你喜欢
      • 2014-12-25
      • 2016-02-09
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-04-27
      • 1970-01-01
      • 2015-01-02
      • 2014-11-21
      相关资源
      最近更新 更多