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

Issue 6665005: Add check-value support and check /proc/cmdline for cros_nodebug (Closed)

Created:
9 years, 9 months ago by Randall Spangler
Modified:
9 years, 7 months ago
Reviewers:
gauravsh, Will Drewry
CC:
chromium-os-reviews_chromium.org, Randall Spangler, Luigi Semenzato, Bill Richardson
Visibility:
Public.

Description

Add check-value support and check /proc/cmdline for cros_nodebug Change-Id: I35158810184be03f18d98893e4dd640088384579 BUG=12904 TEST=manual crossystem fwb_tries=1 crossystem fwb_tries?1 && echo YES || echo NO --> YES crossystem fwb_tries?0x01 && echo YES || echo NO --> YES crossystem fwb_tries?0 && echo YES || echo NO --> NO crossystem fwb_tries=0 crossystem fwb_tries?0 && echo YES || echo NO --> YES crossystem fwb_tries?1 && echo YES || echo NO --> NO crossystem fwb_tries?0x01 && echo YES || echo NO --> NO crossystem ecfw_act --> RW (if it's not, change RW to RO in the tests below) crossystem ecfw_act?RW && echo YES || echo NO --> YES crossystem ecfw_act?BOB && echo YES || echo NO --> NO For the following tests, boot Alex with dev switch on and fwb_tries=1 Expected output of `crossystem mainfw_type mainfw_act cros_debug` under each of the following scenarios: * Neither "cros_debug" nor" cros_nodebug" in kernel command line: normal B 1 * Kernel command line changed to include "cros_nodebug": normal B 0 * Kernel command line changed to include "cros_nodebugg": normal B 1 * Kernel command line changed to include "ccros_nodebug": normal B 1 Committed: http://chrome-svn/viewvc/chromeos?view=rev&revision=227f792

Patch Set 1 #

Total comments: 3

Patch Set 2 : Fixes from code review #

Unified diffs Side-by-side diffs Delta from patch set Stats (+42 lines, -6 lines) Patch
M host/lib/crossystem.c View 2 chunks +3 lines, -1 line 0 comments Download
M utility/crossystem_main.c View 1 4 chunks +39 lines, -5 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
Randall Spangler
9 years, 9 months ago (2011-03-10 21:33:16 UTC) #1
gauravsh
lgtm http://codereview.chromium.org/6665005/diff/1/utility/crossystem_main.c File utility/crossystem_main.c (right): http://codereview.chromium.org/6665005/diff/1/utility/crossystem_main.c#newcode130 utility/crossystem_main.c:130: if (v == -1 || i != v) ...
9 years, 9 months ago (2011-03-11 02:39:35 UTC) #2
Will Drewry
9 years, 9 months ago (2011-03-11 02:47:17 UTC) #3
lgtm

with two optional comments to go with gauravsh's :)

http://codereview.chromium.org/6665005/diff/1/utility/crossystem_main.c
File utility/crossystem_main.c (right):

http://codereview.chromium.org/6665005/diff/1/utility/crossystem_main.c#newco...
utility/crossystem_main.c:126: int i = strtol(expect, &e, 0);
nit: long != int, always.

this will likely throw a warning when building 64-bit, but unlikely to be a
problem ever in practice.

http://codereview.chromium.org/6665005/diff/1/utility/crossystem_main.c#newco...
utility/crossystem_main.c:222: else if (has_expect)
Do you want a check for has_set && has_expect to bail out? 

Not a big deal, but just thinking it could help catch typos or misuse.

Powered by Google App Engine
This is Rietveld 408576698