staging: drm/omap: platform data structs moved to plat-omap

Platform data structs populated when the platform device is registered
need to be #include'able under arch/arm/..., but having to #include
headers from drivers/staging is messy.  Instead these structs are
moved to arch/arm/plat-omap/include/plat.

Signed-off-by: Rob Clark <rob@ti.com>
staging: omap/drm: dmm should return proper errors

Minor error path clean-up.

Signed-off-by: Rob Clark <rob@ti.com>
drm: add drm_property_change_is_valid

Move code from drm_mode_connector_property_set_ioctl to a new
function, so we can reuse this code when we add crtc properties.

v2: use bool instead of int

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
drm: WARN() when drm_connector_attach_property fails

Also return void instead of int. We have more than 100 callers and
no one checks for the return value.

If this function fails the property won't be exposed by the get/set
ioctls, but we should probably survive. If this starts happening,
the solution will be to increase DRM_CONNECTOR_MAX_PROPERTY and
recompile the Kernel.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
drm: create struct drm_object_properties and use it

For now, only connectors have it. In the future, all objects that need
properties should use it. Since the strucutre is referenced inside
struct drm_mode_object, we will be able to deal with object properties
without knowing the real type of the object.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
drm: add generic ioctls to get/set properties on any object

Useless for connector properties (since they already have their own
ioctls), but useful when we add properties to CRTCs, planes and other
objects.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
drm: make the connector properties code use the object properties code

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
drm: add CRTC properties

The i915 driver needs this for the rotation and overscan compensation
properties. Other drivers might need this too.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
drm: add bitmask property type

A bitmask property is similar to an enum.  The enum value is a bit
position (0-63), and valid property values consist of a mask of
zero or more of (1 << enum_val[n]).

TODO: word commit msg better
drm: add plane properties

The omapdrm driver uses this for setting per-overlay rotation.  It
is likely also useful for setting YUV->RGB colorspace conversion
matrix, etc.
drm: support for rotated scanout

For drivers that can support rotated scanout, the extra parameter
checking in drm-core, while nice, tends to get confused.  To solve
this drivers can set the crtc or plane invert_dimensions field so
that the dimension checking takes into account the rotation that
the driver is performing.
staging: drm/omap: dmabuf/prime support
WIP: tiler/2d support for DSS

updated to use properties, and re-work the omapdss part a bit
WIP: drm/omap: add plugin API
WIP: staging: drm/omap: dmabuf/prime mmap support

There are still a few places to cleanup, and possibly things can be
made a bit easier for individual drm drivers by some helpers in drm
core.  But this is enough for a proof of concept.

With this, I can allocate cached buffers, fill them w/ software from
userspace, and on kernel side with fault handling and PTE shootdown
track which pages must be flushed to simulate coherency.

Fyi, you can find my kernel branch, with this patch on top of Daniel's
dmabuf mmap patch, here:

https://github.com/robclark/kernel-omap4/commits/dmabuf/mmap
staging: drm/omap: fix NULL pointer dereference

Make sure we do not dereference NULL pointers when things go wrong in
omap_framebuffer_replace.

Signed-off-by: Vincent Stehlé <v-stehle@ti.com>
Add GPU device & hwmod

Signed-off-by: Vincent Stehlé <v-stehle@ti.com>
Create omap_drm/drv links

Signed-off-by: Vincent Stehlé <v-stehle@ti.com>
Hack! Force HDMI detect & HPD

Useful with my DELL monitor + HDMI2DVI converter with µEVM.

Signed-off-by: Vincent Stehlé <v-stehle@ti.com>
Tweak config!

Signed-off-by: Vincent Stehlé <v-stehle@ti.com>