2
0

Display GPU vram vendor

Add support and testing for reading the vram vendor associated with
the GPU. The vram vendor can be found as a separate sysfs file at:
/sys/class/drm/card[X]/device/mem_info_vram_vendor
The vram vendor is displayed as a string value.

Change-Id: I12c8e56e57f45aa08d7d6c25338c4e468ed1c7fc
Signed-off-by: Ori Messinger <Ori.Messinger@amd.com>
Este cometimento está contido em:
Ori Messinger
2019-10-03 13:06:11 -04:00
ascendente 551b15182b
cometimento 2412dff6a2
5 ficheiros modificados com 70 adições e 0 eliminações
+25
Ver ficheiro
@@ -878,6 +878,31 @@ rsmi_status_t rsmi_dev_brand_get(uint32_t dv_ind, char *brand, uint32_t len);
rsmi_status_t rsmi_dev_vendor_name_get(uint32_t dv_ind, char *name,
size_t len);
/**
* @brief Get the vram vendor string of a gpu device.
*
* @details Given a device index @p dv_ind, a pointer to a caller provided
* char buffer @p brand, and a length of this buffer @p len, this function
* will write the vram vendor of the device (up to @p len characters) to the
* buffer @p brand.
*
* If the vram vendor for the device is not found as one of the values
* contained within rsmi_dev_vram_vendor_get, then this function will return
* the string 'unknown' instead of the vram vendor.
*
* @param[in] dv_ind a device index
*
* @param[inout] brand a pointer to a caller provided char buffer to which the
* vram vendor will be written
*
* @param[in] len the length of the caller provided buffer @p brand.
*
* @retval ::RSMI_STATUS_SUCCESS is returned upon successful call.
*
*/
rsmi_status_t rsmi_dev_vram_vendor_get(uint32_t dv_ind, char *brand,
uint32_t len);
/**
* @brief Get the serial number string for a device
*
+1
Ver ficheiro
@@ -125,6 +125,7 @@ enum DevInfoTypes {
kDevMemUsedGTT,
kDevMemUsedVisVRAM,
kDevMemUsedVRAM,
kDevVramVendor,
kDevPCIEReplayCount,
kDevUniqueId,
kDevDFCountersAvailable,