Thread (18 messages) 18 messages, 5 authors, 2012-08-14

Re: [PATCH v2 2/2] powerpc/mpic: add global timer support

From: Gala Kumar-B11780 <hidden>
Date: 2012-08-10 20:24:43

On Aug 10, 2012, at 2:40 PM, Scott Wood wrote:
On 08/10/2012 12:54 AM, Dongsheng.wang@freescale.com wrote:
quoted
+static const struct of_device_id mpic_timer_ids[] =3D {
+	{ .compatible =3D "open-pic,global-timer", },
+	{ .compatible =3D "fsl,global-timer", },
+	{},
+};
+
+static int __init mpic_timer_init(void)
+{
+	struct device_node *np =3D NULL;
+
+	for_each_node_by_type(np, "open-pic")
+		if (of_match_node(mpic_timer_ids, np))
+			group_init(np);
+
+	if (list_empty(&group_list))
+		return -ENODEV;
+
+	return 0;
+}
+arch_initcall(mpic_timer_init);
=20
=20
Where do you distinguish an FSL timer from an openpic timer?  I thought
openpic timers didn't support cascading.
in group_init()

+	if (of_device_is_compatible(np, "fsl,global-timer"))
+		priv->flags |=3D FSL_GLOBAL_TIMER;
+

- k
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help