Implement a boot attempt counter.

Bug: 122556707
Test: manual test
Change-Id: I75457b95aef9d74bbf4121850f2f29fdc887386c
9 files changed