Ilan Finci wrote:


Calling mmap from the user application returns an address, but trying to access this address, yields an error message:

do_wp_page: bogus page at address 30027024 (page 0xc23358e0)
VM: killing process testSram


(0x30027000 is the address that mmap returned, and I tried to access 24 bytes after this. I've mapped 0x40000 bytes, so there shouldn't be a problem).



In the flags to the mmap call replace MAP_PRIVATE (or 0) with MAP_SHARED. The kernel is trying to do copy on write for your pages (hence the name of function in the error message - do_ write protect _page) and that's not going to work with what you are trying to do.


You owe the wizard a pogo stick :-)

Gilad


-- Gilad Ben-Yossef <[EMAIL PROTECTED]> Codefidence. A name you can trust(tm) Web: http://codefidence.com | SIP: [EMAIL PROTECTED] Tel: +972.9.8650475 ext. 201 | Fax: +972.9.8850643

"I am Jack's Overwritten Stack Pointer"
        -- Hackers Club, the movie

=================================================================
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]



Reply via email to