PIC32CM5112SG00100 HSM registers

The 57 registers of HSM (Cryptographic Acceleration Module Lite), from 0x4F000000, with their reset value and every field. The PIC32CM5112SG00100 has 3618 registers in 68 peripherals, one page each.

HSM Cryptographic Acceleration Module Lite

CTRLAControl Register A

Address
0x4F000000
Reset
0x00000000
Access
read/write
Size
32-bit
4 fields
FieldBitsWhat it does
RUNSTDBY6Run In Standby bit
  • 0 HSM clock is disabled in Standby Sleep mode, clock requests are de-asserted after any pending bus transactions or requests are completed.
  • 1 If enabled, the HSM clock remains requested in Standby Sleep mode.
PRIV2Privileged Access Only - This bit affects all Wrapper and EIP registers.
  • 0 HSM registers accessible in privileged and unprivileged modes. Master Requests are NOT privileged
  • 1 HSM registers only accessible in privileged mode. Master Requests are also privileged.
ENABLE1Macro/Clock Enable bit
  • 0 HSM clock is not requested and macros is disabled.
  • 1 HSM clock is requested and macro is enabled.
SWRST0Software Reset1 = Reset registers and internal state0 = No effect

STATUSASTATUS Register A

Address
0x4F000038
Reset
0x00000000
Access
read only
Size
32-bit
1 field
FieldBitsWhat it does
OTPLOCK0OTP Lock bit
  • 1 OTP lock bit set. Device not in IC manufacturing.

SYNCBUSYSYNCBUSY Register

Address
0x4F00005C
Reset
0x00000000
Access
read only
Size
32-bit
2 fields
FieldBitsWhat it does
ENABLE1Macro Enable Synchronization Busy
  • 0 ENABLE synchronization is NOT busy.
  • 1 ENABLE synchronization is busy.
SWRST0Software Reset Synchronization Busy1 = SWRST synchronization is busy0 = SWRST synchronization is NOT busy

DMA_Registers__FETCH_ADDR_LSB

Address
0x4F010000
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
FETCH_ADDR_LSB31:0

DMA_Registers__FETCH_ADDR_MSB

Address
0x4F010004
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
FETCH_ADDR_MSB31:0

DMA_Registers__FETCH_LEN

Address
0x4F010008
Reset
0x00000000
Access
read/write
Size
32-bit
4 fields
FieldBitsWhat it does
FETCH_ZPADDING30
FETCH_REALIGN29
FETCH_CSTADDR28
FETCH_LEN27:0

DMA_Registers__FETCH_TAG

Address
0x4F01000C
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
FETCH_TAG31:0

DMA_Registers__PUSH_ADDR_LSB

Address
0x4F010010
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
PUSH_ADDR_LSB31:0

DMA_Registers__PUSH_ADDR_MSB

Address
0x4F010014
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
PUSH_ADDR_MSB31:0

DMA_Registers__PUSH_LEN

Address
0x4F010018
Reset
0x00000000
Access
read/write
Size
32-bit
4 fields
FieldBitsWhat it does
PUSH_DISCARD30
PUSH_REALIGN29
PUSH_CSTADDR28
PUSH_LEN27:0

DMA_Registers__INT_EN

Address
0x4F01001C
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
INT_EN5:0

DMA_Registers__INT_ENSET

Address
0x4F010020
Reset
0x00000000
Access
write only
Size
32-bit
1 field
FieldBitsWhat it does
INT_ENSET5:0

DMA_Registers__INT_ENCLR

Address
0x4F010024
Reset
0x00000000
Access
write only
Size
32-bit
1 field
FieldBitsWhat it does
INT_ENCLR5:0

DMA_Registers__INT_STATRAW

Address
0x4F010028
Reset
0x00000000
Access
read only
Size
32-bit
1 field
FieldBitsWhat it does
INT_STATRAW5:0

DMA_Registers__INT_STAT

