diff --git a/packages/mediacenter/xbmc/patches/12.2-091cb29/xbmc-990.24-wait-for-nic-on-wakeup.patch b/packages/mediacenter/xbmc/patches/12.2-091cb29/xbmc-990.24-wait-for-nic-on-wakeup.patch deleted file mode 100644 index a75dba87e4..0000000000 --- a/packages/mediacenter/xbmc/patches/12.2-091cb29/xbmc-990.24-wait-for-nic-on-wakeup.patch +++ /dev/null @@ -1,60 +0,0 @@ -diff --git a/xbmc/powermanagement/PowerManager.cpp b/xbmc/powermanagement/PowerManager.cpp -index 26d7002..71c4bd4 100644 ---- a/xbmc/powermanagement/PowerManager.cpp -+++ b/xbmc/powermanagement/PowerManager.cpp -@@ -23,6 +23,7 @@ - #include "Application.h" - #include "cores/AudioEngine/AEFactory.h" - #include "input/KeyboardStat.h" -+#include "network/Network.h" - #include "settings/GUISettings.h" - #include "windowing/WindowingFactory.h" - #include "utils/log.h" -@@ -218,10 +219,34 @@ void CPowerManager::OnSleep() - CAEFactory::Suspend(); - } - -+void CPowerManager::WaitForNet() -+{ -+ CLog::Log(LOGDEBUG, "%s: Waithing for first NIC to come up", __FUNCTION__); -+ -+ const unsigned maxLoopCount = 50u; -+ const unsigned sleepTimeMs = 200u; -+ -+ for(unsigned i=0; i < 50; ++i) -+ { -+ CNetworkInterface* pIface = g_application.getNetwork().GetFirstConnectedInterface(); -+ if (pIface && pIface->IsEnabled() && pIface->IsConnected()) -+ { -+ CLog::Log(LOGDEBUG, "%s: NIC is up after waiting %d ms", __FUNCTION__, i * sleepTimeMs); -+ return; -+ } -+ -+ Sleep(sleepTimeMs); -+ } -+ -+ CLog::Log(LOGDEBUG, "%s: NIC did not come up within %d ms... Lets give up...", __FUNCTION__, maxLoopCount * sleepTimeMs); -+} -+ - void CPowerManager::OnWake() - { - CLog::Log(LOGNOTICE, "%s: Running resume jobs", __FUNCTION__); - -+ WaitForNet(); -+ - // reset out timers - g_application.ResetShutdownTimers(); - -diff --git a/xbmc/powermanagement/PowerManager.h b/xbmc/powermanagement/PowerManager.h -index 0a9183c..714b5cc 100644 ---- a/xbmc/powermanagement/PowerManager.h -+++ b/xbmc/powermanagement/PowerManager.h -@@ -72,6 +72,8 @@ private: - - void OnLowBattery(); - -+ void WaitForNet(); -+ - IPowerSyscall *m_instance; - }; -