1
0
Fork 0
Commit Graph

42 Commits (da49252fb0392d8196833ef3da92e48fb371f8d7)

Author SHA1 Message Date
Archit Taneja bc6d4b1d3d OMAP: DSS2: Use request / release calls in Taal for DSI Virtual Channels.
Taal driver used to take a hard coded Macro for Virtual Channel and the VC_ID.
The Taal panel driver now requests for a Virtual channel through the
omap_dsi_request_vc() call in taal_probe().

The channel number returned by the request_vc() call is used for sending command
and data to the Panel. The DSI driver automatically configures the Virtual
Channel's source to either Video Port or L4 Slave port based on what the panel
driver is using it for.

The driver uses omap_dsi_release_vc() to free the VC specified by the panel.
taal_remove() or when a request_vc() call fails.

Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2011-03-11 15:46:28 +02:00
Lionel Debroux acc2472ed3 backlight: constify backlight_ops
backlight_device_register has been expecting a const "ops" argument, and using
it as such, since 9905a43b2d. Let's make the
remaining backlight_ops instances const.

Inspired by hunks of the grsecurity patch, updated for newer kernels.

Signed-off-by: Lionel Debroux <lionel_debroux@yahoo.fr>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2010-11-16 14:14:02 +01:00
Tomi Valkeinen ffb63c95b2 OMAP: DSS2: Taal: Optimize enable_te, rotate, mirror when value unchanged
Skip any further processing of taal_enable_te(), taal_rotate(), and
taal_mirror() if value remains unchanged.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-05 16:52:07 +03:00
Tomi Valkeinen 26a8c2507a OMAP: DSS2: change manual update scaling setup
Currently the update area on manual update displays is automatically
enlargened to fully cover scaled overlays. This patch makes that
optional, allowing the panel driver to choose if it's used or not.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-05 16:52:03 +03:00
Jani Nikula 1e8943dbae OMAP: DSS2: Taal: CABC workaround is Taal specific
Prepare for supporting panels other than Taal in this driver.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:49 +03:00
Tomi Valkeinen c8cd4547dc OMAP: DSS2: Taal: Add regulator configuration support
Add support for configuring regulators in the panel specific
configuration data.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:49 +03:00
Jani Nikula 0f45bddf04 OMAP: DSS2: Taal: Print panel name in addition to revision
The driver will support other panels in addition to Taal, print also the
name.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:49 +03:00
Jani Nikula e7f6c3f2fb OMAP: DSS2: Taal: Add panel specific configuration structure
Add a structure for panel specific configration to be able to support
more than one panel in the future.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:49 +03:00
Jani Nikula 448dfe9680 OMAP: DSS2: Taal: Configure ESD check in DSI panel data
Make ESD check usage configurable in DSI panel data, as opposed to a
define.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:49 +03:00
Tomi Valkeinen 8d3573c88a OMAP: DSS2: Taal: Use Nokia DSI panel data
Get board specific information from the Nokia DSI panel data structure
instead of the DSS.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:48 +03:00
Jani Nikula 7ae2fb1192 OMAP: DSS2: Taal: Add proper external TE support
Add gpio irq based external TE support with timeout.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:48 +03:00
Jani Nikula d2b6578738 OMAP: DSS2: Taal: Change probe error handling labels
Switch from numbered to named labels to make it easier to add new
labels for error handling.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:48 +03:00
Jani Nikula 4571a023f5 OMAP: DSS2: Taal: Change ESD work management
Move ESD work queuing and cancelling out of taal_power_on/off() to avoid
problems related to taal_esd_work() calling the power on/off functions.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:48 +03:00
Jani Nikula fed44b7af8 OMAP: DSS2: Taal: Check taal_power_on() return value in taal_resume()
Change state only if power on was succesful.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:48 +03:00
Jani Nikula 2c2fc15124 OMAP: DSS2: Taal: Change DSI bus locking to avoid deadlock in ESD work
Move dsi_bus_lock/unlock() out of taal_power_on/off() to avoid deadlock
in taal_esd_work().

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:48 +03:00
Jani Nikula ee52c0ae68 OMAP: DSS2: Taal: Ensure panel is enabled in enable_te() and run_test()
Bail out from taal_enable_te() and taal_run_test() if panel is not
enabled.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:48 +03:00
Jani Nikula f2a8b75c13 OMAP: DSS2: Taal: Improve taal_power_on() error handling
Check return values and bail out on errors.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:48 +03:00
Jani Nikula d803bb6e68 OMAP: DSS2: Taal: Remove ESD work cancel from driver probe error handling
ESD work is never queued in probe, no need to cancel it on probe error.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:47 +03:00
Jani Nikula 2f1e5f606a OMAP: DSS2: Taal: Fix request_irq() error handling
Separate gpio_request() and request_irq() error handling.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:47 +03:00
Jani Nikula 75392bfe3e OMAP: DSS2: Taal: Remove platform enable/disable
After the addition of proper hardware reset, taal_hw_reset(), there's no
need for an additional platform enable/disable. Remove them.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:47 +03:00
Jani Nikula 6b316715b4 OMAP: DSS2: Taal: Add locks to protect taal data access
Avoid potential race conditions in sysfs access to taal data.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:47 +03:00
Jani Nikula 006db7b430 OMAP: DSS2: Taal: Add panel hardware reset
Issue a proper reset pulse on the reset line instead of just doing power
on/off.

