[sw/host/opentitanlib] Add SFDP signature check
[sw/host/opentitanlib] Add SFDP signature check

My CW310 FPGA is producing 256 0xff bytes for the SFDP buffer instead of
something valid. As a result, we're parsing a signature of 0xffffffff
instead of the expected 0x50444653.

This commit changes Sfdp::try_from() to fail fast with an informative
error message about the invalid header, rather than blunder on and fail
farther down the line with "attempt to add with overflow".

Fixes #13477

Signed-off-by: Dan McArdle <8fb240f11ec935676fcfd8aed04f42f9ee63efa8@google.com>

lowRISC/opentitan,lowRISC/opentitan,lowRISC/opentitan,lowRISC/opentitan,lowRISC/opentitan,lowRISC/opentitan