diff --git a/board/xilinx/zynqmp/cmds.c b/board/xilinx/zynqmp/cmds.c
index ea404d5..fadb0ed 100644
--- a/board/xilinx/zynqmp/cmds.c
+++ b/board/xilinx/zynqmp/cmds.c
@@ -14,16 +14,7 @@
 #include <asm/arch/hardware.h>
 #include <asm/arch/sys_proto.h>
 #include <asm/io.h>
-
-struct aes {
-	u64 srcaddr;
-	u64 ivaddr;
-	u64 keyaddr;
-	u64 dstaddr;
-	u64 len;
-	u64 op;
-	u64 keysrc;
-};
+#include <mach/zynqmp_aes.h>
 
 static int do_zynqmp_verify_secure(struct cmd_tbl *cmdtp, int flag, int argc,
 				   char *const argv[])
@@ -121,9 +112,7 @@
 static int do_zynqmp_aes(struct cmd_tbl *cmdtp, int flag, int argc,
 			 char * const argv[])
 {
-	ALLOC_CACHE_ALIGN_BUFFER(struct aes, aes, 1);
-	int ret;
-	u32 ret_payload[PAYLOAD_ARG_CNT];
+	ALLOC_CACHE_ALIGN_BUFFER(struct zynqmp_aes, aes, 1);
 
 	if (zynqmp_firmware_version() <= PMUFW_V1_0) {
 		puts("ERR: PMUFW v1.0 or less is detected\n");
@@ -142,40 +131,14 @@
 	aes->keysrc = hextoul(argv[6], NULL);
 	aes->dstaddr = hextoul(argv[7], NULL);
 
-	if (aes->srcaddr && aes->ivaddr && aes->dstaddr) {
-		flush_dcache_range(aes->srcaddr,
-				   (aes->srcaddr +
-				    roundup(aes->len, ARCH_DMA_MINALIGN)));
-		flush_dcache_range(aes->ivaddr,
-				   (aes->ivaddr +
-				    roundup(IV_SIZE, ARCH_DMA_MINALIGN)));
-		flush_dcache_range(aes->dstaddr,
-				   (aes->dstaddr +
-				    roundup(aes->len, ARCH_DMA_MINALIGN)));
-	}
-
 	if (aes->keysrc == 0) {
 		if (argc < cmdtp->maxargs)
 			return CMD_RET_USAGE;
 
 		aes->keyaddr = hextoul(argv[8], NULL);
-		if (aes->keyaddr)
-			flush_dcache_range(aes->keyaddr,
-					   (aes->keyaddr +
-					    roundup(KEY_PTR_LEN,
-						    ARCH_DMA_MINALIGN)));
 	}
 
-	flush_dcache_range((ulong)aes, (ulong)(aes) +
-			   roundup(sizeof(struct aes), ARCH_DMA_MINALIGN));
-
-	ret = xilinx_pm_request(PM_SECURE_AES, upper_32_bits((ulong)aes),
-				lower_32_bits((ulong)aes), 0, 0, ret_payload);
-	if (ret || ret_payload[1])
-		printf("Failed: AES op status:0x%x, errcode:0x%x\n",
-		       ret, ret_payload[1]);
-
-	return ret;
+	return zynqmp_aes_operation(aes);
 }
 
 #ifdef CONFIG_DEFINE_TCM_OCM_MMAP
