Skip to content

Commit c5fdcc5

Browse files
committed
PhysicalDisk (Linux): detect revision of USB devices
1 parent f894856 commit c5fdcc5

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/detection/physicaldisk/physicaldisk_linux.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,12 @@ const char* ffDetectPhysicalDisk(FFlist* result, FFPhysicalDiskOptions* options)
149149
snprintf(pathSysBlock, PATH_MAX, "/sys/block/%s/device/firmware_rev", devName);
150150
if (ffReadFileBuffer(pathSysBlock, &device->revision))
151151
ffStrbufTrimRightSpace(&device->revision);
152+
else
153+
{
154+
snprintf(pathSysBlock, PATH_MAX, "/sys/block/%s/device/rev", devName);
155+
if (ffReadFileBuffer(pathSysBlock, &device->revision))
156+
ffStrbufTrimRightSpace(&device->revision);
157+
}
152158
}
153159

154160
device->temperature = FF_PHYSICALDISK_TEMP_UNSET;

0 commit comments

Comments
 (0)