Commit graph

4122 commits

Author SHA1 Message Date
Axel Lin b57287ba49 video: platinumfb: Add __devexit_p at necessary place
According to the comments in include/linux/init.h:

"Pointers to __devexit functions must use __devexit_p(function_name), the
wrapper will insert either the function_name or NULL, depending on the config
options."

We have __devexit annotation for platinumfb_remove(), thus add __devexit_p at
necessary place.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-15 00:19:58 +00:00
Florian Tobias Schandinat ef26b7943c Merge branch 'for-florian' of git://gitorious.org/linux-omap-dss2/linux into fbdev-next 2011-10-15 00:19:52 +00:00
Florian Tobias Schandinat 07aaae44f5 Merge commit 'v3.1-rc9' into fbdev-next 2011-10-15 00:14:01 +00:00
Arnd Bergmann 97b09da4ee ARM: pxa: use correct __iomem annotations
This tries to clear up the confusion between integers and iomem pointers
in the marvell pxa platform. MMIO addresses are supposed to be __iomem*
values, in order to let the Linux type checking work correctly. This
patch moves the cast to __iomem as far back as possible, to the place
where the MMIO virtual address windows are defined.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2011-10-08 21:03:07 +08:00
Eric Miao c9d1917c63 ARM: pxa: make pxafb_smart_*() empty when not enabled
Reported-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2011-10-08 21:03:04 +08:00
Timur Tabi 07a0621403 drivers/video: fsl-diu-fb: merge diu_pool into fsl_diu_data
The diu_pool structure contains diu_addr objects for various objects
allocated in DMA space that are used by the DIU, but the only instance
of this structure is a global variable, 'pool'.  Eliminate 'pool' by
merging its fields into the fsl_diu_data structure, which is instantiated
on the heap for each DIU controller found.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:16:36 +00:00
Timur Tabi 3c755b7c09 drivers/video: fsl-diu-fb: merge diu_hw into fsl_diu_data
The diu_hw structure contains two fields used to access the DIU registers,
but the only instance of this structure is a global variable, 'dr'.
Eliminate 'dr' by merging its fields into the fsl_diu_data structure,
which is instantiated on the heap for each DIU controller found.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:10:12 +00:00
Timur Tabi c4e5a02327 drivers/video: fsl-diu-fb: only DIU modes 0 and 1 are supported
The Freescale DIU video controller supports five video "modes", but only
the first two are used by the driver.  The other three are special modes
that don't make sense for a framebuffer driver.  Therefore, there's no
point in keeping a global variable that indicates which mode we're
supposed to use.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:10:12 +00:00
Timur Tabi 7e47c21195 drivers/video: fsl-diu-fb: remove unused panel operating mode support
The MFB_TYPE_xxx macros indicate different "operating modes" of each AOI,
but this feature is not actually used in the driver.  The mfb_index.type
field is always set to MFB_TYPE_OUTPUT, so just delete it and any code
that references it.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:10:12 +00:00
Timur Tabi 2572df91d5 drivers/video: fsl-diu-fb: use an enum for the AOI index
Each of the five AOIs created by the DIU driver has a special purpose, and
they're not treated equally.  It makes sense to identify them with an enum
instead of a hard-coded number.

Since the 'index' is now an enum, it can only contain allowed values, so
there's no need to check for an invalid value.  This simplifies some other
code, such as fsl_diu_disable_panel(), which no longer needs to return an
error code.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:10:12 +00:00
Timur Tabi 760af8f83d drivers/video: fsl-diu-fb: add several new video modes
Add the following new video modes to the Freescale DIU framebuffer driver:

640x480x60
640x480x72
640x480x75
640x480x90
640x480x100
800x480x60
800x600x60
854x480x60
1280x480x60
1280x720x60
1920x1080x60

Also add margin data to the 320x240 video mode.  This mode was originally
intended only for the AOIs (overlays) used on planes two and three, but with
real margin data, it can now be used as an actual video mode.
Video mode data is from earlier work done by Jerry Huang
<Chang-Ming.Huang@freescale.com>.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:10:12 +00:00
Timur Tabi 1738f6f84f drivers/video: fsl-diu-fb: remove broken screen blanking support
The function which is supposed to provide screen blanking support doesn't
actually do anything, so the framebuffer layer thinks the screen has
been blanked when it really isn't.  Remove the code completely for now.

A side-effect of this change is that the framebuffer console blanking now
works correctly.  Presumably this is because the console now receives -EINVAL
instead of '0' when it asks the driver to blank the screen, so the console
does it manually now.

A signficant refactoring of the driver is planned, and proper hardware
blanking support will added afterwards.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:10:12 +00:00
Timur Tabi b715f9f04c drivers/video: fsl-diu-fb: move some definitions out of the header file
Move several macros and structures from the Freescale DIU driver's header
file into the source file, because they're only used by that file.  Also
delete a few unused macros.

The diu and diu_ad structures cannot be moved because they're being used
by the MPC5121 platform file.  A future patch eliminate the need for
the platform file to access these structs, so they'll be moved also.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:10:12 +00:00
Timur Tabi 36b0b1d415 drivers/video: fsl-diu-fb: fix some ioctls
Use the _IOx macros to define the ioctl commands, instead of hard-coded
numbers.  Unfortunately, the original definitions of MFB_SET_PIXFMT and
MFB_GET_PIXFMT used the wrong value for the size, so these macros have
new values now.  To avoid breaking binary compatibility with older
applications, we retain support for the original values, but the driver
displays a warning message if they're used.

