1. 24 9月, 2012 1 次提交
    • T
      OMAPDSS: DSI: improve DSI clock calcs for DISPC · d66b1581
      Tomi Valkeinen 提交于
      Commit ee144e64 added
      dsi_pll_calc_ddrfreq() which calculates PLL dividers based on given DSI
      bus clock speed. The function works ok, but it can be improved for the
      DISPC clock calc.
      
      The current version calculates the clock going from the PLL to the DISPC
      simply by setting the clock as close to DISPC maximum as possible, and
      the pixel clock is calculated based on that.
      
      This patch changes the function to calculate DISPC clock more
      dynamically, iterating through different DISPC clocks and pixel clock
      values, and thus we'll get more suitable pixel clocks.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      d66b1581
  2. 11 9月, 2012 1 次提交
  3. 08 9月, 2012 22 次提交
    • T
      OMAPDSS: fix dss_ovl_unset_manager · b2f5976c
      Tomi Valkeinen 提交于
      When we removed fifomerge support, we also changed dss_ovl_disable so
      that it doesn't wait for the hardware to be finished with the overlay.
      This may cause a problem when changing the overlay's manager, as
      changing the manager is an immediate change. Thus if the overlay is
      still being used by the HW when the manager is changed, there may be
      glitches on the screen.
      
      This patch adds a wait into dss_ovl_unset_manager, which ensures the
      overlays are disabled in the HW.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      b2f5976c
    • T
      OMAPDSS: fix set_timings · b82fe7f0
      Tomi Valkeinen 提交于
      set_timings function of DSS's output drivers are not consistent. Some of
      them disable the output, set the timings, and re-enable the output. Some
      set the timings on the fly, while the output is enabled. And some just
      store the given timings, so that they will be taken into use next time
      the output is enabled.
      
      We require the DISPC output to be disabled when changing the timings,
      and so we can change all the output drivers' set_timings to just store
      the given timings.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      b82fe7f0
    • T
      OMAPDSS: Use WB fifo for GFX overlay · 66a0f9e4
      Tomi Valkeinen 提交于
      OMAP4's GFX overlay has smaller fifo than the rest of the overlays
      (including writeback "overlay"). This seems to be the reason for
      underflows in some more demanding scenarios.
      
      We can avoid the problems by using the WB fifo for GFX overlay, and vice
      versa. WB usage is not supported yet, but when it will, it should
      perform just fine with smaller fifo as there are no hard realtime
      constraints with WB.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      66a0f9e4
    • T
      OMAPDSS: Improve fifo management code · 42a6961c
      Tomi Valkeinen 提交于
      OMAP4+ allows assigning the overlay FIFOs freely, but that is not
      supported by omapdss yet. This patch takes a step forward by improving
      the fifo management to be more flexible.
      
      dispc.c is changed to keep track of the sizes of each fifo, and also the
      overlay using each fifo.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      42a6961c
    • T
      Revert "OMAPDSS: APPLY: add fifo merge support funcs" · 85099f11
      Tomi Valkeinen 提交于
      This reverts commit fb011974.
      
      Adding fifo merge feature as an omapdss internal configuration was a
      mistake. We cannot hide from the users of omapdss the complexities of
      fifo merge.
      
      The previous commit removed fifo merge itself, and this removes the
      remaining fifo merge support functions.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      85099f11
    • T
      Revert "OMAPDSS: APPLY: add fifo-merge support" · b3e93cbd
      Tomi Valkeinen 提交于
      This reverts commit 1d71f42b.
      
      Adding fifo merge feature as an omapdss internal configuration was a
      mistake. We cannot hide from the users of omapdss the complexities of
      fifo merge.
      
      This commit removes the fifo merge support, which luckily is easily done
      as it was handled totally inside apply.c. Note that this is not a 1:1
      revert, but some resolving was needed for the dss_ovl_setup_fifo.
      
      The plan is to try fifo merge again later when it is more clear how the
      hardware acts in various situations, and how the omapdrm wants to use
      fifo merge.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      b3e93cbd
    • T
      OMAPDSS: clean up dss_mgr_set_timings · fed62e54
      Tomi Valkeinen 提交于
      dss_mgr_set_timings() can only be called when the output is not active.
      This means that most of the code in the function is extra, as there's no
      need to write the values to registers, etc, because that will be handled
      when the output will be enabled.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      fed62e54
    • T
      OMAPDSS: clean up dss_mgr_set_lcd_config · aba96570
      Tomi Valkeinen 提交于
      dss_mgr_set_lcd_config() can only be called when the output is not
      active. This means that most of the code in the function is extra, as
      there's no need to write the values to registers, etc, because that will
      be handled when the output will be enabled.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      aba96570
    • T
      OMAPDSS: split manager sysfs code · f6a0492e
      Tomi Valkeinen 提交于
      Separate sysfs code for managers to a separate file. This is a bit
      cleaner, and will allow us later to easily switch off the sysfs support
      via Kconfig option.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      f6a0492e
    • T
      OMAPDSS: split overlay sysfs code · 91691516
      Tomi Valkeinen 提交于
      Separate sysfs code for overlays to a separate file. This is a bit
      cleaner, and will allow us later to easily switch off the sysfs support
      via Kconfig option.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      91691516
    • T
      OMAPDSS: TFP410: use devm_gpio_request_one · a6df3fd9
      Tomi Valkeinen 提交于
      Use devm_ version instead of the regular gpio_request_one to simplify
      the error handling.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      a6df3fd9
    • T
      OMAPDSS: Taal: Reogranize for device tree · f075a594
      Tomi Valkeinen 提交于
      Reorganize taal driver to make it easier to integrate device tree code.
      Instead of storing the panel's platform data, we'll "parse" the platform
      data and store the required information in driver's own data. This way
      adding device tree data parsing is simple.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      f075a594
    • T
      OMAPDSS: VRAM: Remove clearing with sDMA · 5ae1f372
      Tomi Valkeinen 提交于
      Currently vram.c clears the allocated memory automatically using OMAP
      system DMA. In an effort to reduce OMAP dependencies, we'll do the
      memory clear with CPU from now on.
      
      The previous patch implemented memory clear in the omapfb driver, and
      this patch removes the now obsolete clear functionality from vram.c.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      Cc: Russell King - ARM Linux <linux@arm.linux.org.uk>
      5ae1f372
    • T
      OMAPFB: clear framebuffers with CPU · ca444158
      Tomi Valkeinen 提交于
      Currently vram.c clears the allocated memory automatically using OMAP
      system DMA. In an effort to reduce OMAP dependencies, we'll do the
      memory clear with CPU from now on.
      
      This patch implements clearing of the framebuffer in omapfb, using
      cfb_fillrect() to do the actual clear.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      ca444158
    • T
      OMAPDSS: remove unnecessary includes · fe6a4662
      Tomi Valkeinen 提交于
      Remove unnecessary includes from omapdss.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      fe6a4662
    • T
      OMAPDSS: Taal: use devm_* functions · 5e56ad44
      Tomi Valkeinen 提交于
      Use devm_ functions in panel-taal.c's probe when possible. Also reorder
      the initialization sequence so that devm_ allocations are done before
      things that require explicit freeing. This simplifies the probe and
      remove functions.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      5e56ad44
    • T
      OMAPDSS: fix use of dssdev->caps · ab585254
      Tomi Valkeinen 提交于
      Recent commit dca2b152 (OMAPDSS: DSI:
      Maintain copy of operation mode in driver data) broke DSI for video mode
      displays. The commit changed the way dssdev->caps are initialized, and
      the result was that every DSI display is initialized with manual-update
      and tear-elim caps.
      
      The code that sets dssdev->caps is not very good, even when fixed.
      omapdss driver shouldn't be writing dssdev->caps at all.
      
      This patch fixes the problem with video mode displays by moving the
      initialization of dssdev->caps to the panel driver. The same change is
      done for RFBI.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      ab585254
    • T
      OMAPDSS: DSI: calculate dsi clock · ee144e64
      Tomi Valkeinen 提交于
      Currently the way to configure clocks related to DSI (both DSI and DISPC
      clocks) happens via omapdss platform data. The reason for this is that
      configuring the DSS clocks is a very complex problem, and it's
      impossible for the SW to know requirements about things like
      interference.
      
      However, for general cases it should be fine to calculate the dividers
      for clocks in the SW. The calculated clocks are probably not perfect,
      but should work.
      
      This patch adds support to calculate the dividers when using DSI command
      mode panels. The panel gives the required DDR clock rate and LP clock
      rate, and the DSI driver configures itself and DISPC accordingly.
      
      This patch is somewhat ugly, though. The code does its job by modifying
      the platform data where the clock dividers would be if the board file
      gave them. This is not how it's going to be in the future, but allows us
      to have quite simple patch and keep the backward compatibility.
      
      It also allows the developer to still give the exact dividers from the
      board file when there's need for that, as long as the panel driver does
      not override them.
      
      There are also other areas for improvement. For example, it would be
      better if the panel driver could ask for a DSI clock in a certain range,
      as, at least command mode panels, the panel can work fine with many
      different clock speeds.
      
      While the patch is not perfect, it allows us to remove the hardcoded
      clock dividers from the board file, making it easier to bring up a new
      panel and to use device tree from omapdss.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      ee144e64
    • T
      OMAPDSS: Add DSI fclk maximum to dss_features · bc63f304
      Tomi Valkeinen 提交于
      Add max value of DSI functional clock to dss_features, so that DSI
      driver can use it.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      bc63f304
    • T
      OMAPDSS: HDMI: use vdda_hdmi_dac · 17486943
      Tomi Valkeinen 提交于
      The HDMI driver requires vdda_hdmi_dac power for operation, but does not
      enable it. This has worked because the regulator has been always
      enabled.
      
      But this may not always be the case, as I encountered when implementing
      HDMI device tree support.
      
      This patch changes the HDMI driver to use the vdda_hdmi_dac.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      17486943
    • T
      OMAPDSS: HDMI: Add delay to wait for 5V power · a84b2065
      Tomi Valkeinen 提交于
      TPD12S015A spec says to wait 300us after setting CT_CP_HPD gpio for the
      5V power output to reach 90% of the voltage. This patch adds the delay
      to the driver.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      a84b2065
    • T
      OMAPDSS: HDMI: Move GPIO handling to HDMI driver · cca35017
      Tomi Valkeinen 提交于
      We currently manage HDMI GPIOs in the board files via
      platform_enable/disable calls. This won't work with device tree, and in
      any case the correct place to manage the GPIOs is in the HDMI driver.
      
      This patch moves the handling of the GPIOs to the HDMI driver. The GPIO
      handling is moved to the common hdmi.c file, and this probably needs to
      be revisited when adding OMAP5 HDMI support to see if the GPIO handling
      needs to be moved to IP specific files.
      Signed-off-by: NTomi Valkeinen <tomi.valkeinen@ti.com>
      Acked-by: NTony Lindgren <tony@atomide.com>
      cca35017
  4. 23 8月, 2012 2 次提交
  5. 22 8月, 2012 6 次提交
  6. 16 8月, 2012 8 次提交
    • A
      OMAPDSS: VENC: Maintian copy of video output polarity info in private data · 89e71956
      Archit Taneja 提交于
      The VENC driver currently relies on the omap_dss_device struct to configure the
      video output polarity. This makes the VENC interface driver dependent on the
      omap_dss_device struct.
      
      Make the VENC driver data maintain it's own polarity field. A panel driver
      is expected to call omapdss_venc_invert_vid_out_polarity() before enabling the
      interface.
      Signed-off-by: NArchit Taneja <archit@ti.com>
      89e71956
    • A
      OMAPDSS: VENC: Maintain copy of venc type in driver data · febe2905
      Archit Taneja 提交于
      The VENC driver currently relies on the omap_dss_device struct to configure the
      venc type. This makes the VENC interface driver dependent on the omap_dss_device
      struct.
      
      Make the VENC driver data maintain it's own 'venc type' field. A panel driver
      is expected to call omapdss_venc_set_type() before enabling the interface or
      changing the type via display sysfs attributes.
      Signed-off-by: NArchit Taneja <archit@ti.com>
      febe2905
    • A
      OMAPDSS: RFBI: Maitain copy of rfbi timings in driver data · 6e883324
      Archit Taneja 提交于
      The RFBI driver currently relies on the omap_dss_device struct to receive the
      rfbi specific timings requested by the panel driver. This makes the RFBI
      interface driver dependent on the omap_dss_device struct.
      
      Make the RFBI driver data maintain it's own rfbi specific timings field. The
      panel driver is expected to call omapdss_rfbi_set_interface_timings() to
      configure the rfbi timings before the interface is enabled.
      Signed-off-by: NArchit Taneja <archit@ti.com>
      6e883324
    • A
      OMAPDSS: DSI: Maintain copy of video mode timings in driver data · 0b3ffe39
      Archit Taneja 提交于
      The DSI driver currently relies on the omap_dss_device struct to receive the
      video mode timings requested by the panel driver. This makes the DSI interface
      driver dependent on the omap_dss_device struct.
      
      Make the DSI driver data maintain it's own video mode timings field. The panel
      driver is expected to call omapdss_dsi_set_videomode_timings() to configure the
      video mode timings before the interface is enabled.
      Signed-off-by: NArchit Taneja <archit@ti.com>
      0b3ffe39
    • A
      OMAPDSS: DSI: Rename dsi_videomode_data to dsi_videomode_timings · 6b849375
      Archit Taneja 提交于
      The struct omap_dss_dsi_videomode_data holds fields which need to be configured
      for DSI to operate in video mode. Rename the struct to dsi_videomode_timings.
      
      One reason to do this is because most of the fields in the struct are timings
      related. The other reason is to create a generic op for output specific
      timings. This generic op can be considered as a way to set custom or private
      timings for the output.
      
      In the case of OMAP, DSI and RFBI require some more timings apart from the
      relgular DISPC timings. The structs omap_dss_videomode_timings and rfbi_timings
      can be considered as these output specific timings respectively.
      Signed-off-by: NArchit Taneja <archit@ti.com>
      6b849375
    • A
      OMAPDSS: DSI: Maintain copy of operation mode in driver data · dca2b152
      Archit Taneja 提交于
      The DSI driver currently relies on the omap_dss_device struct to know the mode
      of operation of the DSI protocol(command or video mode). This makes the DSI
      interface driver dependent on the omap_dss_device struct.
      
      Make the DSI driver data maintain it's own operation mode field. The panel
      driver is expected to call omapdss_dsi_set_operation_mode() before the interface
      is enabled.
      Signed-off-by: NArchit Taneja <archit@ti.com>
      dca2b152
    • A
      OMAPDSS: SDI: Maintain copy of data pairs in driver data · 889b4fd7
      Archit Taneja 提交于
      The SDI driver currently relies on the omap_dss_device struct to configure the
      number of data pairs as specified by the panel. This makes the SDI interface
      driver dependent on the omap_dss_device struct.
      
      Make the SDI driver data maintain it's own data lines field. A panel driver
      is expected to call omapdss_sdi_set_datapairs() before enabling the interface.
      Even though we configure the number of data pairs here, this function would be
      finally mapped to a generic interface op called set_data_lines. The datapairs
      argument type has been changed from u8 to int at some places to be in sync with
      the 'set_data_lines' ops of other interfaces.
      Signed-off-by: NArchit Taneja <archit@ti.com>
      889b4fd7
    • A
      OMAPDSS: DPI: Maintain copy of number of data lines in driver data · c6b393d4
      Archit Taneja 提交于
      The DPI driver currently relies on the omap_dss_device struct to configure the
      number of data lines as specified by the panel. This makes the DPI interface
      driver dependent on the omap_dss_device struct.
      
      Make the DPI driver data maintain it's own data lines field. A panel driver
      is expected to call omapdss_dpi_set_data_lines() before enabling the interface.
      Signed-off-by: NArchit Taneja <archit@ti.com>
      c6b393d4