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

Side by Side Diff: tests/tpm_lite/spaceperm.c

Issue 3116025: Added new commands and reactivated full rebuild after fixing for ARM ebuild. (Closed) Base URL: ssh://git@chromiumos-git/vboot_reference.git
Patch Set: move to new build flow (no changes expected) Created 10 years, 3 months 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 unified diff | Download patch
« no previous file with comments | « tests/tpm_lite/redefine.c ('k') | tests/tpm_lite/writelimit.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 1 /* Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
2 * Use of this source code is governed by a BSD-style license that can be 2 * Use of this source code is governed by a BSD-style license that can be
3 * found in the LICENSE file. 3 * found in the LICENSE file.
4 */ 4 */
5 5
6 /* Test of space permissions retrieval. The spaces 0xcafe and 0xcaff must have 6 /* Test of space permissions retrieval. The spaces 0xcafe and 0xcaff must have
7 * already been defined (by running, for instance, the "redefine" test). 7 * already been defined (by running, for instance, the "redefine" test).
8 */ 8 */
9 9
10 #include <stdint.h> 10 #include <stdint.h>
11 #include <stdio.h> 11 #include <stdio.h>
12 #include <stdlib.h> 12 #include <stdlib.h>
13 #include <tss/tcs.h>
14 13
15 #include "tlcl.h" 14 #include "tlcl.h"
16 #include "utility.h" 15 #include "utility.h"
17 16
18 #define INDEX0 0xcafe 17 #define INDEX0 0xcafe
19 #define INDEX1 0xcaff 18 #define INDEX1 0xcaff
20 19
21 int main(int argc, char** argv) { 20 int main(int argc, char** argv) {
22 uint32_t perm; 21 uint32_t perm;
23 uint32_t perm_pp_gl = TPM_NV_PER_PPWRITE | TPM_NV_PER_GLOBALLOCK; 22 uint32_t perm_pp_gl = TPM_NV_PER_PPWRITE | TPM_NV_PER_GLOBALLOCK;
(...skipping 11 matching lines...) Expand all
35 assert((perm & perm_pp_gl) == perm_pp_gl); 34 assert((perm & perm_pp_gl) == perm_pp_gl);
36 35
37 result = TlclGetPermissions(INDEX1, &perm); 36 result = TlclGetPermissions(INDEX1, &perm);
38 assert(result == TPM_SUCCESS); 37 assert(result == TPM_SUCCESS);
39 printf("permissions for INDEX1 = 0x%x\n", perm); 38 printf("permissions for INDEX1 = 0x%x\n", perm);
40 assert((perm & perm_pp) == perm_pp); 39 assert((perm & perm_pp) == perm_pp);
41 40
42 printf("Test completed successfully\n"); 41 printf("Test completed successfully\n");
43 exit(0); 42 exit(0);
44 } 43 }
OLDNEW
« no previous file with comments | « tests/tpm_lite/redefine.c ('k') | tests/tpm_lite/writelimit.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698