[PATCH 1/6] Common: define scopes a specific hardware or software feature can cope with

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

 



This change adds an enum to define a scope to be used in frameworks which
have to select a feature specific to a scope. These defines will be used
in the following changes in the 'reset reason', 'machine restart' and
'watchdog' framework. These three frameworks need this kind of information
to select a proper feature provider or source.

Signed-off-by: Juergen Borleis <jbe@xxxxxxxxxxxxxx>
---
 include/fscope.h | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)
 create mode 100644 include/fscope.h

diff --git a/include/fscope.h b/include/fscope.h
new file mode 100644
index 0000000..186249b
--- /dev/null
+++ b/include/fscope.h
@@ -0,0 +1,29 @@
+/*
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+
+#ifndef __INCLUDE_FSCOPE_H
+# define __INCLUDE_FSCOPE_H
+
+/* define a scope some hardware feature can cope with */
+enum f_scope {
+	FEATURE_SCOPE_UNKNOWN,
+	FEATURE_SCOPE_CPU,
+	FEATURE_SCOPE_SOC,
+	FEATURE_SCOPE_MACHINE,
+};
+
+#define NAME_FEATURE_SCOPE_UNKNOWN "unknown"
+#define NAME_FEATURE_SCOPE_CPU "cpu"
+#define NAME_FEATURE_SCOPE_SOC "soc"
+#define NAME_FEATURE_SCOPE_MACHINE "machine"
+
+#endif /* __INCLUDE_FSCOPE_H */
-- 
2.1.4


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux