MCPcopy Create free account
hub / github.com/CloverHackyColor/CloverBootloader / BigNumSwapWord

Function BigNumSwapWord

Library/OcCryptoLib/BigNumPrimitives.c:52–66  ·  view source on GitHub ↗

STATIC_ASSERT ( OC_BN_WORD_SIZE == sizeof (UINT32) || OC_BN_WORD_SIZE == sizeof (UINT64), "OC_BN_WORD_SIZE and OC_BN_WORD_NUM_BITS usages must be adapted." ); */

Source from the content-addressed store, hash-verified

50 );
51*/
52OC_BN_WORD
53BigNumSwapWord (
54 IN OC_BN_WORD Word
55 )
56{
57 if (OC_BN_WORD_SIZE == sizeof (UINT32)) {
58 return (OC_BN_WORD)SwapBytes32 ((UINT32)Word);
59 }
60
61 if (OC_BN_WORD_SIZE == sizeof (UINT64)) {
62 return (OC_BN_WORD)SwapBytes64 ((UINT64)Word);
63 }
64
65 ASSERT (FALSE);
66}
67
68/**
69 Shifts A left by Exponent Words.

Callers 1

Calls 2

SwapBytes32Function · 0.50
SwapBytes64Function · 0.50

Tested by

no test coverage detected