有没有办法以编程方式获取当前系统上存在的所有 BIOS 中断列表? [英] Is there a way to get the list of all BIOS interrupts present on the current system programmatically?

查看:33
本文介绍了有没有办法以编程方式获取当前系统上存在的所有 BIOS 中断列表?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在查找我的 PC 提供的 BIOS 中断列表.

I'm looking for a list of BIOS interrupts supplied by my PC.

为了获得最常见的 BIOS 调用,有各种公共资源,但我希望能列出我的 PC 的所有(可能不是非常公开的)BIOS 调用.

To get the most common BIOS calls, there are various public resources, but I was hoping for a list of all (possibly not very public) BIOS calls for my PC.

有没有程序可以做到这一点,或者我可以用任何方式编写一个程序(最好用汇编或 C)?

Is there a program to do this, or any way I could write one (preferably in assembly or C)?

我的目标是避免 BIOS 反汇编.我也知道 BIOS 的低级 API 相对相似,因此 API 调用列表也相似.

My goal is to avoid BIOS disassembling. I am also aware that BIOSes are relatively similar in their low-level API, and thus also the list of the API calls are similar.

推荐答案

"Ralf Brown 的中断列表" 可能对你有帮助.

"Ralf Brown's interrupt list" might be helpful for you.

该站点列出了 x86 系统上常用的大多数中断:

That site lists most interrupts commonly used on x86 systems:

不仅列出了BIOS中断,还列出了MS-DOS中断和常用程序使用的中断.这包括一个列出 Linux 系统调用(中断 0x80)的部分.

Not only BIOS interrupts are listed, but also MS-DOS interrupts and interrupts used by common programs. This includes a section listing Linux system calls (interrupt 0x80).

... 即请不要包含...

... i.e. please don't include ...

不幸的是,您必须将常见"BIOS 中断、仅存在于某些 BIOS 中的中断和自己的 MS-DOS 中断分开.

Unfortunately, you will have to separate "common" BIOS interrupts, interrupts only present in certain BIOSes and MS-DOS interrupts yourself.

但是,对于许多中断,列表中的内容类似于:仅存在于 Example Software Inc. 制造的 BIOS 中."

However, the for many interrupts the list says something like: "Only present in BIOSes made by Example Software Inc."

...我最近的编辑...

... my recent edit ...

如果我理解正确,您希望拥有某种 API 来告诉您某个系统上存在哪些中断.

If I understand you correctly, you want to have some kind of API that tells you which interrupts are present on a certain system.

不幸的是,这样的 API 不存在:

Unfortunately, such an API does not exist:

BIOS 不一定是一个软件.相反,某些硬件组件(例如显卡)可能有自己的固件.

The BIOS is not necessarily one single piece of software. Instead, some hardware components (such as a graphics card) may have their own firmware.

此类组件的固件通常没有自己的中断,但它可以通过更改中断向量来为 BIOS 中断添加功能.

The firmware of such a component typically doesn't have own interrupts, but it may add functionality to the BIOS interrupts by changing the interrupt vector.

显卡的固件可能会通过改变中断向量,在int 10h中添加一个函数AX=5678h,使其指向以下代码:>

The firmware of a graphics card may add a function AX=5678h to int 10h by changing the interrupt vector so it points to the following piece of code:

new_int_10_vector:
    cmp ax, 5678h
    je new_function

    ; (In reality, the next line is not as simple as shown here)
    jmp original_int_10_vector

new_function:
    ; Perform the "new" function "AX=5678h" of "int 10h"
    ; ...
    iret

如果现代 BIOS 供应商想要引入一个列出所有支持的功能(您正在寻找的功能)的功能,他们会遇到问题:

If modern BIOS suppliers wanted to introduce a function that lists all supported functions (the function you are looking for), they would have a problem:

BIOS应该如何检测到显卡的固件在int 10h中添加了附加功能AX=5678h?

How should the BIOS detect that the firmware of the graphics card adds the additional function AX=5678h to int 10h?

这篇关于有没有办法以编程方式获取当前系统上存在的所有 BIOS 中断列表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