virtual-address-space

Why is the ELF execution entry point virtual address of the form 0x80xxxxx and not zero 0x0?

吃可爱长大的小学妹 提交于 2019-11-26 05:29:43
问题 When executed, program will start running from virtual address 0x80482c0. This address doesn\'t point to our main() procedure, but to a procedure named _start which is created by the linker. My Google research so far just led me to some (vague) historical speculations like this: There is folklore that 0x08048000 once was STACK_TOP (that is, the stack grew downwards from near 0x08048000 towards 0) on a port of *NIX to i386 that was promulgated by a group from Santa Cruz, California. This was

Is there any API for determining the physical address from virtual address in Linux?

懵懂的女人 提交于 2019-11-26 03:57:40
问题 Is there any API for determining the physical address from virtual address in Linux operating system? 回答1: Kernel and user space work with virtual addresses (also called linear addresses) that are mapped to physical addresses by the memory management hardware. This mapping is defined by page tables, set up by the operating system. DMA devices use bus addresses. On an i386 PC, bus addresses are the same as physical addresses, but other architectures may have special address mapping hardware to