Merge "Drop caches after installing key policy to avoid cache clashes" into nyc-mr1-dev

am: 235e78b9ae

* commit '235e78b9aede9d4a7f871f5064670afab5cb2d6b':
  Drop caches after installing key policy to avoid cache clashes

Change-Id: I766e87aa700bd0a1312faac33092b3a0d20b5fd1
gugelfrei
Paul Lawrence 8 years ago committed by android-build-merger
commit 7b6ff76185

@ -176,6 +176,14 @@ static bool install_key(const std::string& key, std::string* raw_ref) {
}
LOG(DEBUG) << "Added key " << key_id << " (" << ref << ") to keyring " << device_keyring
<< " in process " << getpid();
// *TODO* Remove this code when kernel is fixed - see b/28373400
// Kernel preserves caches across a key insertion with ext4ice, which leads
// to contradictory dirents
if (!android::base::WriteStringToFile("3", "/proc/sys/vm/drop_caches")) {
PLOG(ERROR) << "Failed to drop_caches";
}
return true;
}

Loading…
Cancel
Save