Also remove the FBIOGET_GWINFO and FBIOPUT_GWINFO ioctls.  FBIOPUT_GWINFO
was never implemented, and FBIOGET_GWINFO was never used by any
application.

Signed-off-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-05 01:06:55 +00:00
Florian Tobias Schandinat 6488867c05 Merge branch 'viafb-next' of git://github.com/schandinat/linux-2.6 into fbdev-next 2011-10-04 09:55:04 +00:00
Manjunathappa, Prakash 4d7408014e video: da8xx-fb: Increased resolution configuration of revised LCDC IP
Revised LCD controller in upcoming TI SoC which is an updated version of
LCDC IP that was found on TI's DA850 SoC supports 2048*2048 resolution.
Below are the encoding details:
Width:
Pixels Per Line = {pplmsb, ppllsb, 4'b1111} + 1
Where pplmsb:1bit==>Raster Timing0[3], ppllsb:6bits==>Raster Timing0[9:4].
And encoded value can range from 16 to 2048 in multiples of 16.

Height:
Lines Per Panel = {lpp_b10, lpp}
Where lpp:10bits==>Raster Timing1[9:0], lpp_b10:1bit==>Raster Timing2[26].
And encoded value can range from 1 to 2048, programmable range is 0 to
2047.

Patch is verified on emulation platform of upcoming SoC for updated
feature and on DA850 platform to make sure nothing existing breaks.

Signed-off-by: Manjunathappa, Prakash <prakash.pm@ti.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-04 09:48:58 +00:00
Tomi Valkeinen 3e28189038 OMAPDSS: picodlp: add missing #include <linux/module.h>
Compiling panel-picodlp.c failed with:

drivers/video/omap2/displays/panel-picodlp.c:560:12: error:
'THIS_MODULE' undeclared here (not in a function)

Add #include <linux/module.h> to get THIS_MODULE definition.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-10-04 11:45:29 +03:00
Manuel Lauss d121c3f3ce fb: fix au1100fb bitrot.
Removes some bitrot from the au1100fb driver and fix it up so it works again.

Signed-off-by: Manuel Lauss <manuel.lauss@googlemail.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-03 15:52:38 +00:00
Wolfram Stering 8b53b7fb57 mx3fb: fix NULL pointer dereference in screen blanking.
When blanking an already blanked framebuffer, a kernel NULL pointer
dereference occurred, because mx3fb driver handles all kinds of screen
blanking (normal, vsync suspend, powerdown) in the same way.
Certain programs (Xorg X11 server) first do a normal blank, followed by
a powerdown blank, which triggered the bug.

Add an additional safeguard and make sdc_disable_channel() safe against
multiple calls independent of other logic.

Signed-off-by: Michael Thalmeier <michael.thalmeier@hale.at>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-03 15:52:32 +00:00
Yong Zhang f8798ccbef video: irq: Remove IRQF_DISABLED
Since commit [e58aa3d2: genirq: Run irq handlers with interrupts disabled],
We run all interrupt handlers with interrupts disabled
and we even check and yell when an interrupt handler
returns with interrupts enabled (see commit [b738a50a:
genirq: Warn when handler enables interrupts]).

So now this flag is a NOOP and can be removed.

Signed-off-by: Yong Zhang <yong.zhang0@gmail.com>
Acked-by: David Brown <davidb@codeaurora.org>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-03 15:52:22 +00:00
Dan Carpenter 261e767628 smscufx: change edid data to u8 instead of char
Having "edid" as char caused a problem in ufx_read_edid() where we
compared "edid[i] != 0xFF".  Because of the type difference, the
condition was never true and the error checking failed.

Also I added a __user notation to silence a sparse complaint.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
2011-10-03 15:52:05 +00:00
Archit Taneja 54128701ec OMAPDSS: DISPC: zorder support for DSS overlays
Add zorder support on OMAP4, this feature allows deciding the visibility order
of the overlays based on the zorder value provided as an overlay info parameter
or a sysfs attribute of the overlay object.

Use the overlay cap OMAP_DSS_OVL_CAP_ZORDER to determine whether zorder is
supported for the overlay or not. Use dss feature FEAT_ALPHA_FREE_ZORDER
if the caps are not available.

Ensure that all overlays that are enabled and connected to the same manager
have different zorders. Swapping zorders of 2 enabled overlays currently
requires disabling one of the overlays.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-10-03 16:51:55 +03:00
Archit Taneja b8c095b4d6 OMAPDSS: DISPC: VIDEO3 pipeline support
Add support for VIDEO3 pipeline on OMAP4:
- Add VIDEO3 pipeline information in dss_features and omapdss.h
- Add VIDEO3 pipeline register coefficients in dispc.h
- Create a new overlay structure corresponding to VIDEO3.
- Make changes in dispc.c for VIDEO3

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-10-03 16:51:54 +03:00
Archit Taneja 11354dd58d OMAPDSS/OMAP_VOUT: Fix incorrect OMAP3-alpha compatibility setting
On OMAP3, in order to enable alpha blending for LCD and TV managers, we needed
to set LCDALPHABLENDERENABLE/TVALPHABLENDERENABLE bits in DISPC_CONFIG. On
OMAP4, alpha blending is always enabled by default, if the above bits are set,
we switch to an OMAP3 compatibility mode where the zorder values in the pipeline
attribute registers are ignored and a fixed priority is configured.

Rename the manager_info member "alpha_enabled" to "partial_alpha_enabled" for
more clarity. Introduce two dss_features FEAT_ALPHA_FIXED_ZORDER and
FEAT_ALPHA_FREE_ZORDER which represent OMAP3-alpha compatibility mode and OMAP4
alpha mode respectively. Introduce an overlay cap for ZORDER. The DSS2 user is
expected to check for the ZORDER cap, if an overlay doesn't have this cap, the
user is expected to set the parameter partial_alpha_enabled. If the overlay has
ZORDER cap, the DSS2 user can assume that alpha blending is already enabled.

Don't support OMAP3 compatibility mode for now. Trying to read/write to
alpha_blending_enabled sysfs attribute issues a warning for OMAP4 and does not
set the LCDALPHABLENDERENABLE/TVALPHABLENDERENABLE bits.

Change alpha_enabled to partial_alpha_enabled in the omap_vout driver. Use
overlay cap "OMAP_DSS_OVL_CAP_GLOBAL_ALPHA" to check if overlay supports alpha
blending or not. Replace this with checks for VIDEO1 pipeline.

Cc: linux-media@vger.kernel.org
Cc: Lajos Molnar <molnar@ti.com>
Signed-off-by: Archit Taneja <archit@ti.com>
Acked-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-10-03 16:51:54 +03:00
Arnd Bergmann 28748782b7 video/omap: fix build dependencies
Four of the LCD panel drivers depend on the backlight class,
so add the dependency in Kconfig.
Selecting the BACKLIGHT_CLASS_DEVICE symbol does not generally
work since it has other dependencies.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
[tomi.valkeinen@ti.com: changed also N8x0 panel]
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-10-03 13:28:14 +03:00
Tomi Valkeinen 212b0d50e2 OMAPDSS: remove vaddr from overlay info
overlay_info struct, used to configure overlays, currently includes both
physical and virtual addresses for the pixels. The vaddr was added to
support more exotic configurations where CPU would be used to update a
display, but it is not currently used and there has been no interest in
the feature. Using CPU to update a screen is also less interesting now
that OMAP4 has two LCD outputs.

This patch removes the vaddr field, and modifies the users of omapdss
accordingly. This makes the use of omapdss a bit simpler, as the user
doesn't need to think if it needs to give the vaddr.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:32 +03:00
Mythri P K 162874d5f5 OMAPDSS: HDMI: Add support to dump registers through debugfs
Add support to dump the HDMI wrapper, core, PLL and PHY registers
through debugfs.

Signed-off-by: Mythri P K <mythripk@ti.com>
[tomi.valkeinen@ti.com: updated the description]
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:32 +03:00
Mythri P K 81302a7538 OMAPDSS: HDMI: Add missing register definitions
Add some of the missing register definitions, which are h/w indexable.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:31 +03:00
Mythri P K 31ec732e8f OMAPDSS: HDMI: Replace hdmi_reg struct with u16
Remove usage of hdmi_reg struct to use u16 instead in the HDMI IP header
file. hdmi_reg struct is not really needed, and the same change was also
made for dispc earlier.

Signed-off-by: Mythri P K <mythripk@ti.com>
[tomi.valkeinen@ti.com: updated the description]
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:31 +03:00
Mythri P K 050958b97b OMAPDSS: HDMI: Move the comments in avi infoframe
Move the comments in AVI infoframe structure above each parameter
to align with other comments in the header file.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:30 +03:00
Tomi Valkeinen 562a060611 OMAPDSS: Add N800 panel driver
This is a driver for N800's display, ported from the old omapfb. This is
a slightly lighter version of the driver as not all features of the old
driver can be ported without big changes to DSS2, and also because some
of the HW features used in the old driver are unclear (e.g. the power
management part).

That said, the new driver works fine for basic use.

Architecturally the driver is not as neat as it could be. N800's display
HW consists of a display buffer chip and a panel, and ideally they would
be represented by separate, independent drivers. This is not currently
possible, and this driver contains both buffer chip and panel driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:30 +03:00
Tomi Valkeinen 8d49fe74f5 OMAPDSS: Port the Apollon display driver to DSS2
Port the old omapfb panel driver for Apollon to DSS2.

Cc: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:29 +03:00
Tomi Valkeinen 8a41ba9a37 OMAPDSS: Port the H4 display driver to DSS2
Port the old omapfb panel driver for H4 to DSS2.

Cc: Imre Deak <imre.deak@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:29 +03:00
Tomi Valkeinen 3fddbf54b3 OMAPDSS: Port 2430sdp display driver to DSS2
Port the old omapfb panel driver for 2430SDP to DSS2.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:28 +03:00
Tomi Valkeinen 028c5a432a OMAPFB: Remove unused lcd drivers
drivers/video/omap/ contains some lcd drivers which are not used by any
board. They can be removed.

Cc: Arun C <arunedarath@mistralsolutions.com>
Acked-by: Koen Kooi <koen@openembedded.org>
Acked-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:28 +03:00
Tomi Valkeinen bb36dbfd23 OMAPDSS: Taal: remove external backlight support
Taal panel driver supports two kinds of backlight control: 1) using DSI
commands sent to the panel to control the backlight, 2) calling function
pointers going to the board file to control the backlight.

The second option is a bit hacky, and will no longer be needed when the
PWM driver supports the backlight features. After that we can use the
standard PWM backlight driver.

This patch removes the second backlight control mechanism, and adds a
boolean field, use_dsi_backlight, to nokia_dsi_panel_data which the
board file can use to inform whether the panel driver should use DSI
commands to control the backlight.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:27 +03:00
Archit Taneja 0373cac6cc OMAPDSS: FEATURES: Create a range param to get max downscaling
Create a dss_range_param member called FEAT_PARAM_DOWNSCALE to get the maximum
downscaling possible on the current platform. Use this in
dispc_ovl_calc_scaling().

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:27 +03:00
Archit Taneja 79ad75f27b OMAPDSS: DISPC: Clean up scaling related clock and five tap calculations
Move DISPC scaling related code from dispc_ovl_setup() to a new function
dispc_ovl_calc_scaling(). Use overlay caps to check if the overlay can scale or
not. No functional changes are made.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:26 +03:00
Archit Taneja ebdc52499f OMAPDSS: DISPC: Remove hardcoded use of PPL in five tap clock calculation
The function calc_fclk_five_taps() uses a fixed value of pixels per line which
is used in calculations to get the minimum fclk needed for scaling with five
taps to work.

Remove this by providing the width of the panel connected to the manager.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:26 +03:00
Archit Taneja c3dc6a7afb OMAPDSS: DISPC: Get correct pixel clock for TV manager
dispc_mgr_pclk_rate() is used to calculate minimum required functional clock for
scaling in calc_fclk() and calc_fclk_five_taps(). This function returns the
correct pixel clock for LCD and LCD2 managers, but not for TV manager. Extend
this function so that it gets the correct pixel clock for TV manager.