Address
0x4F01002C
Reset
0x00000000
Access
read only
Size
32-bit
1 field
FieldBitsWhat it does
INT_STAT5:0

DMA_Registers__INT_STATCLR

Address
0x4F010030
Reset
0x00000000
Access
write only
Size
32-bit
1 field
FieldBitsWhat it does
INT_STATCLR5:0

DMA_Registers__CONFIG

Address
0x4F010034
Reset
0x00000000
Access
read/write
Size
32-bit
5 fields
FieldBitsWhat it does
SOFT_RST4
PUSH_STOP3
FETCH_STOP2
PUSH_CTRL_INDIRECT1
FETCH_CTRL_INDIRECT0

DMA_Registers__START

Address
0x4F010038
Reset
0x00000000
Access
write only
Size
32-bit
2 fields
FieldBitsWhat it does
START_PUSH1
START_FETCH0

DMA_Registers__STATUS

Address
0x4F01003C
Reset
0x00000000
Access
read only
Size
32-bit
6 fields
FieldBitsWhat it does
SOFT_RST_BUSY6
PUSH_WAITINGFIFO5
FETCH_NOT_EMPTY4
PUSH_BUSY1
FETCH_BUSY0
PUSH_NBDATA31:16

Registers__INCL_IPS_HW_CFG

Address
0x4F010400
Reset
0x00000611
Access
read only
Size
32-bit
14 fields
FieldBitsWhat it does
BA422_KASUMI_INCLUDED13Generic g_IncludeKasumi value. BA422-Kasumi IP included if set
BA423_SNOW3G_INCLUDED12Generic g_IncludeSnow3G value. BA423-Snow3G IP included if set
BA420_HP_CHACHAPOLY_INCLUDED11Generic g_IncludeHPChachaPoly value. BA420-HP-ChaChaPoly IP included if set
BA431_NDRNG_INCLUDED10Generic g_IncludeNDRNG value. BA431-NDRNG IP included if set
BA414EP_PKE_INCLUDED9Generic g_IncludePKE value. BA414EP-PKE IP included if set
BA419_SM4_INCLUDED8Generic g_IncludeSM4 value. BA419-SM4 IP included if set
BA421_ZUC_INCLUDED7Generic g_IncludeZUC value. BA421-ZUC IP included if set
BA418_SHA3_INCLUDED6Generic g_IncludeSHA3 value. BA418-SHA3 IP included if set
BA417_CHACHAPOLY_INCLUDED5Generic g_IncludeChachaPoly value. BA417-ChaChaPoly IP included if set
BA413_HASH_INCLUDED4Generic g_IncludeHASH value. BA413-HASH IP included if set
BA412_DES_INCLUDED3Generic g_IncludeDES value. BA412-3DES IP included if set
BA416_HP_AES_XTS_INCLUDED2Generic g_IncludeAESXTS value. BA416-HP-AES-XTS IP included if set
BA415_HP_AES_GCM_INCLUDED1Generic g_IncludeAESGCM value. BA415-HP-AES-GCM IP included if set
BA411_AES_INCLUDED0Generic g_IncludeAES value. BA411E-AES IP included if set

Registers__BA411E_AES_HW_CFG_1

Address
0x4F010404
Reset
0x1F0301FF
Access
read only
Size
32-bit
6 fields
FieldBitsWhat it does
AES_HW_CFG_GLITCHPROTECTION28Generic g_GlitchProtection value. BA411E-AES engine configuration.
BA411E_AES_HW_CFG_CXSWITCH27Generic g_CxSwitch value. BA411E-AES engine configuration.
BA411E_AES_HW_CFG_KEYSIZE26:24Generic g_Keysize value. BA411E-AES engine configuration.
BA411E_AES_HW_CFG_MASKING17Generic g_UseMasking value. BA411E-AES engine configuration.
BA411E_AES_HW_CFG_CS16Generic g_CS value. BA411E-AES engine configuration.
BA411E_AES_HW_CFG_MODE8:0Generic g_AesModesPoss value. BA411E-AES engine configuration.

Registers__BA411E_AES_HW_CFG_2Generic g_CtrSize value. BA411E-AES engine configuration.

Address
0x4F010408
Reset
0x00200080
Access
read only
Size
32-bit
3 fields
FieldBitsWhat it does
BA411E_AES_HW_CFG_2_IKGKEYS27:24Generic g_IKG_nb_AES_keys value. BA411E-AES engine configuration.
BA411E_AES_HW_CFG_2_EXTKEYS23:20Generic g_Ext_nb_AES_keys value. BA411E-AES engine configuration.
BA411E_AES_HW_CFG_2_CTRSIZE15:0Generic g_CtrSize value. BA411E-AES engine configuration.

Registers__BA413_HASH_HW_CFG

Address
0x4F01040C
Reset
0x0013003E
Access
read only
Size
32-bit
6 fields
FieldBitsWhat it does
BA413_HASH_HW_CFG_IKGKEYS27:24Generic g_IKG_nb_Hash_keys value. BA413-Hash engine configuration.
BA413_HASH_HW_CFG_EXTKEYS23:20Generic g_Ext_nb_Hash_keys value. BA413-Hash engine configuration.
BA413_HASH_HW_CFG_VERIFYDIGEST18Generic g_HashVerifyDigest value. BA413-Hash engine configuration.
BA413_HASH_HW_CFG_HMAC17Generic g_HMAC_enabled value. BA413-Hash engine configuration.
BA413_HASH_HW_CFG_PADDING16Generic g_HashPadding value. BA413-Hash engine configuration.
BA413_HASH_HW_CFG_MASK6:0Generic g_HashMaskFunc value. BA413-Hash engine configuration.

Registers__BA418_SHA3_HW_CFGGeneric g_Sha3CtxtEn value. BA418-SHA3 configuration.

Address
0x4F010410
Reset
0x00000000
Access
read only
Size
32-bit
1 field
FieldBitsWhat it does
BA418_SHA3_HW_CFG0Generic g_Sha3CtxtEn value. BA418-SHA3 configuration.

Registers__BA419_SM4_HW_CFGGeneric g_SM4ModesPoss value. BA419-SM4 engine configuration.

Address
0x4F010414
Reset
0x000001FF
Access
read only
Size
32-bit
1 field
FieldBitsWhat it does
BA419_SM4_HW_CFG8:0Generic g_SM4ModesPoss value. BA419-SM4 engine configuration.

Registers__BA424_ARIA_HW_CFGGeneric g_aria_modePoss value. BA424-Aria engine configuration.

Address
0x4F010418
Reset
0x0000017F
Access
read only
Size
32-bit
1 field
FieldBitsWhat it does
BA424_ARIA_HW_CFG8:0Generic g_aria_modePoss value. BA424-Aria engine configuration.

RNG_Control_Registers__ControlControl register

Address
0x4F011000
Reset
0x00040000
Access
read/write
Size
32-bit
17 fields
FieldBitsWhat it does
FifoWriteStartUp20Enable write of the samples in the FIFO during start-up.
Nb128BitBlocks19:16Number of 128 bit blocks used in AES-CBCMAC post-processing. This value cannot be zero.
AIS31TestSel15Select input to the AIS31 test module: 0: Before conditioning, 1: After conditioning.
HealthTestSel14Select input to health test module: 0: Before conditioning, 1: After conditioning.
AIS31Bypass13Bypass AIS31 tests such that the results of the start-up and online tests do not affect the FSM state.
HealthTestBypass12Bypass NIST tests such that the results of the start-up and online test do not affect the FSM state.
ForceActiveROs11Force oscillators to run when FIFO is full.
IntEnAlm10Interrupt enable for AIS31 noise alarm.
IntEnPre9Interrupt enable for AIS31 preliminary noise alarm.
SoftRst8Software reset: 0: Normal mode, 1: The continuous test, the conditioning function and the FIFO are reset. This bit is not cleared automatically.
IntEnFull7Interrupt enable for FIFO full.
IntEnProp5Interrupt enable for Adaptive Proportion Test failure (1024-sample window).
IntEnRep4Interrupt enable for Repetition Count Test failure.
CondBypass30: the conditioning function is used (normal mode), 1: the conditioning function is bypassed (to observe entropy source directly).
TestEn2Select input for conditioning function and continuous tests: 0: Noise source (normal mode), 1: Test data register (test mode).
LFSREn1Select between the NDRNG with asynchronous free running oscillators (when '0') and the Pseudo-Random generator with synchronous oscillators for simulation purpose (when '1').
Enable0Enable the NDRNG.

