12 Jan, 2017

1 commit

  • Currently when a simplefb needs both clocks and regulators and one
    of the regulators returns -EPROBE_DEFER when we try to get it, we end
    up disabling the clocks. This causes the screen to go blank; and in some
    cases my cause hardware state to be lost resulting in the framebuffer not
    working at all.

    This commit splits the get and enable steps and only enables
    clocks and regulators after successfully getting all of them,
    fixing the disabling of the clocks which were left enabled by
    the firmware setting up the simplefb.

    Signed-off-by: Hans de Goede
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Hans de Goede
     

27 Sep, 2016

2 commits

  • simplefb gets unregister when a proper framebuffer driver comes in and
    kicks it out. However the claimed clocks and regulators stay enabled
    as they are only released in the platform device remove function, which
    in theory would never get called.

    Move the clock/regulator cleanup into the framebuffer destroy callback,
    which gets called as part of the framebuffer unregister process.

    Note this introduces asymmetry in how the resources are claimed and
    released.

    Signed-off-by: Chen-Yu Tsai
    Reviewed-by: Hans de Goede
    Signed-off-by: Tomi Valkeinen

    Chen-Yu Tsai
     
  • These structures are only used to copy into other structures, so declare
    them as const.

    The semantic patch that makes this change in the fb_fix_screeninfo case is
    as follows (http://coccinelle.lip6.fr/). The fb_var_screeninfo case is
    analogous.

    //
    @r disable optional_qualifier@
    identifier i;
    position p;
    @@
    static struct fb_fix_screeninfo i@p = { ... };

    @ok@
    identifier r.i;
    expression e;
    position p;
    @@
    e = i@p

    @bad@
    position p != {r.p,ok.p};
    identifier r.i;
    struct fb_fix_screeninfo e;
    @@
    e@i@p

    @depends on !bad disable optional_qualifier@
    identifier r.i;
    @@
    static
    +const
    struct fb_fix_screeninfo i = { ... };
    //

    Signed-off-by: Julia Lawall
    Signed-off-by: Tomi Valkeinen

    Julia Lawall
     

27 Feb, 2016

1 commit


15 Dec, 2015

1 commit

  • This claims and enables regulators listed in the simple framebuffer dt
    node. This is needed so that regulators powering the display pipeline
    and external hardware, described in the device node and known by the
    kernel code, will remain properly enabled.

    Signed-off-by: Chen-Yu Tsai
    Acked-by: Mark Brown
    Signed-off-by: Tomi Valkeinen

    Chen-Yu Tsai
     

21 Jul, 2015

1 commit

  • This driver uses the consumer API, so include clk.h explicitly
    instead of impliclty through the provider API.

    Cc: Luc Verhaegen
    Cc: Hans de Goede
    Acked-by: Geert Uytterhoeven
    Cc: Maxime Ripard
    Cc: David Herrmann
    Cc: Tomi Valkeinen
    Signed-off-by: Stephen Boyd

    Stephen Boyd
     

13 Jan, 2015

1 commit

  • of_platform_device_create is only defined when CONFIG_OF_ADDRESS is set,
    which is normally always the case when CONFIG_OF is defined, except on Sparc,
    so explicitly check for CONFIG_OF_ADDRESS rather then for CONFIG_OF.

    Reported-by: kbuild test robot
    Signed-off-by: Hans de Goede
    Signed-off-by: Tomi Valkeinen

    Hans de Goede
     

15 Dec, 2014

1 commit

  • Pull driver core update from Greg KH:
    "Here's the set of driver core patches for 3.19-rc1.

    They are dominated by the removal of the .owner field in platform
    drivers. They touch a lot of files, but they are "simple" changes,
    just removing a line in a structure.

    Other than that, a few minor driver core and debugfs changes. There
    are some ath9k patches coming in through this tree that have been
    acked by the wireless maintainers as they relied on the debugfs
    changes.

    Everything has been in linux-next for a while"

    * tag 'driver-core-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (324 commits)
    Revert "ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries"
    fs: debugfs: add forward declaration for struct device type
    firmware class: Deletion of an unnecessary check before the function call "vunmap"
    firmware loader: fix hung task warning dump
    devcoredump: provide a one-way disable function
    device: Add dev__once variants
    ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries
    ath: use seq_file api for ath9k debugfs files
    debugfs: add helper function to create device related seq_file
    drivers/base: cacheinfo: remove noisy error boot message
    Revert "core: platform: add warning if driver has no owner"
    drivers: base: support cpu cache information interface to userspace via sysfs
    drivers: base: add cpu_device_create to support per-cpu devices
    topology: replace custom attribute macros with standard DEVICE_ATTR*
    cpumask: factor out show_cpumap into separate helper function
    driver core: Fix unbalanced device reference in drivers_probe
    driver core: fix race with userland in device_add()
    sysfs/kernfs: make read requests on pre-alloc files use the buffer.
    sysfs/kernfs: allow attributes to request write buffer be pre-allocated.
    fs: sysfs: return EGBIG on write if offset is larger than file size
    ...

    Linus Torvalds
     

25 Nov, 2014

1 commit


14 Nov, 2014

5 commits

  • One of the reasons for having the simplefb nodes in /chosen, and doing
    explicit enumeration of the nodes there, is too allow enumerating them sooner,
    so that we get a console earlier on.

    Doing this earlier then fs_initcall is not useful, since the fb only turns
    into a console when fbcon intializes, which is a fs_initcall too.

    Signed-off-by: Hans de Goede
    Signed-off-by: Tomi Valkeinen

    Hans de Goede
     
  • Update simplefb to support the new preferred location for simplefb dt nodes
    under /chosen.

    Signed-off-by: Hans de Goede
    Signed-off-by: Tomi Valkeinen

    Hans de Goede
     
  • This claims and enables clocks listed in the simple framebuffer dt node.
    This is needed so that the display engine, in case the required clocks
    are known by the kernel code and are described in the dt, will remain
    properly enabled.

    Signed-off-by: Luc Verhaegen
    [hdegoede@redhat.com: Change clks from list to dynamic array]
    Reviewed-by: Hans de Goede
    Signed-off-by: Hans de Goede
    Acked-by: Geert Uytterhoeven
    Reviewed-by: Maxime Ripard
    Reviewed-by: David Herrmann
    Acked-by: Grant Likely
    Signed-off-by: Tomi Valkeinen

    Luc Verhaegen
     
  • Use the usual kernel style of goto error_foo to free resources on probe
    error. This is a preparation patch for adding clocks support.

    While at it also update ioremap_wc error return from ENODEV to ENOMEM.

    Signed-off-by: Luc Verhaegen
    Acked-by: Stephen Warren
    Reviewed-by: Hans de Goede
    Signed-off-by: Hans de Goede
    Acked-by: Geert Uytterhoeven
    Reviewed-by: Maxime Ripard
    Reviewed-by: David Herrmann
    Acked-by: Grant Likely
    Signed-off-by: Tomi Valkeinen

    Luc Verhaegen
     
  • Add a proper struct describing simplefb private data, with the palette in there,
    instead of directly storing the palette in the fb_info->par pointer.

    Signed-off-by: Luc Verhaegen
    Acked-by: Stephen Warren
    [hdegoede@redhat.com: drop unnecessary void * cast]
    Reviewed-by: Hans de Goede
    Signed-off-by: Hans de Goede
    Acked-by: Geert Uytterhoeven
    Reviewed-by: Maxime Ripard
    Reviewed-by: David Herrmann
    Acked-by: Grant Likely
    Signed-off-by: Tomi Valkeinen

    Luc Verhaegen
     

20 Oct, 2014

1 commit


17 Apr, 2014

1 commit

  • The drivers/video directory is a mess. It contains generic video related
    files, directories for backlight, console, linux logo, lots of fbdev
    device drivers, fbdev framework files.

    Make some order into the chaos by creating drivers/video/fbdev
    directory, and move all fbdev related files there.

    No functionality is changed, although I guess it is possible that some
    subtle Makefile build order related issue could be created by this
    patch.

    Signed-off-by: Tomi Valkeinen
    Acked-by: Laurent Pinchart
    Acked-by: Geert Uytterhoeven
    Acked-by: Rob Clark
    Acked-by: Jingoo Han
    Acked-by: Daniel Vetter

    Tomi Valkeinen