ARM: davinci: uart: move to devid based clk_get

For modules having single clock, clk_get should be done with dev_id.
But current davinci implementation handles multiple instances
of the UART devices with single platform_device_register. Hence clk_get
is based on con_id rather than dev_id, this is not correct. Do
platform_device_register for each instance and clk_get on dev_id.

Signed-off-by: Manjunathappa, Prakash <prakash.pm@ti.com>
[nsekhar@ti.com: actually stop using con_id in clk_get(), squash the
		 patch adding OF aux data into this one]
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
drm/gma500: Add generic code for clock calculation

This patch aims to unify the bits and pieces that are common (or similar
enough) for pll clock calculations. Nothing makes use of this code yet
That will come in later patches.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/cdv: Make use of the generic clock code

Add chip specific callbacks for the generic and non-generic clock
calculation code. Also remove as much dupilicated code as possible.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500: Make use of gma_pipe_has_type()

Replace any use of xxx_intel_pipe_has_type() with the generic
gma_pipe_has_type() function. Poulsbo still use it but that will be
removed when we rip out psb_intel_pipe_has_type().

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/psb: Make use of generic clock code

Add chip specific callbacks for the generic and non-generic clock
calculation code. Also remove as much dupilicated code as possible.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500: Remove the unused psb_intel_display.h

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500: Add generic pipe/crtc functions

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/cdv: Use identical generic crtc funcs

This patch makes cdv use the gma_xxx counterparts that are identical. I
took them in one sweep as they should not cause any regressions.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500: Make all chips use gma_wait_for_vblank

Also remove the duplicated oaktrail function.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/psb: Use identical generic crtc funcs

This patch makes psb use the gma_xxx counterparts that are identical. I
took them in one sweep as they should not cause any regressions.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/cdv: Convert to gma_pipe_set_base()

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500: Add IS_CDV() macro

This macro is needed for Cedarview specific stuff in the generic gma
functions.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/cdv: Convert to gma_crtc_dpms()

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/cdv: Convert to generic gamma funcs

There is a slight difference in how we pick the palette register in the
generic function but we should be ok as long as psb_intel_crtc->pipe and
the register map is sane.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/psb: Convert to gma_pipe_set_base()

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500: Convert to generic gamma funcs

This takes care of the remaining chips using the old generic code.
We don't check if the pipe number is valid but the old code peeked in
the register map before checking anyways so just ignore it.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/psb: Convert to gma_crtc_dpms()

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/oak: Use identical generic crtc funcs

Use the generic gma functions instead of the oaktrail functions where
they are identical.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/mdfld: Use identical generic crtc funcs

Use the generic gma functions instead of the medfield functions where
they are identical.

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drm/gma500/psb: Convert to generic crtc->destroy

Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>