Enable or disable expansion ROM
Synopsis:
#include <pci/pci.h>
pci_err_t pci_device_rom_disable( pci_devhdl_t hdl );
pci_err_t pci_device_rom_enable( pci_devhdl_t hdl );
Library:
libpci
Use the -l pci option to
qcc
to link against this library.
Description:
The pci_device_rom_enable() and pci_device_rom_disable() functions
enable and disable a device's expansion ROM, respectively.
It's your responsibility to enable the Memory Access bit in the command register.
Returns:
- PCI_ERR_OK
- Success.
- PCI_ERR_ENODEV
- The device identified by hdl doesn't exist.
Note that this error can also be returned if a device that supports live removal is removed after a successful
call to
pci_device_find().
- PCI_ERR_ENOTSUP
- One of the following occurred:
- The device identified by hdl isn't supported.
- There are no expansion ROM entries for the device.
- PCI_ERR_EINVAL
- The hdl doesn't refer to a valid device that you attached to, or other parameters
are otherwise invalid.
This error can also be returned from the hardware-dependent module.
- PCI_ERR_NOT_OWNER
- You aren't the owner of the device; see
pci_device_attach().
- PCI_ERR_ASPACE_INVALID
- The base addresses assigned to the device couldn't be translated into usable values for you.
This is generally a hardware-dependent module error.
- PCI_ERR_EIO
- A device-specific error occurred.
-
-
Classification:
QNX Neutrino
Safety: |
|
Cancellation point |
No |
Interrupt handler |
No |
Signal handler |
No |
Thread |
Yes |