Signed-off-by: Jani Nikula <ext-jani.1.nikula@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:47 +03:00
Tomi Valkeinen 1cbc8703e1 OMAP: DSS2: Taal: add locks to taal_bl_update_status
taal_bl_update_status was missing locks to protect taal_data. This caused
a kernel crash randomly, as the code attempted to set the brightness while
the OMAP's DSI block was actually disabled.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-08-03 15:18:47 +03:00
Ville Syrjälä 6df37271f8 OMAP: DSS2: Taal: Fix DSI bus locking problem
If omapdss_dsi_display_enable() failed the DSI bus was left locked. Also
if the operation failed later omapdss_dsi_display_disable() would get
called without holding the bus lock.

Signed-off-by: Ville Syrjälä <ville.syrjala@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-05-18 14:14:30 +03:00
Tomi Valkeinen a3201a0eae OMAP: DSS2: Taal: add mutex to protect panel data
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-05-18 14:14:30 +03:00
Tejun Heo 5a0e3ad6af include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
percpu.h is included by sched.h and module.h and thus ends up being
included when building most .c files.  percpu.h includes slab.h which
in turn includes gfp.h making everything defined by the two files
universally available and complicating inclusion dependencies.

percpu.h -> slab.h dependency is about to be removed.  Prepare for
this change by updating users of gfp and slab facilities include those
headers directly instead of assuming availability.  As this conversion
needs to touch large number of source files, the following script is
used as the basis of conversion.

  http://userweb.kernel.org/~tj/misc/slabh-sweep.py

The script does the followings.

* Scan files for gfp and slab usages and update includes such that
  only the necessary includes are there.  ie. if only gfp is used,
  gfp.h, if slab is used, slab.h.

* When the script inserts a new include, it looks at the include
  blocks and try to put the new include such that its order conforms
  to its surrounding.  It's put in the include block which contains
  core kernel includes, in the same order that the rest are ordered -
  alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
  doesn't seem to be any matching order.

* If the script can't find a place to put a new include (mostly
  because the file doesn't have fitting include block), it prints out
  an error message indicating which .h file needs to be added to the
  file.

The conversion was done in the following steps.

1. The initial automatic conversion of all .c files updated slightly
   over 4000 files, deleting around 700 includes and adding ~480 gfp.h
   and ~3000 slab.h inclusions.  The script emitted errors for ~400
   files.

2. Each error was manually checked.  Some didn't need the inclusion,
   some needed manual addition while adding it to implementation .h or
   embedding .c file was more appropriate for others.  This step added
   inclusions to around 150 files.

3. The script was run again and the output was compared to the edits
   from #2 to make sure no file was left behind.

