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

Unified Diff: testsuite/tcg/nv/Tspi_NV_DefineSpace02.c

Issue 3581012: Upgrade from trousers 0.3.3 to 0.3.6 and from testsuite 0.2 to 0.3. (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/trousers.git
Patch Set: git cl push Created 10 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « testsuite/tcg/nv/Tspi_NV_DefineSpace01.c ('k') | testsuite/tcg/nv/Tspi_NV_DefineSpace03.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: testsuite/tcg/nv/Tspi_NV_DefineSpace02.c
diff --git a/testsuite/tcg/nv/Tspi_NV_DefineSpace02.c b/testsuite/tcg/nv/Tspi_NV_DefineSpace02.c
index 4efb88f0d02fc06efa476462bc7effcef9b817c2..5ff877ff2ea17405f85fbca834a68e0b86ed8e7e 100644
--- a/testsuite/tcg/nv/Tspi_NV_DefineSpace02.c
+++ b/testsuite/tcg/nv/Tspi_NV_DefineSpace02.c
@@ -193,7 +193,23 @@ main_v1_2(char version)
/*Define NV space*/
result = Tspi_NV_DefineSpace(hNVStore, 0, 0);
+
+ /* Set password */
+ Tspi_Policy_SetSecret(hPolicy, TESTSUITE_OWNER_SECRET_MODE,
+ TESTSUITE_OWNER_SECRET_LEN,
+ TESTSUITE_OWNER_SECRET);
+ Tspi_TPM_SetStatus(hTPM, TSS_TPMSTATUS_RESETLOCK, 1);
+#ifdef CLEAR_TEST_INDEX
+ if (result== TSS_SUCCESS)
+ {
+ Tspi_Context_GetTpmObject(hContext, &hTPM);
+ Tspi_GetPolicyObject(hTPM, TSS_POLICY_USAGE, &hPolicy);
+ Tspi_Policy_SetSecret( hPolicy, TESTSUITE_OWNER_SECRET_MODE,
+ TESTSUITE_OWNER_SECRET_LEN, TESTSUITE_OWNER_SECRET);
+ Tspi_NV_ReleaseSpace(hNVStore);
+ }
+#endif
#ifdef NV_LOCKED
if (TSS_ERROR_CODE(result)== TPM_E_AUTHFAIL)
{
« no previous file with comments | « testsuite/tcg/nv/Tspi_NV_DefineSpace01.c ('k') | testsuite/tcg/nv/Tspi_NV_DefineSpace03.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698