Hardware Locality (hwloc): Components and Plugins: Discovery backends

Hardware Locality (hwloc) 1.11.7

Data Structures | Enumerations | Functions
Components and Plugins: Discovery backends

## Data Structures
struct | hwloc_backend

## Enumerations
enum | hwloc_backend_flag_e { HWLOC_BACKEND_FLAG_NEED_LEVELS }

## Functions
struct hwloc_backend * | hwloc_backend_alloc (struct hwloc_disc_component *component)
int | hwloc_backend_enable (struct hwloc_topology *topology, struct hwloc_backend *backend)
int | hwloc_backends_get_obj_cpuset (struct hwloc_backend *caller, struct hwloc_obj *obj, hwloc_bitmap_t cpuset)
int | hwloc_backends_notify_new_object (struct hwloc_backend *caller, struct hwloc_obj *obj)

## Detailed Description

## Enumeration Type Documentation

## § hwloc_backend_flag_e

enum hwloc_backend_flag_e

Backend flags.

Enumerator
HWLOC_BACKEND_FLAG_NEED_LEVELS | Levels should be reconnected before this backend discover() is used.

## Function Documentation

## § hwloc_backend_alloc()

struct hwloc_backend* hwloc_backend_alloc | ( | struct hwloc_disc_component * | component | ) |

Allocate a backend structure, set good default values, initialize backend->component and topology, etc. The caller will then modify whatever needed, and call hwloc_backend_enable().

## § hwloc_backend_enable()

int hwloc_backend_enable | ( | struct hwloc_topology * | topology,
|  | struct hwloc_backend * | backend
| ) |  |

Enable a previously allocated and setup backend.

## § hwloc_backends_get_obj_cpuset()

int hwloc_backends_get_obj_cpuset | ( | struct hwloc_backend * | caller,
|  | struct hwloc_obj * | obj,
|  | hwloc_bitmap_t | cpuset
| ) |  |

Used by backends discovery callbacks to request locality information from others.

Traverse the list of enabled backends until one has a get_obj_cpuset() method, and call it.

## § hwloc_backends_notify_new_object()

int hwloc_backends_notify_new_object | ( | struct hwloc_backend * | caller,
|  | struct hwloc_obj * | obj
| ) |  |

Used by backends discovery callbacks to notify other backends of new objects.

Traverse the list of enabled backends (all but caller) and invoke their notify_new_object() method to notify them that a new object just got added to the topology.

Currently only used for notifying of new PCI device objects.