@@ -191,6 +191,8 @@ obj-$(CONFIG_CMD_SPL) += cmd_spl.o
obj-$(CONFIG_CMD_ZIP) += cmd_zip.o
obj-$(CONFIG_CMD_ZFS) += cmd_zfs.o
+obj-$(CONFIG_ARM64) += cmd_armv8svchvc.o
+
# others
obj-$(CONFIG_BOOTSTAGE) += bootstage.o
obj-$(CONFIG_CONSOLE_MUX) += iomux.o
new file mode 100644
@@ -0,0 +1,60 @@
+/*
+ * (C) Copyright 2016
+ * Robert Bosch Car Multimedia GmbH
+ * Dirk Behme <dirk.behme@de.bosch.com>
+ *
+ * SPDX-License-Identifier: GPL-2.0+
+ */
+
+#include <common.h>
+#include <command.h>
+
+static int do_smc(cmd_tbl_t *cmdtp, int flag, int argc, char * const
argv[])
+{
+ struct pt_regs regs;
+
+ memset(®s, 0, sizeof(struct pt_regs));
+
+ switch (argc) {
+ case 9:
+ regs.regs[7] = simple_strtoul(argv[8], NULL, 16);
+ /* fall through */
+ case 8:
+ regs.regs[6] = simple_strtoul(argv[7], NULL, 16);
+ /* fall through */
+ case 7:
+ regs.regs[5] = simple_strtoul(argv[6], NULL, 16);
+ /* fall through */
+ case 6:
+ regs.regs[4] = simple_strtoul(argv[5], NULL, 16);
+ /* fall through */
+ case 5:
+ regs.regs[3] = simple_strtoul(argv[4], NULL, 16);
+ /* fall through */
+ case 4:
+ regs.regs[2] = simple_strtoul(argv[3], NULL, 16);
+ /* fall through */
+ case 3:
+ regs.regs[1] = simple_strtoul(argv[2], NULL, 16);
+ /* fall through */
+ case 2:
+ regs.regs[0] = simple_strtoul(argv[1], NULL, 16);
+ break;
+ default:
+ return CMD_RET_USAGE;
+ }
+
+ smc_call(®s);
+
+ printf("ret: x0: 0x%016luX\n x1: 0x%016luX\n x2: 0x%016luX
x3: 0x%016lX\n",
+ regs.regs[0], regs.regs[1], regs.regs[2], regs.regs[3]);
+
+ return 0;
+}
+
+U_BOOT_CMD(
+ smc , 9, 0, do_smc,
+ "do ARMv8 hypervisor call (SMC)",
+ "x0 [x1 x2 x3 x4 x5 x6 x7]\n"