summaryrefslogtreecommitdiffstats
path: root/content/gpu
diff options
context:
space:
mode:
authorjbauman@chromium.org <jbauman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-11-08 02:51:12 +0000
committerjbauman@chromium.org <jbauman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-11-08 02:51:12 +0000
commit4271960ec03b5e51ebcd8879c7b832282ea3a0cd (patch)
treed72388b6d46be06e1cea08090b0052f47cd64f78 /content/gpu
parent4895dd806a3ef331d1905166c7537d1845d36b47 (diff)
downloadchromium_src-4271960ec03b5e51ebcd8879c7b832282ea3a0cd.zip
chromium_src-4271960ec03b5e51ebcd8879c7b832282ea3a0cd.tar.gz
chromium_src-4271960ec03b5e51ebcd8879c7b832282ea3a0cd.tar.bz2
Enable GPU watchdog after initializing GL on Chrome OS
This was causing errors when developers switched to VT2 on startup. BUG=159137 Review URL: https://chromiumcodereview.appspot.com/11293158 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@166590 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/gpu')
-rw-r--r--content/gpu/gpu_main.cc15
1 files changed, 14 insertions, 1 deletions
diff --git a/content/gpu/gpu_main.cc b/content/gpu/gpu_main.cc
index 0e84d3e..4629242 100644
--- a/content/gpu/gpu_main.cc
+++ b/content/gpu/gpu_main.cc
@@ -131,11 +131,19 @@ int GpuMain(const MainFunctionParams& parameters) {
enable_watchdog = false;
#endif
+ bool delayed_watchdog_enable = false;
+
+#if defined(OS_CHROMEOS)
+ // Don't start watchdog immediately, to allow developers to switch to VT2 on
+ // startup.
+ delayed_watchdog_enable = true;
+#endif
+
scoped_refptr<GpuWatchdogThread> watchdog_thread;
// Start the GPU watchdog only after anything that is expected to be time
// consuming has completed, otherwise the process is liable to be aborted.
- if (enable_watchdog) {
+ if (enable_watchdog && !delayed_watchdog_enable) {
watchdog_thread = new GpuWatchdogThread(kGpuTimeout);
watchdog_thread->Start();
}
@@ -191,6 +199,11 @@ int GpuMain(const MainFunctionParams& parameters) {
dead_on_arrival = true;
}
+ if (enable_watchdog && delayed_watchdog_enable) {
+ watchdog_thread = new GpuWatchdogThread(kGpuTimeout);
+ watchdog_thread->Start();
+ }
+
// OSMesa is expected to run very slowly, so disable the watchdog in that
// case.
if (enable_watchdog &&