This also prevents the crash we get when we try to scale overlays connected to
TV manager. The current code leads to a BUG() being executed if we call
dispc_mgr_pclk_rate() for the TV manager.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:25 +03:00
Archit Taneja dac57a05fc OMAPDSS: DISPC: Create helper function dispc_mgr_is_lcd()
Create a helper function called dispc_mgr_is_lcd() which returns true if the
manager is LCD or LCD2.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:25 +03:00
Archit Taneja c3d92529c3 OMAPDSS: DISPC: Pass overlay params as arguments to dispc_ovl_setup()
dispc_ovl_enable_replication() and dispc_ovl_set_fifo_threshold() are currently
called in configure_overlay(). These are the only functions which cause DISPC
register writes of overlay parameters outside of dispc_ovl_setup().

Move these to dispc_ovl_setup() and pass replication, fifo_low and fifo_high
thresholds as arguments to dispc_ovl_setup() in order to be aligned with other
overlay parameters. No functional changes are made.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:25 +03:00
Archit Taneja a4273b7cca OMAPDSS: DISPC: Reduce the number of arguments in dispc_ovl_setup()
dispc_ovl_setup() currently takes a large number of overlay arguments, most of
these are members of the overlay_info struct. Replace these arguments by
passing a overlay_info pointer instead.

In configure_overlay(), we create an overlay_info struct called new_oi, this is
a copy of the overlay cache's overlay_info member. Update the new_oi parameters
which could have been possibly changed in configure_overlay(). Pass its pointer
pointer to dispc_ovl_setup().

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:24 +03:00
Tomi Valkeinen dc891fab11 OMAPFB: find best mode from edid
Use the new read_edid() function to get EDID information from the
display (when available), and use the information to use a suitable mode
at initialization time.

Hot-plug is not yet supported, so the timings selected at init time will
stay even if the monitor would be changed.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:17:23 +03:00
Tomi Valkeinen aadb85e5ca OMAP: DSS2: panel-generic-dpi: remove "generic" panel
Remove the "generic" panel config entry, which is not used.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:58 +03:00
Tomi Valkeinen ba2eac9ed3 OMAP: DSS2: add panel-dvi driver
We have currently panel-generic-dpi driver, which is a combined driver
for dummy panels and also for DVI output.

The aim is to split the panel-generic-dpi into two, one for fixed size
dummy panels connected via DPI, and the other (this) for variable
resolution output which supports DDC channel (in practice a DVI framer
chip connected to DPI output).

Original i2c code by: Ricardo Salveti de Araujo
<ricardo.salveti@canonical.com>

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:48 +03:00
Tomi Valkeinen 759593ffa7 OMAP: DSS2: HDMI: implement detect()
Implement detect() by checking the hot plug detect status.

The implementation is not very good, as it always turns on the HDMI
output to get the detection working. HDMI driver needs improvements so
that we could enable only core parts of it.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:47 +03:00
Tomi Valkeinen 468c1b934c OMAP: DSS2: HDMI: remove error prints in check_timings
check_timings() is supposed to be used to verify if timings are ok or
not. Currently the HDMI driver prints error messages if the timings are
not ok. This is not right, as it is no error to give invalid timings to
check_timings().

Remove the error prints.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:47 +03:00
Tomi Valkeinen 937fce138f OMAP: DSS2: HDMI: clean up edid reading & fix checksum
Clean up reading of EDID by passing direct address to the block being
read, instead of start address of the whole EDID memory area. Rewrite
the loop which reads the EDID.

This also fixes the checksum calculation, which used to calculate the
checksum only for the first block.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:46 +03:00
Tomi Valkeinen 032b8ea508 OMAP: DSS2: HDMI: split hdmi_core_ddc_edid
Split the DDC initialization off from hdmi_core_ddc_edid() into a
separate function hdmi_core_ddc_init(). This cleans up the
implementation.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:46 +03:00
Tomi Valkeinen 2ea51fef86 OMAP: DSS2: HDMI: remove edid parsing
OMAPFB handles EDID parsing now, using the common helper functions in
fbdev. We can remove the EDID parsing from HDMI driver.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:45 +03:00
Tomi Valkeinen 470245652d OMAP: DSS2: HDMI: implement read_edid()
Implement read_edid() for HDMI by implementing necessary functions to
hdmi.c and to hdmi_omap4_panel.c.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:45 +03:00
Tomi Valkeinen fa70dc5f47 OMAP: DSS2: HDMI: make set_timing saner
Currently the set_timings code for hdmi is quite strange. The display is
disabled in hdmi_omap4_panel.c before setting timings, and enabled in
hdmi.c after setting the timings. Furthermore, the timings were not
permanent, and disabling and enabling the display would lose them.

This patch makes the set_timings handling a bit better.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:44 +03:00
Tomi Valkeinen 3870c909f2 OMAP: DSS2: HDMI: improve hdmi output enable
Enabling HDMI output often causes sync lost errors, and almost always
causes timeout errors being printed from dispc_mgr_enable_digit_out().

The sync lost problem seems to go lessen greatly if we first enable the
HDMI output, and only then enable the DISPC output. However, as this is
only based on observations, the fix may not be perfect as the problem
may lie somewhere else. Nevertheless, HDMI works better with this patch.

This will also fix the dispc's dispc_mgr_enable_digit_out(), as the code
waits for two VSYNCs after enabling the output. If the HDMI output is
disabled (as it was previously), there are no VSYNCs and
dispc_mgr_enable_digit_out() will print timeout errors.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:43 +03:00
Tomi Valkeinen e82b090b80 OMAP: DSS2: DISPC: improve dispc_mgr_enable_digit_out()
dispc_mgr_enable_digit_out() didn't handle HDMI case very well.

Improve the function to use FRAMEDONETV interrupt to see when HDMI has
been disabled.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:43 +03:00
Tomi Valkeinen 4a61e267c8 OMAP: DSS2: add dss_get_hdmi_venc_clk_source()
Add dss_get_hdmi_venc_clk_source(), which can be used to get the value
programmed with dss_select_hdmi_venc_clk_source(). This can be used to
find out if the digit output is going to VENC or HDMI.

For OMAP2/3 dss_get_hdmi_venc_clk_source() always returns
DSS_VENC_TV_CLK.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:42 +03:00
Tomi Valkeinen b44e45825d OMAP: DSS2: HDMI: change regn definition
regn divider is currently programmed to the registers without change,
but when calculating clock frequencies it is used as regn+1.

To make this similar to how DSI handles the dividers this patch changes
the regn value to be used as such for calculations, but the value
programmed to registers is regn-1.

This simplifies the clock frequency calculations, makes it similar to
DSI, and also allows us to use regn value 0 as undefined.

Cc: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:41 +03:00
Tomi Valkeinen 8d88767a43 OMAP: DSS2: HDMI: use default dividers
Use default regn and regm2 dividers in the hdmi driver if the board file
does not define them.

Cc: Mythri P K <mythripk@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:36 +03:00
Tomi Valkeinen 9eaaf2076d OMAP: DSS2: DISPC: Fix minimum PCD value
The current driver had a hardcoded minimum value of 2 for pixel clock
divisor (PCD). This doesn't seem to be right.

OMAP4 TRM says that PCD can be 1 when not downscaling, and inverted
pixel clock (IPC) is off.

OMAP3 TRM says the same, but also in the register descriptions that PCD
value 1 is invalid.

OMAP2 TRM says PCD 2 is the minimum.

OMAP2 is still untested, but for both OMAP3 and OMAP4 PCD of 1 seems to
work fine.

This patch adds a new DSS feature, FEAT_PARAM_DSS_PCD, which is used to
find the minimum and maximum PCD. The minimum is set to 2 for OMAP2, and
1 for OMAP3/4.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:35 +03:00
Mythri P K d875f992e9 OMAP4: DSS2: Rename hdmi_omap4_panel.c to hdmi_panel.c
As the panel driver will remain generic across OMAP's renaming it to
hdmi_panel.c

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:35 +03:00
Mythri P K 60634a28bc OMAP4: DSS2: HDMI: Function pointer approach to call
HDMI IP fundamentally has replaceable core PHY and PLL blocks.
These blocks might vary across OMAP's but the end functionality such as to
enable or disable PLL, PHY, function to read EDID would remain the same.

Thus to make the current hdmi DSS driver compatible with different OMAP's having
different IP blocks( A combination of different core, PHY, PLL blocks), function
pointer approach is introduced.

With function pointer, relevant IP dependent functions are mapped to the generic
functions used by DSS during the initialization based on the OMAP compiled.
Thus making hdmi DSS driver IP agnostic.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:34 +03:00
Mythri P K 176b578b1a OMAP4: DSS2: HDMI: Rename the functions in HDMI IP library
Functions that are included in HDMI IP driver is renamed to have
IP specific names so that it will not conflict with similar functions
from other IP.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:34 +03:00
Mythri P K 7334167bf1 OMAP4: DSS2: HDMI: Move the HDMI IP dependent audio
Move HDMI IP dependent audio functions from HDMI DSS file  to IP library.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:33 +03:00
Mythri P K 7d983f39ec OMAP4: DSS2: HDMI: Split the current HDMI driver to move
Split the current HDMI driver to move the HDMI IP dependent ( PLL/PHY/Core
configuration code) to a new IP file (ti_hdmi_4xxx_ip.c.
This is to separate IP dependent OMAP agnostic code from OMAP specific DSS
dependent code.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:32 +03:00
Mythri P K 7c1f1ecac9 OMAP4: DSS2: HDMI: Move the EDID definition from HDMI
Clean up to move the EDID definition from the IP dependent header file to hdmi.c

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:32 +03:00
Mythri P K 94c52987d2 OMAP4: DSS2: HDMI: Move HDMI IP independent generic header
Some of the header file definitions that are there in the hdmi.h are generic
and can be used across OMAP's, Thus moving generic definition to new file.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:32 +03:00
Mythri P K 38863b7e1d OMAP4: DSS2: HDMI: Use specific HDMI timings structure
As hdmi has few additional parameters such as vsync and hsync
polarity which is missing in DSS timing structure, define HDMI timings
structure for hdmi to use instead of OMAP DSS timing structure.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:31 +03:00
Mythri P K 7b27da5483 OMAP4: DSS2: HDMI: Move pll and video configuration
As the pll and the video configuration info are part of the ip_data, pll
and video structures are moved to the ip_data structure. Also the pll and
video configuration functions are modified accordingly to take care of the
structure movement.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:31 +03:00
Mythri P K 95a8aeb6c5 OMAP4: DSS2: HDMI: HDMI clean up to pass base_address
As the base_address of the HDMI might differ across SoC's, offset of the HDMI
logical blocks(PHY, PLL and Core) and base address procured from the platform
data are passed dynamically to the functions that modify HDMI IP registers.

Signed-off-by: Mythri P K <mythripk@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:30 +03:00
Archit Taneja 8af6ff0107 OMAP: DSS2: DSI Video mode support
Add initial support for DSI video mode panels:
- Add a new structure omap_dss_dsi_videomode_data in the member "panel" in
  omap_dss_device struct. This allows panel driver to configure dsi video_mode
  specific parameters.
- Configure basic DSI video mode timing parameters: HBP, HFP, HSA, VBP, VFP, VSA,
  TL and VACT.
- Configure DSI protocol engine registers for video_mode support.
- Introduce functions dsi_video_mode_enable() and dsi_video_mode_disable() which
  enable/disable video mode for a given virtual channel and a given pixel format
  type.

Things left for later
- Add functions to check for errors in video mode timings provided by panel.
- Configure timing registers required  for command mode interleaving.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:30 +03:00
Archit Taneja 18b7d09908 OMAP: DSS2: DSI: Send zero length packet in dsi_vc_send_null()
dsi_vc_send_null() currently sends a long packet with data type
MIPI_DSI_NULL_PACKET and packet length 4. Modify it to send a zero
length long packet. This leads to sending only the long packet header
and no payload packets and hence the transfer completes faster.

The function can be modified later if there is a need to send null
packets of a non-zero length.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:29 +03:00
Archit Taneja a3b3cc2b88 OMAP: DSS2: Create an enum for DSI pixel formats
Currently, DSI pixel info is only represented by the pixel size in bits using
the pixel_size parameter in omap_dss_device struct's ctrl member.

This is not sufficient information for DSI video mode usage, as two of the
supported formats(RGB666 loosely packed, and RGB888) have the same pixel
container size, but different data_type values for the video mode packet header.

Create enum "omap_dss_dsi_pixel_format" which describes the pixel data format
the panel is configured for. Create helper function dsi_get_pixel_size() which
returns the pixel size of the given pixel format.

Modify functions omapdss_default_get_recommended_bpp() and dss_use_replication()
to use dsi_get_pixel_size().

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:29 +03:00
Archit Taneja 569969d601 OMAP: DSS2: Clean up stallmode and io pad mode selection
Split the function dispc_set_parallel_interface_mode() into 2 separate
functions called dispc_mgr_set_io_pad_mode() and dispc_mgr_enable_stallmode().
The current function tries to set 2 different modes(io pad mode and stall mode)
based on a parameter omap_parallel_interface_mode which loosely corresponds to
the panel interface type.

This isn't correct because a) these 2 modes are independent to some extent,
b) we are currently configuring gpout0/gpout1 for DSI panels which is
unnecessary, c) a DSI Video mode panel won't get configured correctly.

