From 21150471e3c11f0816e034404567b1f016924737 Mon Sep 17 00:00:00 2001 From: Chengyi Zhao Date: Fri, 3 Jan 2014 12:45:46 +0800 Subject: [PATCH] Make WIFI driver loading mechanism configurable Currently, on Samsung platform, it loads WIFI driver dynamically, but on Intel platform, WIFI driver is loaded when system boots up. So it needs to make the WIFI driver loading mechanism configurable to adapt both Samsung and Intel platform. Use the existing macro definition "EMBEDDED_TARGET" to fix this issue. Change-Id: Iddccfc411f79284232f9d10b971ac6cd28ae75ca Signed-off-by: Chengyi Zhao --- src/wifi-power.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/wifi-power.c b/src/wifi-power.c index 15ac07c..db06800 100644 --- a/src/wifi-power.c +++ b/src/wifi-power.c @@ -121,11 +121,13 @@ static gboolean __netconfig_wifi_load_driver(void) if (netconfig_emulator_is_emulated() == TRUE) return rv; +#if defined EMBEDDED_TARGET rv = netconfig_execute_file(path, args, envs); if (rv != TRUE) { DBG("Failed to load wireless device driver"); return FALSE; } +#endif DBG("Successfully loaded wireless device driver"); return TRUE; @@ -141,11 +143,13 @@ gboolean netconfig_wifi_remove_driver(void) if (netconfig_emulator_is_emulated() == TRUE) return rv; +#if defined EMBEDDED_TARGET rv = netconfig_execute_file(path, args, env); if (rv != TRUE) { DBG("Failed to remove wireless device driver"); return FALSE; } +#endif DBG("Successfully removed wireless device driver"); return TRUE; -- 2.34.1