
Tell me, on the x86 architecture, can a program (operating system kernel, application, machine virtualiser, whatever else...) keep a another piece of code from calling the BIOS and deal with this attempted call and call some other function instead?
for example, a virtual machine runs a program which wants to find out how much memory is available. It calls INT 12 which puts this info into AX. But the virtualiser doesn't want to devote all the RAM to this vm, so how can it prevent this from happening?