From 1eb28cdf81fda7bc748e2ba071e2d222a3287453 Mon Sep 17 00:00:00 2001 From: Ondrej Čerman Date: Sat, 12 Jan 2019 18:07:09 +0100 Subject: devices/storage: Use udisks2 as primary source for storage info --- modules/devices.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'modules/devices.c') diff --git a/modules/devices.c b/modules/devices.c index fa474180..1c3253e4 100644 --- a/modules/devices.c +++ b/modules/devices.c @@ -38,6 +38,7 @@ #include "devices.h" #include "dt_util.h" +#include "udisks2_util.h" gchar *callback_processors(); gchar *callback_gpu(); @@ -616,8 +617,10 @@ void scan_storage(gboolean reload) g_free(storage_list); storage_list = g_strdup(""); - __scan_ide_devices(); - __scan_scsi_devices(); + if (!__scan_udisks2_devices()) { + __scan_ide_devices(); + __scan_scsi_devices(); + } SCAN_END(); } @@ -791,14 +794,14 @@ void hi_module_init(void) init_memory_labels(); init_cups(); sensors_init(); - storage_init(); + udisks2_init(); } void hi_module_deinit(void) { moreinfo_del_with_prefix("DEV"); sensors_shutdown(); - storage_shutdown(); + udisks2_shutdown(); g_hash_table_destroy(memlabels); g_module_close(cups); } -- cgit v1.2.3