security/vboot: Add function to check if UDC can be enabled
commit95673afc78c9bdc3c78734c8e23a67f37dc8c8cd
authorFurquan Shaikh <furquan@google.com>
Thu, 26 Apr 2018 01:15:44 +0000 (25 18:15 -0700)
committerFurquan Shaikh <furquan@google.com>
Fri, 27 Apr 2018 02:51:32 +0000 (27 02:51 +0000)
treee13895ef32d7506ab2074768a91cc68926f97f2f
parent37c721d78669ed2141981c990a3e8eb1f538fdb4
security/vboot: Add function to check if UDC can be enabled

Add a function that will check the various requirements to
enable USB Device Controller (UDC):

- developer mode enabled
- GBB flag set or VBNV flag set

If VBOOT is not enabled, then default is to allow UDC enabling.

BUG=b:78577893
BRANCH=poppy

Change-Id: Id146ac1065f209865372aeb423f66ae734702954
Signed-off-by: Duncan Laurie <dlaurie@google.com>
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/25847
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
src/security/vboot/vboot_common.c
src/security/vboot/vboot_common.h