linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* PXA 2xx devictree port and clock infrastructure
@ 2014-05-27 13:02 Robert Jarzmik
  2014-05-27 15:17 ` Arnd Bergmann
  2014-06-05  3:01 ` Andrew Ruder
  0 siblings, 2 replies; 8+ messages in thread
From: Robert Jarzmik @ 2014-05-27 13:02 UTC (permalink / raw)
  To: linux-arm-kernel

Hi guys,

I'm playing with devicetree to port the mioa701 machine code to devicetree (or
rather to eliminate the mioa701 machine code).

While porting the pxa2xx device drivers, I came to a question about the clock
infrastructure, and I'd need a bit of guidance.

Many drivers, in their probe code are doing something like :
	1) regs = platform_get_resource(pdev, IORESOURCE_MEM, 0);
	2) irq = platform_get_irq(pdev, 0);
	3) clk = clk_get(&pdev->dev, NULL);

Points 1 and 2 are straightforward with DT. Point 3 is not so obvious to me.

As there is no platform data anymore, the clock infrastructure wants to match
the OF device (in my case udc at 40600000) with the registered
clocks. Unfortunately, the registered clock is named "pxa27x-udc", which works
well in "platform data" devices, but not in devicetree populated devices.

Therefore, I'd like to know what to do, and an example in another platform would
be great. Should I create a clkdev driver in drivers/clk, or is there another
... faster way ? And Daniel, you probably solved it already for
arch/arm/mach-pxa/pxa-dt.c, didn't you ?

Thanks for your insights.

Cheers.

-- 
Robert

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2014-06-07 18:49 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-27 13:02 PXA 2xx devictree port and clock infrastructure Robert Jarzmik
2014-05-27 15:17 ` Arnd Bergmann
2014-05-27 15:43   ` Mark Rutland
2014-05-27 15:49     ` Arnd Bergmann
2014-05-27 23:20       ` Robert Jarzmik
2014-05-28  1:05         ` Mike Turquette
2014-06-05  3:01 ` Andrew Ruder
2014-06-07 18:49   ` Robert Jarzmik

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).