Splitting the functions allows the interface driver to set these modes
independently and hence allow more flexibility.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:28 +03:00
Archit Taneja b3b89c05cb OMAP: DSS2: DSI: Introduce generic read functions
Introduce read functions which use generic Processor-to-Peripheral
transaction types. These are needed by some devices which may not support
corresponding DCS commands.

Add function dsi_vc_generic_send_read_request() which can send
a short packet with 0, 1 or 2 bytes of request data and the corresponding
generic data type.

Rename function dsi_vc_dcs_read_rx_fifo() to dsi_vc_read_rx_fifo() and modify
it to take the enum "dss_dsi_content_type" as an argument to use either DCS
or GENERIC Peripheral-to-Processor transaction types while parsing data read
from the device.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:28 +03:00
Archit Taneja b850975cd8 OMAP: DSS2: DSI: Split dsi_vc_dcs_read() into 2 functions
Split dsi_vc_dcs_read() into the functions:
- dsi_vc_dcs_send_read_request(): This is responsible for sending the short
packet command with the read request.
- dsi_vc_dcs_read_rx_fifo(): This parses the DSI RX fifo of the given virtual
channel, identifies the type of data received, and fills a buffer with the data
provided by the panel.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:27 +03:00
Archit Taneja 5c716a04ed OMAP: DSS2: DSI: Remove functions dsi_vc_dcs_read_1() and dsi_vc_dcs_read_2()
Remove functions dsi_vc_dcs_read_1() and dsi_vc_dcs_read_2(), these are used
when the panel is expected to return 1 and 2 bytes respecitvely. This was manily
used for debugging purposes. These functions should be implemented in the panel
driver if needed.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:27 +03:00
Archit Taneja 6ff8aa3182 OMAP: DSS2: DSI: Introduce generic write functions
Intoduce enum "dss_dsi_content_type" to differentiate between DCS and generic
content types.

Introduce short and long packet write functions which use generic
Processor-to-Peripheral transaction types. These are needed by some devices
which may not support corresponding DCS commands. Create common write functions
which allow code reuse between DCS and generic write functions.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:26 +03:00
Archit Taneja 7e951ee995 OMAP: DSS2: Create enum for DSI operation modes
Create an enum for DSI operation modes, use this to set the capabilities of the
device in dsi_init_display().

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:26 +03:00
Archit Taneja d604914484 OMAP: DSS2: DSI: Represent L4 and VP as sources of VC instead of modes
The enum type dsi_vc_mode is a bit misleading as L4 slave port and video port
are sources to VC rather than the mode of operation. Rename then enum type and
its members. Merge dsi_vc_config_vp() and dsi_vc_config_l4() into a single
function called dsi_vc_config_source() which takes dsi_vc_source enum as an
extra argument.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:26 +03:00
Archit Taneja 7a7c48f9ab OMAP: DSS2: Use MIPI DSI enums from include/video/mipi_display.h
MIPI DSI Transaction types and DCS commands are currently defined as
macros in dsi.c and panel-taal.c, remove these and replace them with
enum members defined in include/video/mipi_display.h.

Signed-off-by: Archit Taneja <archit@ti.com>
[tomi.valkeinen@ti.com: reformatted the commit message]
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:25 +03:00
Thomas Weber 1e497c4f0a OMAP: DSS2: Support for Innolux AT070TN83
Add support for Innolux AT070TN83, a 7 inch LCD
with RGB-Interface and touch panel to panel-generic-dpi.

Tested with Devkit8000.

Signed-off-by: Thomas Weber <weber@corscience.de>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:24 +03:00
Tomi Valkeinen cd295aebf1 OMAP: DSS2: reorganize functions in dss.h
Group dispc's overlay and manager related functions.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:24 +03:00
Tomi Valkeinen 26d9dd0dbe OMAP: DSS2: DISPC: rename manager related funcs
Rename dispc's manager related functions as follows:

- Remove prepending underscores, which were originally used to inform
  that the clocks needs to be enabled. This meaning is no longer valid.
- Prepend the functions with dispc_mgr_*
- Remove "channel" from the name, e.g. dispc_enable_channel ->
  dispc_mgr_enable

The idea is to group manager related functions so that it can be deduced
from the function name that it writes to manager spesific registers.

All dispc_mgr_* functions have enum omap_channel as the first parameter.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:23 +03:00
Tomi Valkeinen f0e5caab97 OMAP: DSS2: DISPC: rename overlay related funcs
Rename dispc's overlay related functions as follows:

- Remove prepending underscores, which were originally used to inform
  that the clocks needs to be enabled. This meaning is no longer valid.
- Prepend the functions with dispc_ovl_*
- Remove "plane" from the name, e.g. dispc_set_plane_ba0 ->
  dispc_ovl_set_ba0

The idea is to group overlay related functions so that it can be deduced
from the function name that it writes to overlay spesific registers.

