Re: Segmentation fault with outb()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Timur Tabi wrote:

Raja.Hayek@xxxxxxxxxxxxxx wrote:

I know that similar code works in module form, whereby I insmod the module, and set up my ports using in the init_module() function. Here, however, I am trying to build it into a regular executable. But is that the reason?


Yes. This is basic x86 stuff, not related to Linux at all. You can't execute I/O instructions in user space.

Yes, you can execute I/O instructions in user space through the outb/inb functions and by including the header sys/io.h
man ioperm
man iopl


Bill



--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux