diff options
author | Suren A. Chilingaryan <csa@suren.me> | 2016-03-08 02:15:51 +0100 |
---|---|---|
committer | Suren A. Chilingaryan <csa@suren.me> | 2016-03-08 02:15:51 +0100 |
commit | eec7e74d2eccf811f0d25bb40fa514dc47655d67 (patch) | |
tree | 1b2c199cb356da7fd299d5b53a632cf9a535ca3e /pcilib/xml.h | |
parent | 92b9df25f5bbb2f70ee2626907e410affc02bdeb (diff) | |
download | pcitool-eec7e74d2eccf811f0d25bb40fa514dc47655d67.tar.gz pcitool-eec7e74d2eccf811f0d25bb40fa514dc47655d67.tar.bz2 pcitool-eec7e74d2eccf811f0d25bb40fa514dc47655d67.tar.xz pcitool-eec7e74d2eccf811f0d25bb40fa514dc47655d67.zip |
Support XML configuration of device models
Diffstat (limited to 'pcilib/xml.h')
-rw-r--r-- | pcilib/xml.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/pcilib/xml.h b/pcilib/xml.h index d8a9693..f6fc91b 100644 --- a/pcilib/xml.h +++ b/pcilib/xml.h @@ -40,6 +40,16 @@ struct pcilib_xml_s { extern "C" { #endif +/** + * Resolves device model from vendor and device ids using XML configuration + * The association of vendor/device id pairs with model are provided devices.xml under PCILIB_MODEL_DIR + * @param[in,out] ctx - pcilib context + * @param[in] vendor_id - the vendor id + * @param[in] device_id - the device id + * @return - the name of model or NULL on an error and unknown device. It is caller responsibility to free returned string. + */ +char *pcilib_detect_xml_model(pcilib_t *ctx, unsigned int vendor_id, unsigned int device_id); + /** Initializes XML stack and loads a default set of XML files. * The default location for XML files is /usr/local/share/pcilib/models/@b{model}. * This can be altered using CMake PCILIB_MODEL_DIR variable while building or using |