Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(605)

Unified Diff: content/gpu/gpu_main.cc

Issue 11293158: Enable GPU watchdog after initializing GL on Chrome OS (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/gpu/gpu_main.cc
diff --git a/content/gpu/gpu_main.cc b/content/gpu/gpu_main.cc
index 0e84d3e431adab223afaac11b7f254fa56d706b9..46292423d3a23fcff7a77d413db40176917c1d80 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 &&
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698