Optimize the key switching mechanism to set the key only if a different operation is performed with the context. Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>