From: Christian B. <cb...@st...> - 2001-05-30 17:24:30
|
Hi! On Wed, May 23, 2001 at 10:41:45AM +1000, ni...@in... wrote: > Sure. What I actually meant was, what is this mmap() doing: > > RAMBaseHost = (uint8 *)mmap(0, mapped_ram_rom_size, > PROT_READ | PROT_WRITE, > MAP_PRIVATE, zero_fd, 0); > > So, how is this really any different to: > > RAMBaseHost = (uint8 *)malloc(mapped_ram_rom_size); Hm, at first glance I can't see the reason. It looks like gbeauchesne wrote that part (rev. 1.19 vs. 1.20 of that file); maybe he knows. Perhaps it simplifies some things by just having to munmap() the area when quitting istead of either munmap() or free()? Bye, Christian -- / Coding on PowerPC and proud of it \/ http://www.uni-mainz.de/~bauec002/ |