RNG_Control_Registers__FIFOLevelFIFO level register.

Address
0x4F011004
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
FIFOLevel31:0Number of 32 bits words of random available in the FIFO. Any write to this register clears the FullInt flag in the Status register.

Control_Registers__FIFOThresholdFIFO threshold register.

Address
0x4F011008
Reset
0x00000001
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
FIFOThreshold1:0FIFO level below which the module leaves the idle state to refill the FIFO, expressed in number of 128bit blocks.

RNG_Control_Registers__FIFODepthFIFO depth register.

Address
0x4F01100C
Reset
0x00000008
Access
read only
Size
32-bit
1 field
FieldBitsWhat it does
FIFODepth31:0Maximum number of 32 bits words that can be stored in the FIFO: 2**g_fifodepth.

RNG_Control_Registers__Key0Key register (MSB).

Address
0x4F011010
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
Key031:0Key register (MSB).

RNG_Control_Registers__Key1Key register.

Address
0x4F011014
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
Key131:0Key register.

RNG_Control_Registers__Key2Key register.

Address
0x4F011018
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
Key231:0Key register.

RNG_Control_Registers__Key3Key register (LSB).

Address
0x4F01101C
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
Key331:0Key register (LSB).

RNG_Control_Registers__TestDataTest data register.

Address
0x4F011020
Reset
0x00000000
Access
write only
Size
32-bit
1 field
FieldBitsWhat it does
TestData31:0Test data register.

Registers__RepeatThresholdRepetition Test Count Cut-Off value.

Address
0x4F011024
Reset
0x00000029
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
RepeatThreshold5:0Repetition Test Count Cut-Off value.

Control_Registers__PropThresholdAdaptive Proportion Test (1024-sample window) Cut-Off value.

Address
0x4F011028
Reset
0x00000319
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
PropThreshold9:0Adaptive Proportion Test (1024-sample window) Cut-Off value.

RNG_Control_Registers__StatusStatus register.

Address
0x4F011030
Reset
0x00000000
Access
read/write
Size
32-bit
9 fields
FieldBitsWhat it does
FifoAccFail11Set when a FIFO data read is performed while the NDRNG is disabled AND has its FIFO empty (FIFOLevel = 0).
StartUpFail10Start-up test failure.
AlmInt9AIS31 noise alarm interrupt status.
PreInt8AIS31 preliminary noise alarm interrupt status.
FullInt7FIFO full status.
PropFail5NIST-800-90B adaptive Proportion Test (1024-sample window) interrupt status.
RepFail4NIST-800-90B repetition Count Test interrupt status.
State3:1State of the control FSM: 000: Reset, 001: Startup, 010: Idle (Rings On), 011: Idle (Rings Off), 100: Fill FIFO, 101: Error, 110: Unused, 111: Unused.
TestDataBusy0High when data written to TestData register is being processed. (see section 4.7)

Control_Registers__InitWaitValInitial wait counter value.

Address
0x4F011034
Reset
0x0000FFFF
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
InitWaitVal15:0Number of clock cycles to wait before sampling data from the noise source.

Control_Registers__DisableOsc0Disable oscillator rings #0 to #31.

Address
0x4F011038
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
DisableOsc031:0Disable oscillator rings #0 to #31.

Control_Registers__DisableOsc1Disable oscillator rings #32 to #63.

Address
0x4F01103C
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
DisableOsc131:0Disable oscillator rings #32 to #63.

Control_Registers__SwOffTmrValSwitch off timer value.

Address
0x4F011040
Reset
0x0000FFFF
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
SwOffTmrVal15:0Number of clk cycles to wait before stopping the rings after the FIFO is full.

RNG_Control_Registers__ClkDivSample clock divider.

Address
0x4F011044
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
ClkDiv7:0Sample clock divider. The frequency at which the outputs of the rings are sampled is given by: Fs=Fpclk/(ClkDiv+1).

Control_Registers__AIS31Conf0AIS31 configuration register 0.

Address
0x4F011048
Reset
0x00000000
Access
read/write
Size
32-bit
2 fields
FieldBitsWhat it does
StartUpThreshold15:0Start-up test threshold.
OnlineThreshold31:16Online threshold.

Control_Registers__AIS31Conf1AIS31 configuration register 1.

Address
0x4F01104C
Reset
0x00000000
Access
read/write
Size
32-bit
2 fields
FieldBitsWhat it does
OnlineRepThreshold15:0Online repeat threshold.
HExpectedValue31:16Expected history value.

Control_Registers__AIS31Conf2AIS31 configuration register 2.

Address
0x4F011050
Reset
0x00000000
Access
read/write
Size
32-bit
2 fields
FieldBitsWhat it does
HMin15:0Minimum allowed history value.
HMa31:16Maximum allowed history value.

Control_Registers__AIS31StatusAIS31 status register.

Address
0x4F011054
Reset
0x00000000
Access
read/write
Size
32-bit
3 fields
FieldBitsWhat it does
PrelimNoiseAlarmRep17Last preliminary noise alarm occurred due to consecutive high X**2.
PrelimNoiseAlarmRng16Last preliminary noise alarm occurred due to history value out of range.
NumPrelimAlarms15:0Number of preliminary noise alarms since counter was last cleared.

RNG_Control_Registers__HwConfigHardware configuration register.

Address
0x4F011058
Reset
0x00000037
Access
read only
Size
32-bit
3 fields
FieldBitsWhat it does
AIS31Full9Generic g_AIS31Full value.
AIS318Generic g_AIS31 value.
NumbOfRings7:0Generic g_NumRings value.

PK_Registers__PointersPointers register.

Address
0x4F012000
Reset
0x00000000
Access
read/write
Size
32-bit
4 fields
FieldBitsWhat it does
OpPtrN27:24When executing primitive arithmetic operations, this pointer defines the location where the modulus is located in memory (location 0x0 to 0xF).
OpPtrC19:16When executing primitive arithmetic operations, this pointer defines the location (0x0 to 0xF) where the result will be stored in memory.
OpPtrB11:8When executing primitive arithmetic operations, this pointer defines where operand B is located in memory (location 0x0 to 0xF).
OpPtrA3:0When executing primitive arithmetic operations, this pointer defines where operand A is located in memory (location 0x0 to 0xF).

PK_Registers__CommandCommand register.

