mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-11 18:35:28 +00:00
Storing nvram in SPI Flash becomes more and more popular. Retrieving it takes quite a while due to various flashrom issues. While flashrom still needs to be improved to minimize its running time, a good speed up can be achieved by caching the nvram contents in crossystem. The cache is invalidated each time nvram is written (this could be optimized by updating the local copy, but probably is not worth the extra effort). BRANCH=storm BUG=chrome-os-partner:33592 TEST=crossystem runs much faster now: localhost var # time /var/tmp/crossystem . . . real 0m1.669s user 0m0.790s sys 0m0.170s localhost var # Change-Id: Ie4a483efc189257ff58c92bdc39871b917c89727 Signed-off-by: Vadim Bendebury <vbendeb@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/228655 Reviewed-by: Randall Spangler <rspangler@chromium.org> Reviewed-by: David Hendricks <dhendrix@chromium.org>