4. Several build tests were done and a couple of problems were fixed.
   e.g. lib/decompress_*.c used malloc/free() wrappers around slab
   APIs requiring slab.h to be added manually.

5. The script was run on all .h files but without automatically
   editing them as sprinkling gfp.h and slab.h inclusions around .h
   files could easily lead to inclusion dependency hell.  Most gfp.h
   inclusion directives were ignored as stuff from gfp.h was usually
   wildly available and often used in preprocessor macros.  Each
   slab.h inclusion directive was examined and added manually as
   necessary.

6. percpu.h was updated not to include slab.h.

7. Build test were done on the following configurations and failures
   were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
   distributed build env didn't work with gcov compiles) and a few
   more options had to be turned off depending on archs to make things
   build (like ipr on powerpc/64 which failed due to missing writeq).

   * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
   * powerpc and powerpc64 SMP allmodconfig
   * sparc and sparc64 SMP allmodconfig
   * ia64 SMP allmodconfig
   * s390 SMP allmodconfig
   * alpha SMP allmodconfig
   * um on x86_64 SMP allmodconfig

8. percpu.h modifications were reverted so that it could be applied as
   a separate patch and serve as bisection point.

Given the fact that I had only a couple of failures from tests on step
6, I'm fairly confident about the coverage of this conversion patch.
If there is a breakage, it's likely to be something in one of the arch
headers which should be easily discoverable easily on most builds of
the specific arch.

Signed-off-by: Tejun Heo <tj@kernel.org>
Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
2010-03-30 22:02:32 +09:00
Matthew Garrett a19a6ee6ca backlight: Allow properties to be passed at registration
Values such as max_brightness should be set before backlights are
registered, but the current API doesn't allow that. Add a parameter to
backlight_device_register and update drivers to ensure that they
set this correctly.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-03-16 19:47:54 +00:00
Tomi Valkeinen 21df20fcfb OMAP: DSS2: Taal: Fix TE when resuming
TE was not initialized properly on power on, which broke TE when resuming
from suspend.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-03-02 17:24:18 +02:00
Tomi Valkeinen 1189b7ff64 OMAP: DSS2: Taal: Fix ESD check
Using taal_enable_te() when DSI bus was locked caused a deadlock.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-03-01 14:22:57 +02:00
Tomi Valkeinen 69b2048f44 OMAP: DSS2: move timing functions
Move check/set/get_timings() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 37ac60e414 OMAP: DSS2: move enable/disable/suspend/resume
Move enable/disable/suspend/resume from omap_dss_device to
omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 18946f62c6 OMAP: DSS2: move update() and sync()
Move update() and sync() from omap_dss_device to omap_dss_driver.

Also, update was hardcoded to use virtual channel 0. This patch adds a
parameter that specifies the VC.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 446f7bff70 OMAP: DSS2: move set/get_update_mode()
Move set/get_update_mode() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 225b650d41 OMAP: DSS2: move enable/get_te()
Move enable/get_te() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen a269950405 OMAP: DSS2: move get_recommended_bpp()
Move get_recommended_bpp() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 96adceceed OMAP: DSS2: move get_resolution()
Move get_resolution() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 87424e1bff OMAP: DSS2: move get/set_rotate()
Move get/set_rotate() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 8d8aa61dcf OMAP: DSS2: move set/get_mirror()
Move set/get_mirror() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen c75d9464c1 OMAP: DSS2: move memory_read()
Move memory_read() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 1a75ef422d OMAP: DSS2: move run_test()
Move run_test() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:26 +02:00
Aaro Koskinen 92fe0ff16a OMAP: DSS: Taal: fix error returns in taal_probe()
The workqueue creation error branch attempted to destroy a NULL wq,
and, in turn, a failed registration does not destroy the newly created
workqueue.

The problem was reported by a static analysis tool.

Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-12 12:46:09 +02:00
Tomi Valkeinen f133a9d7f2 OMAP: DSS2: Taal DSI command mode panel driver
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2009-12-09 18:21:41 +02:00