On 10/16/2015 06:21 PM, Jimmy Zhang wrote:
Jimmy Zhang wrote at Monday, October 12, 2015 7:02 PM
Stephen Warren wrote at Monday, October 12, 2015 3:49 PM:
On 10/09/2015 07:46 PM, Jimmy Zhang wrote:
Create new configuration keywords:
     RsaKeyModulusFile: pubkey modulus
     RsaPssSigBlFile:   bootloader rsa pss signature
     RsaPssSigBctFile:  bct rsa pss signature

Sample Configuration file update_bl_sig.cfg
     RsaKeyModulusFile = pubkey.mod;
     RsaPssSigBlFile = bl.sig;

where pubkey.mod and bl.sig are files that contain the public key
modulus and bootloader's rsa-pss signature respectively.

public key modulus and signature are created through utilities
outside cbootimage.

Command line example:
   $ cbootimage -s tegra210 -u update_bl_sig.cfg image.bin
image.bin-bl-signed

Above three new keywords added in this CL are only implemented
support for T210.

diff --git a/src/crypto.c b/src/crypto.c

+void
+swap_endianness(
...
This is the function name used by tegrasign. I am open if you have a better
name. The reason for the swap because the string actually is a 256 byte long
number. Tegra soc handles a number by little endian byte order.

+       u_int8_t *out,
+       u_int8_t *in,

Nit: You could make "in" const to since it's not written.


OK.

Actually this function allows output pointing to input, ie, reversing itself in 
byte order.

Presumably however, the "in" pointer is only used for reads and the "out" point is only used for writes, so "in" can still be const?

--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to