Share via


HalSetBusData

Other versions of this page are also available for the following:

Windows Mobile Not SupportedWindows Embedded CE Supported

8/28/2008

This function sets bus-configuration data for a slot or address on a bus.

Syntax

ULONG HalSetBusData( 
  BUS_DATA_TYPE BusDataType, 
  ULONG BusNumber, 
  ULONG SlotNumber, 
  PVOID Buffer, 
  ULONG Length 
);

Parameters

  • BusDataType
    [in] Bus data to set. The upper bound on the types supported is always MaximumBusDataType.
  • BusNumber
    [in] Zero-based and system-assigned number of the bus in systems with several buses of the same BusDataType.
  • SlotNumber
    [in] Logical slot number or location of the device. If you specify PCIConfiguration as the BusDataType, this value is a PCI_SLOT_NUMBER value, which is the slot and function numbers combined.
  • Buffer
    [in] Pointer to a caller-supplied buffer for configuration information specific to BusDataType.

    If you specify PCIConfiguration, the buffer contains the PCI_COMMON_CONFIG information for the specified SlotNumber. The specified Offset and Length determine how much information to supply. Certain members of PCI_COMMON_CONFIG have read-only values. The caller is responsible for preserving the system-supplied values of read-only members.

  • Length
    [in] Number of bytes in the Buffer to set.

Return Value

Returns the number of bytes of data successfully set for the specified SlotNumber and function number. If the specified BusDataType is not valid for the current platform or if the supplied information is invalid, this function returns zero (0).

Remarks

Calling HalSetBusDataByOffset with a BusDataType of PCIConfiguration and an input Offset of 0 is the same as calling HalSetBusData.

Requirements

Header ceddk.h
Library CEDDK.lib
Windows Embedded CE Windows CE 2.10 and later

See Also

Reference

BUS_DATA_TYPE
HalGetBusData
HalGetBusDataByOffset
HalSetBusDataByOffset
HalTranslateBusAddress
PCI_COMMON_CONFIG