When there is no message before the lifeline activation statement, the deactivation of the same lifeline immediately adjacent to it cannot take effect
below is the code and result:
@startuml
Entity PKG
Entity MMU
Boundary TDB
Boundary RDB
PKG -> MMU : 1
activate PKG
activate MMU
MMU -> PKG : 2
deactivate MMU
PKG -> TDB : Send Packet
deactivate PKG
activate TDB
deactivate TDB
TDB -> RDB : Send Packet
activate RDB
deactivate RDB
@enduml

as you can see, deactivation of TDB is not work but the deactivation of RDB is work