Re: [PATCH v2 04/11] gunyah: Common types and error codes for Gunyah hypercalls

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 02/08/2022 00:12, Elliot Berman wrote:
Add architecture-independent standard error codes, types, and macros for
Gunyah hypercalls.

Signed-off-by: Elliot Berman <quic_eberman@xxxxxxxxxxx>
---
  MAINTAINERS            |  1 +
  include/linux/gunyah.h | 75 ++++++++++++++++++++++++++++++++++++++++++
  2 files changed, 76 insertions(+)
  create mode 100644 include/linux/gunyah.h

diff --git a/MAINTAINERS b/MAINTAINERS
index 02f97ac90cdf..2e4f1d9ed47b 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -8744,6 +8744,7 @@ S:	Maintained
  F:	Documentation/devicetree/bindings/firmware/gunyah-hypervisor.yaml
  F:	Documentation/virt/gunyah/
  F:	arch/arm64/include/asm/gunyah.h
+F:	include/linux/gunyah.h
HABANALABS PCI DRIVER
  M:	Oded Gabbay <ogabbay@xxxxxxxxxx>
diff --git a/include/linux/gunyah.h b/include/linux/gunyah.h
new file mode 100644
index 000000000000..69931a0f5736
--- /dev/null
+++ b/include/linux/gunyah.h
@@ -0,0 +1,75 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+/*
+ * Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
+ */
+
+#ifndef _GUNYAH_H
+#define _GUNYAH_H
+
+#include <linux/types.h>
+#include <linux/errno.h>
+#include <asm/gunyah.h>
+
+typedef u64 gh_capid_t;

I think there was a rule on typedefs? Maybe I'm mistaken, couldn't find one. Why do you need it in the first place? Just use u64. Or 'enum gh_capid'.

+
+/* Common Gunyah macros */
+#define GH_CAPID_INVAL	U64_MAX
+



--
With best wishes
Dmitry



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [Linux for Sparc]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux