04 Jan, 2012

6 commits

  • Allow the controller to be runtime suspended when the screen is blanked
    by not taking a runtime reference while the device is open. This allows
    greater system wide power savings when used with a standard application
    layer and ensures that the screen does not blank unless requested.

    Signed-off-by: Mark Brown
    Acked-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Mark Brown
     
  • Take a runtime PM reference whenever updating registers in preparation
    for suspending the device when the framebuffer is blanked.

    Signed-off-by: Mark Brown
    Acked-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Mark Brown
     
  • When the framebuffer is unblanked hold a runtime PM reference. This
    prevents us powering down when userspace has left an image on the
    framebuffer and prepares the way for being able to power down the hardware
    when an application still has the device open.

    Since we now hold a runtime PM reference whenever the display is unblanked
    there is no need for the runtime power management to disable and enable
    the display, and doing so would lead to runtime PM trying to recurse into
    itself when called from the blanking code, so split the runtime PM into
    separate functions which only deal with the clocks. The PM core will
    runtime resume the device prior to system suspend.

    Signed-off-by: Mark Brown
    Acked-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Mark Brown
     
  • Signed-off-by: Mark Brown
    Acked-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Mark Brown
     
  • The s3c-fb driver has a function called s3c_fb_enable() which turns on
    and off the physical output. However it is only actually used in paths
    which disable the screen, the enabling just writes to the register. Make
    the code less confusing by ensuring that the enable also goes through
    the same path.

    Signed-off-by: Mark Brown
    Acked-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Mark Brown
     
  • The change in "video: s3c-fb: modify runtime pm functions" (commit
    35784b) renders the runtime power management for the device completely
    ineffectual as while it leaves runtime power management notionally
    enabled a runtime power reference is held for the entire time the device
    is registered meaning it will never actually do anything.

    A further issue is introduced as runtime power management is added
    during the system suspend path which is not something which drivers are
    supposed to do and would interact poorly if there were any operations
    done in the runtime power management callbacks.

    While this does make things simpler (the main motivation for the
    original change) it will not only cause us to use more power in the
    framebuffer controller but will also prevent us entering lower power
    domain and SoC wide states as we can never power down the domain
    containing the device. Since neither of these things is desirable
    revert the change.

    Signed-off-by: Mark Brown
    Acked-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Mark Brown
     

20 Dec, 2011

3 commits

  • Shadow registers should be protectd whenever the registers are
    updated. Shadow registers are updated after SHADOWCON shadow
    register is cleared.

    Signed-off-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Jingoo Han
     
  • Runtime suspend and runtime resume are modified in order to
    reduce the complexity and improve the usability of runtime pm.
    After probe function, s3c-fb driver is not suspended until
    suspend or remove is called.

    The scheme is changed as follows:
    runtime_get is only called in probe and resume.
    runtime_put is only called in remove and suspend.
    open/close cannot call the runtime_get/put.

    Also, runtime_susepnd/resume are just called by runtime pm,
    not doing suspend/resume routine any longer. This is because
    open/close cannot call the runtime_get/put; the suspend/resume
    routine in runtime_suspend/resume were previously used when
    open and close were called.

    The name of s3c-fb dev_pm_ops is changed from s3cfb_pm_ops to
    s3c_fb_pm_ops in order to use more consistent naming.

    Signed-off-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Jingoo Han
     
  • This patch set missing bitmask of enabled hardware window which
    should be checked whenever the hardware window is enabled.

    Signed-off-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Jingoo Han
     

04 Dec, 2011

