【问题标题】:Unable to find syscall_table_32.S file in linux在 linux 中找不到 syscall_table_32.S 文件
【发布时间】:2013-01-26 04:55:46
【问题描述】:

我在虚拟机上使用linux-headers-2.6.32-21 包。我要写一个新的系统调用。我找到了其他文件来编写系统调用的缩写,但我无法在arch/x86/kernel/ 目录中找到这个syscall_table_32.S。请帮助我如何以及在哪里可以找到此文件。我怀疑它可能由于权限问题或其他原因而被隐藏。

【问题讨论】:

    标签: linux linux-kernel system-calls archlinux


    【解决方案1】:

    以下提交将其删除:

    commit 303395ac3bf3e2cb488435537d416bc840438fcb
    Author: H. Peter Anvin <hpa@linux.intel.com>
    Date:   Fri Nov 11 16:07:41 2011 -0800
    
        x86: Generate system call tables and unistd_*.h from tables
    
        Generate system call tables and unistd_*.h automatically from the
        tables in arch/x86/syscalls.  All other information, like NR_syscalls,
        is auto-generated, some of which is in asm-offsets_*.c.
    
        This allows us to keep all the system call information in one place,
        and allows for kernel space and user space to see different
        information; this is currently used for the ia32 system call numbers
        when building the 64-bit kernel, but will be used by the x32 ABI in
        the near future.
    
        This also removes some gratuitious differences between i386, x86-64
        and ia32; in particular, now all system call tables are generated with
        the same mechanism.
    

    因为现在系统调用表是由脚本 arch/x86/syscalls/syscalltbl.sh 生成的,基于 arch/x86/syscalls/syscall_{32,64}.tbl。

    【讨论】:

    • 对不起@Cong Wang ,我没有得到你。请简单地指导我在哪里可以找到 syscall_table_32.S 文件来放置我的代码。 :(
    • 哪里难懂? syscall_table_32.S 已删除,如果需要,请修补 arch/x86/syscalls/syscall_{32,64}.tbl。
    • x86/ 目录下没有文件夹 syscalls/。 :(
    • % ls arch/x86/syscalls Makefile syscall_32.tbl syscall_64.tbl syscallhdr.sh syscalltbl.sh
    • 我在 x86 中没有 syscalls 文件夹。
    【解决方案2】:

    /usr/src/kernels/3.3.4-5.fc17.i686.PAE/arch/x86/include/generated/asm

    您可以在此处获取 syscalls_32.h。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-08-19
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2017-04-08
      • 1970-01-01
      相关资源
      最近更新 更多