Previous Next

IO_RESOURCE_DESCRIPTOR

The IO_RESOURCE_DESCRIPTOR structure describes a range of raw hardware resources, of one type, that can be used by a device. An array of IO_RESOURCE_DESCRIPTOR structures is contained within each IO_RESOURCE_LIST structure.

typedef struct _IO_RESOURCE_DESCRIPTOR {
  UCHAR Option;
  UCHAR Type;
  UCHAR ShareDisposition;
  UCHAR Spare1;
  USHORT Flags;
  USHORT Spare2;
  union {
    struct {
      ULONG Length;
      ULONG Alignment;
      PHYSICAL_ADDRESS MinimumAddress;
      PHYSICAL_ADDRESS MaximumAddress;
    } Port;
    struct {
      ULONG Length;
      ULONG Alignment;
      PHYSICAL_ADDRESS MinimumAddress;
      PHYSICAL_ADDRESS MaximumAddress;
    } Memory;
    struct {
      ULONG MinimumVector;
      ULONG MaximumVector;
    } Interrupt;
    struct {
      ULONG MinimumChannel;
      ULONG MaximumChannel;
    } Dma;
    struct {
      ULONG Length;
      ULONG Alignment;
      PHYSICAL_ADDRESS MinimumAddress;
      PHYSICAL_ADDRESS MaximumAddress;
    } Generic;
    struct {
      ULONG Data[3];
    } DevicePrivate;
    struct {
      ULONG Length;
      ULONG MinBusNumber;
      ULONG MaxBusNumber;
      ULONG Reserved;
    } BusNumber;
    struct {
      ULONG Priority;
      ULONG Reserved1;
      ULONG Reserved2;
    } ConfigData;
  } u;
} IO_RESOURCE_DESCRIPTOR, *PIO_RESOURCE_DESCRIPTOR;

Members

Option
Specifies whether this resource description is required, preferred, or alternative. One of the following values must be used:
Value Definition
0
  The specified resource range is required, unless alternative ranges are also specified.
IO_RESOURCE_PREFERRED
  The specified resource range is preferred to any alternative ranges.
IO_RESOURCE_ALTERNATIVE
  The specified resource range is an alternative to the range preceding it. For example, if one IO_RESOURCE_DESCRIPTOR structure specifies IRQ 5, with IO_RESOURCE_PREFERRED set, and the next structure specifies IRQ 3, with IO_RESOURCE_ALTERNATIVE set, the PnP Manager assigns IRQ 3 to the device only if IRQ 5 is unavailable. (Multiple alternatives can be specified for each resource. Both IO_RESOURCE_ALTERNATIVE and IO_RESOURCE_PREFERRED can be set, indicating a preferred alternative.)
IO_RESOURCE_DEFAULT
  Not used.

Type
Identifies the resource type. For a list of valid values, see the Type member of the CM_PARTIAL_RESOURCE_DESCRIPTOR structure.
ShareDisposition
Indicates whether the described resource can be shared. For a list of valid values, see the ShareDisposition member of the CM_PARTIAL_RESOURCE_DESCRIPTOR structure.
Flags
Contains bit flags that are specific to the resource type. For a list of valid flags, see the Flags member of the CM_PARTIAL_RESOURCE_DESCRIPTOR structure.
u.Port
Specifies a range of I/O port addresses, using the following members:
Length
The length, in bytes, of the range of assignable I/O port addresses.
Alignment
The alignment, in bytes, that the assigned starting address must adhere to. The assigned starting address must be devisable by Alignment.
MinimumAddress
The minimum bus-relative I/O port address that can be assigned to the device
MaximumAddress
The maximum bus-relative I/O port address that can be assigned to the device
u.Memory
Specifies a range of memory addresses, using the following members:
Length
The length, in bytes, of the range of assignable memory addresses.
Alignment
The alignment, in bytes, that the assigned starting address must adhere to. The assigned starting address must be devisable by Alignment.
MinimumAddress
The minimum bus-relative memory address that can be assigned to the device
MaximumAddress
The maximum bus-relative memory address that can be assigned to the device
u.Interrupt
Specifies an interrupt vector range, using the following members:
MinimumVector
The minimum bus-relative vector that can be assigned to the device.
MaximumVector
The maximum bus-relative vector that can be assigned to the device.
u.Dma
Specifies a DMA setting, using one of the following members:
MinimumChannel
The minimum bus-relative DMA channel that can be assigned to the device.
MaximumChannel
The maximum bus-relative DMA channel that can be assigned to the device.
u.Generic
Not used.
u.DevicePrivate
Reserved for system use.
u.BusNumber
Specifies bus numbers, using the following members:
Length
The number of bus numbers required.
MinBusNumber
The minimum bus-relative bus number that can be assigned to the device.
MaxBusNumber
The maximum bus-relative bus number that can be assigned to the device.
Reserved
Not used.
u.ConfigData
Reserved for system use.

Headers

Defined in wdm.h and ntddk.h. Include wdm.h or ntddk.h.

See Also

CM_PARTIAL_RESOURCE_DESCRIPTOR,
IO_RESOURCE_LIST,
IO_RESOURCE_REQUIREMENTS_LIST,
IoConnectInterrupt