All dispc_ovl_* functions have enum omap_plane as the first parameter.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:23 +03:00
Tomi Valkeinen 3375483e91 OMAP: DSS2: DISPC: remove non-existing func prototypes
The functions do not exist, so remove the prototypes.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:22 +03:00
Tomi Valkeinen 7fbf1bb02d OMAP: OMAPFB: string parsing cleanups
Use strtobool instead of kstrtoint when parsing bool from sysfs.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:22 +03:00
Tomi Valkeinen e3a26aecc0 OMAP: DSS2: string parsing cleanups
Use strtobool and kstrto* functions when parsing sysfs inputs.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:21 +03:00
Tomi Valkeinen f6dc815098 OMAP: DSS2: Add GLOBAL_ALPHA & PRE_MULT_ALPHA to ovl caps
Add OMAP_DSS_OVL_CAP_GLOBAL_ALPHA and OMAP_DSS_OVL_CAP_PRE_MULT_ALPHA to
overlay capabilities. Use these instead of FEAT_GLOBAL_ALPHA,
FEAT_GLOBAL_ALPHA_VID1 and FEAT_PRE_MULT_ALPHA in code.

Remove FEAT_GLOBAL_ALPHA_VID1 and FEAT_PRE_MULT_ALPHA which are no
longer used. FEAT_GLOBAL_ALPHA is still used to decide if the HW has
global alpha register.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Archit Taneja <archit@ti.com>
2011-09-30 16:16:21 +03:00
Tomi Valkeinen 67019db864 OMAP: DSS2: Add overlay caps to DSS features
Add support to define overlay capabilities into dss_features. The
features are set to overlay->caps at initialization time.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Archit Taneja <archit@ti.com>
2011-09-30 16:16:21 +03:00
Tomi Valkeinen fe3cc9d6cd OMAP: DSS2: DISPC: use lookup tables for bit shifts
Use lookup tables instead of switch/if in some DISPC functions to make
the code cleaner.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Archit Taneja <archit@ti.com>
2011-09-30 16:16:20 +03:00
Tomi Valkeinen 4a9e78abb7 OMAP: DSS2: Remove support for non-DISPC overlays
Remove support for non-DISPC overlays and overlay managers.

The support to possibly have non-DISPC overlays and managers was made to
make it possible to use CPU and/or sDMA to update RFBI or DSI command
mode displays. It is ok to remove the support, because:

- No one has used the feature.
- Display update without DISPC is very slow, so it is debatable if the
  update would even be usable.
- Removal cleans up code.
- If such a feature is needed later, it is better implemented outside
  omapdss driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Archit Taneja <archit@ti.com>
2011-09-30 16:16:20 +03:00
Tomi Valkeinen 46fc133f95 OMAP: DSS2: Remove "EXPERIMENTAL" from Kconfig
DSS driver has not been "experimental" for many years now, so perhaps
it's time to remove the text from Kconfig titles.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:19 +03:00
Tomi Valkeinen 8fa8031c54 OMAP: DSS2: Handle manager change in apply
Currently when changing the manager of an overlay, set_manager() directly
calls dispc to set the overlay's destination.

Change this to be more in line with other overlay configurations, and
this will also remove the need to have dispc clocks enabled when calling
set_manager().

A new field is added to overlay struct, "manager_changed". This is
similar to "display_changed" field in manager struct, and is used to
inform apply that the manager has changed and thus write to the
registers is needed.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:19 +03:00
Tomi Valkeinen 5e7850917f OMAP: DSS2: fix clock sources on error and uninit
DPI and DSI were not cleaning up the clock source in error or uninit
cases. Set the clock source back to PRCM.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:18 +03:00
Tomi Valkeinen bab59b4417 OMAP: OMAPFB: make omapfb start even when a display is missing a driver
Currently omapfb wants that all the display devices have a driver,
otherwise omapfb refuses to start. There's no real requirement to act
like that, and this patch will make omapfb give a warning and skip that
device.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:18 +03:00
Tomi Valkeinen 5bc416cba1 OMAP: DSS2: DSI: Improve dsi_mux_pads parameters
dsi_mux_pads() needs to know about the DSI HW module and the DSI lanes
used. Split the function into two, enable and disable, which take
necessary arguments, and add empty implementations for both.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:17 +03:00
Tomi Valkeinen 7c68dd96d5 OMAP: DSS2: Change DSI device naming
Currently, there are 2 differently named platform devices generated for
the 2 DSS DSI modules. In order to use the same driver, the dsi devices
should be 2 instances of the same platform device.

Change the platform device names from "omapdss_dsi1" and "omapdss_dsi2"
to omapdss_dsi", and set the device indices to 0 and 1.

Signed-off-by: Archit Taneja <archit@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-30 16:16:05 +03:00
Paul Bolle 395cf9691d doc: fix broken references
There are numerous broken references to Documentation files (in other
Documentation files, in comments, etc.). These broken references are
caused by typo's in the references, and by renames or removals of the
Documentation files. Some broken references are simply odd.

Fix these broken references, sometimes by dropping the irrelevant text
they were part of.

Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2011-09-27 18:08:04 +02:00
Russell King 99df4ee107 clk: amba-clcd: convert to clk_prepare()/clk_unprepare()
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2011-09-27 09:25:51 +01:00
Tomi Valkeinen f36465822d OMAP: DSS2: remove unneeded fck enable/disables
Now that the HWMOD fmwk handles the fcks of DSS modules properly, the
DSS driver no longer needs to explicitely enable/disable the fck.

This patch removes the enables/disables of fck from dispc, dsi and dss.
The clk_get(fck) is still needed there, as the modules need to know the
frequency of the clock.

For hdmi and venc this patch also removes the clk_get(fck), as they
don't need the clock at all.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-09-20 11:21:31 +03:00