Source-Changes-HG archive

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

[src/trunk]: src/sys/external/bsd/drm2/include/linux Stub out clk API if no FBT.



details:   https://anonhg.NetBSD.org/src/rev/69058ab19edc
branches:  trunk
changeset: 992837:69058ab19edc
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Mon Aug 27 07:57:22 2018 +0000

description:
Stub out clk API if no FBT.

diffstat:

 sys/external/bsd/drm2/include/linux/clk.h |  22 +++++++++++++++++++++-
 1 files changed, 21 insertions(+), 1 deletions(-)

diffs (36 lines):

diff -r cf902a16158c -r 69058ab19edc sys/external/bsd/drm2/include/linux/clk.h
--- a/sys/external/bsd/drm2/include/linux/clk.h Mon Aug 27 07:57:12 2018 +0000
+++ b/sys/external/bsd/drm2/include/linux/clk.h Mon Aug 27 07:57:22 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: clk.h,v 1.2 2018/08/27 07:33:27 riastradh Exp $        */
+/*     $NetBSD: clk.h,v 1.3 2018/08/27 07:57:22 riastradh Exp $        */
 
 /*-
  * Copyright (c) 2018 The NetBSD Foundation, Inc.
@@ -32,6 +32,26 @@
 #ifndef        _LINUX_CLK_H_
 #define        _LINUX_CLK_H_
 
+/* XXX Use FDT as a proxy for clk API until we have a clk flag.  */
+
+#ifdef _KERNEL_OPT
+#include "opt_fdt.h"
+#endif
+
+#ifdef FDT
+
 #include <dev/clk/clk.h>
 
+#else
+
+struct clk;
+
+static inline unsigned
+clk_get_rate(struct clk *clk)
+{
+       panic("unreachable");
+}
+
+#endif
+
 #endif /* _LINUX_CLK_H_ */



Home | Main Index | Thread Index | Old Index