Address
0x4F012004
Reset
0x0000000F
Access
read/write
Size
32-bit
12 fields
FieldBitsWhat it does
FlagB30See operation description.
FlagA29See operation description.
SwapBytes28Swap the bytes on AHB interface: '0': Native format (little endian) '1': Byte swapped (big endian) See also section 4.2.1. This bit must be programmed before writing/reading any data in data memory.
Edwards26Enable Edwards curve (see operation description).
RandProj25Enable randomization of projective coordinates (counter-measure).
RandKE24Enable randomization of exponent/scalar (counter-measure).
SelCurve22:20Enable accelerator for specific curve modulus: 0x0: No acceleration (default) 0x1: P256 0x2: P384 0x3: P521 0x4: P192 0x5: Curve25519 0x6: Ed25519 This field has no effect when the optional acceleration hardware is not included.
RandMod19Enable randomization of modulus (counter-measure).
OpBytesM117:8This field defines the size (= number of bytes minus one) of the operands for the current operation. Possible values are limited by the maximum supported operand size. Examples: - 0x014 -> ECC on curve K-163 - 0x01F -> ECC on curve P-256 - 0x02F -> ECC on curve P-384 - 0x033 -> ECC on curve K-409 -
FieldF7'0': Field is GF(p) '1': Field is GF(2**m)
OpeAddr6:0This field defines the operation to be performed. See documentation for more details.
CalcR231This bit indicates if the IP has to calculate R**2 mod N for the next operation. This bit must be set to '1' when a new prime number has been programmed. This bit is used for primitive operations and ignored for the other operations. '0': don't recalculate R**2 mod N '1': re-calculate R**2 mod N

PK_Registers__ControlCommand register.

Address
0x4F012008
Reset
0x00000000
Access
write only
Size
32-bit
2 fields
FieldBitsWhat it does
ClearIRQ1Writing a '1' clears the IRQ output.
Start0Writing a '1' starts the processing.

PK_Registers__StatusStatus register.

Address
0x4F01200C
Reset
0x00000000
Access
read only
Size
32-bit
4 fields
FieldBitsWhat it does
FailPtr28:24These bits indicate which data location generated the error flag. They are not available for all error flags.
IntrptStatus17This bit reflects the IRQ output value. It is set when the operation is finished. It is cleared when the CPU writes the bit 1 of Control Register.
PK_Busy16This bit reflects the BUSY output value. It is set when the operation starts and it is cleared when the operation is finished.
ErrorFlags15:4These bits indicate an error condition. They are updated at the end of the operation. They are cleared when starting a new operation. See documentation for more details.

PK_Registers__TimerTimer register.

Address
0x4F012014
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
Timer31:1Number of core clock cycles.

PK_Registers__HwConfigHardware configuration register.

Address
0x4F012018
Reset
0x43F30200
Access
read only
Size
32-bit
14 fields
FieldBitsWhat it does
DisableClrMem30State of DisableClrMem input (high when automatic clear of the RAM after reset is disabled).
DisableSM29State of DisableSMx input (high when SM2/SM9 operations are disabled).
AHBMaster25'0': Memory access through AHB Slave and internally in the PKE. '1': Memory access through AHB Master, outside the PKE.
X2551924Support Curve25519/Ed25519 acceleration.
P19223Support ECC P192 acceleration.
P52122Support ECC P521 acceleration.
P38421Support ECC P384 acceleration.
P25620Support ECC P256 acceleration.
ECC18Support RAM error correction.
BinaryField17Support binary field.
PrimeField16Support prime field.
NbMult15:12Number of multipliers: 0x0: 1 multiplier 0x1: 4 multipliers 0x2: 16 multipliers 0x4: 64 multipliers 0x8: 256 multipliers
MaxOpSize11:0Maximum operand size (number of bytes).
DisableCM31State of DisableCM input (high when counter-measures are disabled).

PK_Registers__OpSizeOperand size register.

Address
0x4F01201C
Reset
0x00001000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
OpSize12:0Operand size (number of bytes): 0x0100: 256 0x0209: 521 0x0800: 2048 0x0C00: 3072 0x1000: 4096 This register is used when the memory is accessed via AHB Master

PK_Registers__MemOffsetMemory offset register.

Address
0x4F012020
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
MemOffset31:0Memory offset for AHB Master

PK_Registers__MicroCodeOffsetMicroCode offset register.

Address
0x4F012024
Reset
0x00000000
Access
read/write
Size
32-bit
1 field
FieldBitsWhat it does
MicroCodeOffset31:0MicroCode offset for AHB Master