OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium 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 #include "chromeos/tpm_token_loader.h" | 5 #include "chromeos/tpm_token_loader.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/location.h" | 10 #include "base/location.h" |
(...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
270 VLOG(1) << "OnTPMTokenInitialized: " << success; | 270 VLOG(1) << "OnTPMTokenInitialized: " << success; |
271 if (!success) { | 271 if (!success) { |
272 RetryTokenInitializationLater(); | 272 RetryTokenInitializationLater(); |
273 return; | 273 return; |
274 } | 274 } |
275 tpm_token_state_ = TPM_TOKEN_INITIALIZED; | 275 tpm_token_state_ = TPM_TOKEN_INITIALIZED; |
276 ContinueTokenInitialization(); | 276 ContinueTokenInitialization(); |
277 } | 277 } |
278 | 278 |
279 void TPMTokenLoader::NotifyTPMTokenReady() { | 279 void TPMTokenLoader::NotifyTPMTokenReady() { |
280 FOR_EACH_OBSERVER(Observer, observers_, | 280 FOR_EACH_OBSERVER(Observer, observers_, OnTPMTokenReady()); |
281 OnTPMTokenReady(tpm_user_pin_, tpm_token_name_, tpm_token_slot_id_)); | |
282 } | 281 } |
283 | 282 |
284 void TPMTokenLoader::LoggedInStateChanged() { | 283 void TPMTokenLoader::LoggedInStateChanged() { |
285 VLOG(1) << "LoggedInStateChanged"; | 284 VLOG(1) << "LoggedInStateChanged"; |
286 MaybeStartTokenInitialization(); | 285 MaybeStartTokenInitialization(); |
287 } | 286 } |
288 | 287 |
289 } // namespace chromeos | 288 } // namespace chromeos |
OLD | NEW |