From mboxrd@z Thu Jan 1 00:00:00 1970 From: sengottuvelan.s@gmail.com (Sengottuvelan S) Date: Sun, 3 Apr 2011 10:11:22 -0700 Subject: i/o opening error for PCI access Message-ID: To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org Hi All, I am trying to access /dev/mem in my user process. I could not access because not a privileged access. I tried to use iopl(3) call in linux 2.6, but i am getting unresolved symbol for this. Is any other way to get access in user process. I am not sure how to solve this. Can you someone throw some light on this. if(iopl(3)){ fprintf(stderr, "Cannot get I/O permissions (being root helps)"); return -1; } if ((fd = open("/dev/mem", O_RDWR | O_SYNC)) < 0) { fprintf(stderr, "Failed to open /dev/mem"); return -1; } -- Regards, S. Sengottuvelan. -- Regards, S. Sengottuvelan. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20110403/1fb65255/attachment.html