2 commits

  • The s3c-fb driver has separate runtime and system PM functions but the
    implementations are identical so far as I can tell so unify them for
    simplicity.

    Signed-off-by: Mark Brown
    Acked-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Mark Brown
     
  • This patch converts the drivers in drivers/video/* to use the
    module_platform_driver() macro which makes the code smaller and a bit
    simpler.

    Cc: Ben Dooks
    Cc: Manuel Lauss
    Signed-off-by: Axel Lin
    Acked-by: Wan ZongShun
    Acked-by: Sascha Hauer
    Acked-by: Lennert Buytenhek
    Acked-by: Alexey Charkov
    Acked-by: Damian Hobson-Garcia
    Acked-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Axel Lin
     

12 Nov, 2011

1 commit


15 Sep, 2011

1 commit


24 Aug, 2011

1 commit

  • This patch adds struct s3c_fb_driverdata s3c_fb_data_exynos4 for EXYNOS4
    and adds lcd clock gating support.

    FIMD driver needs two clocks for FIMD IP and LCD pixel clock. Previously,
    both clocks are provided by using bus clock such as HCLK. However, EXYNOS4
    can not select HCLK for LCD pixel clock because the EXYNOS4 FIMD IP does not
    have the CLKSEL bit of VIDCON0. So, FIMD driver should provide the lcd clock
    using SCLK_FIMD as LCD pixel clock for EXYNOS4.

    The driver selects enabling lcd clock according to has_clksel which means
    the CLKSEL bit of VIDCON0. If there is has_clksel, the driver will not
    enable the lcd clock using SCLK_FIMD because bus clock using HCLK is used
    a LCD pixel clock.

    Signed-off-by: Jingoo Han
    Signed-off-by: Florian Tobias Schandinat

    Jingoo Han
     

19 Aug, 2011

1 commit


09 Jun, 2011

3 commits

  • This patch moves enabling channel for window, because there should
    be enabling channel before enabling window. If the sequence is
    reversed, it makes the problem in displaying images to lcd panel.

    Signed-off-by: Jingoo Han
    Signed-off-by: Paul Mundt

    Jingoo Han
     
  • This patch fixes mishandling in virtual resolution checking.
    Previously, virtual resolution is changed to virtual_x and virtual_y
    which mean the size for buffer allocation, when s3c_fb_check_var is
    called by fb_check_var. However, it is meaningless, since virtual_x
    and virtual_y are fixed and user cannot change virtual resolution.
    Therefore, virtual resolution should be more than resolution
    such as xres and yres.

    Signed-off-by: Jingoo Han
    Signed-off-by: Paul Mundt

    Jingoo Han
     
  • This patch fixes misleading kfree in remove function.

    Signed-off-by: Jingoo Han
    Signed-off-by: Paul Mundt

    Jingoo Han
     

24 May, 2011

6 commits


12 Apr, 2011

2 commits


07 Apr, 2011

1 commit

  • This patch fixes the checkpatch errors listed below:

    ERROR: space required before the open parenthesis '('
    ERROR: need consistent spacing around '+' (ctx:WxV)
    ERROR: space prohibited before that close parenthesis ')'

    Also, following warning is fixed by adding 'platid' variable
    which can reduce number of lines exceeding 80 characters.

    WARNING: line over 80 characters

    Signed-off-by: Jingoo Han
    Signed-off-by: Paul Mundt

    Jingoo Han
     

22 Mar, 2011

1 commit


21 Dec, 2010

1 commit

  • This patch adds support for runtime pm using the functions.
    - pm_runtime_get_sync()
    - pm_runtime_put_sync()

    pm_runtime_get_sync() and pm_runtime_put_sync() are called when
    open or release function of framebufer driver is called to inform
    the system if hardware is idle or not.

    Signed-off-by: Jingoo Han
    Signed-off-by: Paul Mundt

    Jingoo Han
     

11 Aug, 2010

11 commits

  • Add a simple algorithm which calculates the pixel clock based on the video
    mode parameters. This is only done when no pixel clock is supplied
    through the platform data.

    This allows drivers to omit the pixel clock data and thus share the
    algorithm used for calculating it.

    Signed-off-by: Maurus Cuelenaere
    Cc: Pawel Osciak
    Cc: Marek Szyprowski
    Cc: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Russell King
    Tested-by: Donghwa Lee
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Maurus Cuelenaere
     
  • S5PV210 SoCs allow enabling/disabling DMA channels per window. For a
    window to display data from framebuffer memory, its channel has to be
    enabled.

    Signed-off-by: Pawel Osciak
    Signed-off-by: Marek Szyprowski
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak
     
  • This patch fixes the following section mismatch errors:

    WARNING: vmlinux.o(.data+0x20b40): Section mismatch in reference from the variable s3c_fb_driver_ids to the (unknown reference) .devinit.data:(unknown)
    The variable s3c_fb_driver_ids references
    the (unknown reference) __devinitdata (unknown)
    If the reference is valid then annotate the
    variable with __init* or __refdata (see linux/init.h) or name the variable:
    *driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console,

    WARNING: vmlinux.o(.data+0x20b58): Section mismatch in reference from the variable s3c_fb_driver_ids to the (unknown reference) .devinit.data:(unknown)
    The variable s3c_fb_driver_ids references
    the (unknown reference) __devinitdata (unknown)
    If the reference is valid then annotate the
    variable with __init* or __refdata (see linux/init.h) or name the variable:
    *driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console,

    WARNING: vmlinux.o(.data+0x20b70): Section mismatch in reference from the variable s3c_fb_driver_ids to the (unknown reference) .devinit.data:(unknown)
    The variable s3c_fb_driver_ids references
    the (unknown reference) __devinitdata (unknown)
    If the reference is valid then annotate the
    variable with __init* or __refdata (see linux/init.h) or name the variable:
    *driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console,

    Signed-off-by: Marek Szyprowski
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Marek Szyprowski
     
  • Newer hardware (S3C6410, S5P) have the ability to block updates from
    shadow registers during reconfiguration. Add protect calls for set_par
    and clear protection when resetting.

    Signed-off-by: Pawel Osciak
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak
     
  • S3C64xx and S5P OSD registers for OSD size and alpha are as follows:
    VIDOSDC: win 0 - size, win 1-4: alpha
    VIDOSDD: win 1-2 - size; not present for windows 0, 3 and 4

    Signed-off-by: Pawel Osciak
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak
     
  • S5PV210 allows per-window locking of register value updates from shadow
    registers.

    Signed-off-by: Pawel Osciak
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak
     
  • Signed-off-by: Pawel Osciak
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak
     
  • Add VSYNC interrupt support and an ioctl that allows waiting for it.
    Interrupts are turned on only when needed.

    Signed-off-by: Pawel Osciak
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak
     
  • Supports all bpp modes.

    The PRTCON register is used to disable in-hardware updates of registers
    that store start and end addresses of framebuffer memory. This prevents
    display corruption in case we do not make it before VSYNC with updating
    them atomically. With this feature there is no need to wait for a VSYNC
    interrupt before each such update.

    Signed-off-by: Pawel Osciak
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak
     
  • S5PC100 and S5PV210 framebuffer devices differ slightly in terms of
    available registers and their driver data structures have to be separate.
    Those differences include dissimilar ways to control shadow register
    updates.

    Signed-off-by: Pawel Osciak
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak
     
  • The following problems were found in the above situation:

    sfb->windows[win] was being assigned at the end of s3c_fb_probe_win only.
    This resulted in passing a NULL to s3c_fb_release_win if probe_win
    returned early and a memory leak.

    dma_free_writecombine does not allow its third argument to be NULL.

    fb_dealloc_cmap does not verify whether its argument is not NULL.

    Signed-off-by: Pawel Osciak
    Signed-off-by: Kyungmin Park
    Cc: InKi Dae
    Cc: Ben Dooks
    Cc: Marek Szyprowski
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pawel Osciak