From 3ea7a8e67bbf5362283e9c08f8177228d77fa1bd Mon Sep 17 00:00:00 2001 From: Ondrej Čerman Date: Sat, 23 Feb 2019 19:32:17 +0100 Subject: devices/storage - udisks2: added pm, apm, aam, part. table type and partitions list --- modules/devices/storage.c | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'modules/devices') diff --git a/modules/devices/storage.c b/modules/devices/storage.c index e5ad84b8..cb2cc590 100644 --- a/modules/devices/storage.c +++ b/modules/devices/storage.c @@ -85,9 +85,18 @@ gboolean __scan_udisks2_devices(void) { if (disk->ejectable) { features = h_strdup_cprintf(", %s", features, _("Ejectable")); } - if (disk->smart_enabled) { + if (disk->smart_supported) { features = h_strdup_cprintf(", %s", features, _("Smart monitoring")); } + if (disk->pm_supported) { + features = h_strdup_cprintf(", %s", features, _("Power Managment")); + } + if (disk->apm_supported) { + features = h_strdup_cprintf(", %s", features, _("Advanced Power Management")); + } + if (disk->aam_supported) { + features = h_strdup_cprintf(", %s", features, _("Automatic Acoustic Management")); + } moreinfo = g_strdup_printf(_("[Drive Information]\n" "Model=%s\n"), @@ -141,6 +150,14 @@ gboolean __scan_udisks2_devices(void) { disk->smart_poweron/(60*60*24), (disk->smart_poweron/60/60) % 24, disk->smart_temperature); } + if (disk->partition_table || disk->partitions) { + moreinfo = h_strdup_cprintf(_("[Partition table]\n" + "Type=%s\n" + "Partitions=%s\n"), + moreinfo, + disk->partition_table ? disk->partition_table : _("(Unknown)"), + disk->partitions ? disk->partitions : _("(Unknown)")); + } moreinfo_add_with_prefix("DEV", devid, moreinfo); g_free(devid); -- cgit v1.2.3