HASH/HMAC Engine
System
Configuration
Registers
In
te
rf
a
ce
t
o
µ
D
MA
a
n
d
I
n
te
rru
p
t
H
a
n
d
le
r
Clock
Generator
Hash Core
Control
H
a
sh
Sch
e
d
u
le
r
µDMA
Interrupt
Handler
Host
Interface
Bank
SHA/MD5 Functional Description
1587
SLAU723A – October 2017 – Revised October 2018
Copyright © 2017–2018, Texas Instruments Incorporated
SHA/MD5 Accelerator
25.1 SHA/MD5 Functional Description
25.1.1 SHA/MD5 Block Diagram
shows the module architecture, which consists of four primary blocks: the Hash/HMAC
engine, configuration registers, the interface to µDMA, and the interrupt handler.
Figure 25-1. SHA/MD5 Module Block Diagram
25.1.1.1 Configuration Registers
The configuration registers contain the following global control and status registers for the SHA/MD5
module:
•
System control register that controls the mode of operation (SHA_SYSCONFIG register)
•
µDMA interrupt control registers (SHA_DMAIM, SHA_DMARIS, SHA_DMAMIS, and SHA_DMAIC
registers, which reside in the Encryption Control Base address space)
•
Interrupt status register (SHA_IRQSTATUS register)
•
Enable register (SHA_IRQENABLE register)
25.1.1.2 Hash/HMAC Engine
The Hash/HMAC engine performs the SHA-1, SHA-2, or MD5 hash computation. When loaded with a data
block, and optionally an intermediate digest, it independently performs the hash computation (64 or 80
rounds, depending on the algorithm) on that data block.
It can also start from the specified initial digest values instead of a loaded intermediate. Furthermore, it
can perform the IPAD and OPAD XORs for MAC operations. The hash core does not perform any hash
padding; this is performed in the Host Interface Block, where the data input registers are located. A loaded
data block must always be a full 64 bytes (512 bits) long.
25.1.1.3 Hash Core Control
When the hash core is idle or done, a new hash operation can be started. Any additional information
needed by the hash core (mode of operation, data to process, input digest if not starting from algorithm
constants or continuing) must be provided by programming the SHA registers before the core can accept
the operation.