Function - Permit target thread to invoke operations on the specified device.
kern_return_t i386_io_port_add (thread_act_t target_act, device_t device);
The i386_io_port_add function adds a device to the I/O permission bitmap for a thread, thereby permitting the thread to execute I/O instructions against the device.
Normally, the thread must have called i386_io_port_add for all devices to which it will execute I/O instructions. However, possessing send rights to the iopl device port will cause the iopl device to be automatically added to the thread's I/O map upon first attempted access. This is a backward compatibility feature for the DOS emulator.
Only generic errors apply.
Functions: i386_io_port_list, i386_io_port_remove.