26 Oct, 2020

1 commit


08 Sep, 2020

1 commit

  • The only in-tree user for mbx driver for Intel 2700G graphics chip was
    cm-x270 platform. Since this platform was removed by the commit
    9d3239147d6d ("ARM: pxa: remove Compulab pxa2xx boards") there is no
    point to keep the obsolete framebuffer driver.

    Signed-off-by: Mike Rapoport
    Cc: Jonathan Corbet
    Cc: Arnd Bergmann
    Signed-off-by: Bartlomiej Zolnierkiewicz
    Link: https://patchwork.freedesktop.org/patch/msgid/20200830115524.431278-1-rppt@kernel.org

    Mike Rapoport
     

02 Mar, 2020

1 commit

  • The current codebase makes use of the zero-length array language
    extension to the C90 standard, but the preferred mechanism to declare
    variable-length types such as these ones is a flexible array member[1][2],
    introduced in C99:

    struct foo {
    int stuff;
    struct boo array[];
    };

    By making use of the mechanism above, we will get a compiler warning
    in case the flexible array does not occur last in the structure, which
    will help us prevent some kind of undefined behavior bugs from being
    inadvertently introduced[3] to the codebase from now on.

    Also, notice that, dynamic memory allocations won't be affected by
    this change:

    "Flexible array members have incomplete type, and so the sizeof operator
    may not be applied. As a quirk of the original implementation of
    zero-length arrays, sizeof evaluates to zero."[1]

    This issue was found with the help of Coccinelle.

    [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html
    [2] https://github.com/KSPP/linux/issues/21
    [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour")

    Signed-off-by: Gustavo A. R. Silva
    Signed-off-by: Bartlomiej Zolnierkiewicz
    Link: https://patchwork.freedesktop.org/patch/msgid/20200221160005.GA13552@embeddedor

    Gustavo A. R. Silva
     

16 Jan, 2020

1 commit

  • Fix up inconsistent usage of upper and lowercase letters in "Exynos"
    name.

    "EXYNOS" is not an abbreviation but a regular trademarked name.
    Therefore it should be written with lowercase letters starting with
    capital letter.

    The lowercase "Exynos" name is promoted by its manufacturer Samsung
    Electronics Co., Ltd., in advertisement materials and on website.

    Signed-off-by: Krzysztof Kozlowski
    Signed-off-by: Bartlomiej Zolnierkiewicz
    Link: https://patchwork.freedesktop.org/patch/msgid/20200104152107.11407-16-krzk@kernel.org

    Krzysztof Kozlowski
     

07 Nov, 2019

4 commits

  • The DCS command has been named SET_PARTIAL_ROWS in the DCS spec since
    v1.02, for more than a decade. Rename the enumeration to match the spec.

    v2: add comment about the rename (David Lechner)

    Cc: David Lechner
    Cc: Vandita Kulkarni
    Reviewed-by: Thierry Reding
    Signed-off-by: Jani Nikula
    Link: https://patchwork.freedesktop.org/patch/msgid/20191028150047.22048-4-jani.nikula@intel.com

    Jani Nikula
     
  • Update from the DCS specification.

    Cc: Vandita Kulkarni
    Reviewed-by: Thierry Reding
    Signed-off-by: Jani Nikula
    Link: https://patchwork.freedesktop.org/patch/msgid/20191028150047.22048-3-jani.nikula@intel.com

    Jani Nikula
     
  • Add execute queue and compressed pixel stream packet data types for
    completeness.

    Cc: Vandita Kulkarni
    Reviewed-by: Vandita Kulkarni
    Reviewed-by: Thierry Reding
    Signed-off-by: Jani Nikula
    Link: https://patchwork.freedesktop.org/patch/msgid/20191028150047.22048-2-jani.nikula@intel.com

    Jani Nikula
     
  • Rename picture parameter set (it's a long packet, not a long write) and
    compression mode (it's not a DCS command) enumerations according to the
    DSI specification. Order the types according to the spec. Use tabs
    instead of spaces for indentation. Use all lower case for hex.

    Cc: Vandita Kulkarni
    Reviewed-by: Vandita Kulkarni
    Reviewed-by: Thierry Reding
    Signed-off-by: Jani Nikula
    Link: https://patchwork.freedesktop.org/patch/msgid/20191028150047.22048-1-jani.nikula@intel.com

    Jani Nikula
     

26 Aug, 2019

1 commit


16 Jul, 2019

1 commit

  • Pull drm updates from Dave Airlie:
    "The biggest thing in this is the AMD Navi GPU support, this again
    contains a bunch of header files that are large. These are the new AMD
    RX5700 GPUs that just recently became available.

    New drivers:
    - ST-Ericsson MCDE driver
    - Ingenic JZ47xx SoC

    UAPI change:
    - HDR source metadata property

    Core:
    - HDR inforframes and EDID parsing
    - drm hdmi infoframe unpacking
    - remove prime sg_table caching into dma-buf
    - New gem vram helpers to reduce driver code
    - Lots of drmP.h removal
    - reservation fencing fix
    - documentation updates
    - drm_fb_helper_connector removed
    - mode name command handler rewrite

    fbcon:
    - Remove the fbcon notifiers

    ttm:
    - forward progress fixes

    dma-buf:
    - make mmap call optional
    - debugfs refcount fixes
    - dma-fence free with pending signals fix
    - each dma-buf gets an inode

    Panels:
    - Lots of additional panel bindings

    amdgpu:
    - initial navi10 support
    - avoid hw reset
    - HDR metadata support
    - new thermal sensors for vega asics
    - RAS fixes
    - use HMM rather than MMU notifier
    - xgmi topology via kfd
    - SR-IOV fixes
    - driver reload fixes
    - DC use a core bpc attribute
    - Aux fixes for DC
    - Bandwidth calc updates for DC
    - Clock handling refactor
    - kfd VEGAM support

    vmwgfx:
    - Coherent memory support changes

    i915:
    - HDR Support
    - HDMI i2c link
    - Icelake multi-segmented gamma support
    - GuC firmware update
    - Mule Creek Canyon PCH support for EHL
    - EHL platform updtes
    - move i915.alpha_support to i915.force_probe
    - runtime PM refactoring
    - VBT parsing refactoring
    - DSI fixes
    - struct mutex dependency reduction
    - GEM code reorg

    mali-dp:
    - Komeda driver features

    msm:
    - dsi vs EPROBE_DEFER fixes
    - msm8998 snapdragon 835 support
    - a540 gpu support
    - mdp5 and dpu interconnect support

    exynos:
    - drmP.h removal

    tegra:
    - misc fixes

    tda998x:
    - audio support improvements
    - pixel repeated mode support
    - quantisation range handling corrections
    - HDMI vendor info fix

    armada:
    - interlace support fix
    - overlay/video plane register handling refactor
    - add gamma support

    rockchip:
    - RX3328 support

    panfrost:
    - expose perf counters via hidden ioctls

    vkms:
    - enumerate CRC sources list

    ast:
    - rework BO handling

    mgag200:
    - rework BO handling

    dw-hdmi:
    - suspend/resume support

    rcar-du:
    - R8A774A1 Soc Support
    - LVDS dual-link mode support
    - Additional formats
    - Misc fixes

    omapdrm:
    - DSI command mode display support

    stm
    - fb modifier support
    - runtime PM support

    sun4i:
    - use vmap ops

    vc4:
    - binner bo binding rework

    v3d:
    - compute shader support
    - resync/sync fixes
    - job management refactoring

    lima:
    - NULL pointer in irq handler fix
    - scheduler default timeout

    virtio:
    - fence seqno support
    - trace events

    bochs:
    - misc fixes

    tc458767:
    - IRQ/HDP handling

    sii902x:
    - HDMI audio support

    atmel-hlcdc:
    - misc fixes

    meson:
    - zpos support"

    * tag 'drm-next-2019-07-16' of git://anongit.freedesktop.org/drm/drm: (1815 commits)
    Revert "Merge branch 'vmwgfx-next' of git://people.freedesktop.org/~thomash/linux into drm-next"
    Revert "mm: adjust apply_to_pfn_range interface for dropped token."
    mm: adjust apply_to_pfn_range interface for dropped token.
    drm/amdgpu/navi10: add uclk activity sensor
    drm/amdgpu: properly guard the generic discovery code
    drm/amdgpu: add missing documentation on new module parameters
    drm/amdgpu: don't invalidate caches in RELEASE_MEM, only do the writeback
    drm/amd/display: avoid 64-bit division
    drm/amdgpu/psp11: simplify the ucode register logic
    drm/amdgpu: properly guard DC support in navi code
    drm/amd/powerplay: vega20: fix uninitialized variable use
    drm/amd/display: dcn20: include linux/delay.h
    amdgpu: make pmu support optional
    drm/amd/powerplay: Zero initialize current_rpm in vega20_get_fan_speed_percent
    drm/amd/powerplay: Zero initialize freq in smu_v11_0_get_current_clk_freq
    drm/amd/powerplay: Use memset to initialize metrics structs
    drm/amdgpu/mes10.1: Fix header guard
    drm/amd/powerplay: add temperature sensor support for navi10
    drm/amdgpu: fix scheduler timeout calc
    drm/amdgpu: Prepare for hmm_range_register API change (v2)
    ...

    Linus Torvalds
     

10 Jul, 2019

1 commit

  • Pull fbdev updates from Bartlomiej Zolnierkiewicz:

    - remove fbdev notifier usage for fbcon (as prep work to clean up the
    fbcon locking), add locking checks in vt/console code and make
    assorted cleanups in fbdev and backlight code (Daniel Vetter)

    - add COMPILE_TEST support to atmel_lcdfb, da8xx-fb, gbefb, imxfb,
    pvr2fb and pxa168fb drivers (me)

    - fix DMA API abuse in au1200fb and jz4740_fb drivers (Christoph
    Hellwig)

    - add check for new BGRT status field rotation bits in efifb driver
    (Hans de Goede)

    - mark expected switch fall-throughs in s3c-fb driver (Gustavo A. R.
    Silva)

    - remove fbdev mxsfb driver in favour of the drm version (Fabio
    Estevam)

    - remove broken rfbi code from omap2fb driver (me)

    - misc fixes (Arnd Bergmann, Shobhit Kukreti, Wei Yongjun, me)

    - misc cleanups (Gustavo A. R. Silva, Colin Ian King, me)

    * tag 'fbdev-v5.3' of git://github.com/bzolnier/linux: (62 commits)
    video: fbdev: imxfb: fix a typo in imxfb_probe()
    video: fbdev: s3c-fb: Mark expected switch fall-throughs
    video: fbdev: s3c-fb: fix sparse warnings about using incorrect types
    video: fbdev: don't print error message on framebuffer_alloc() failure
    video: fbdev: intelfb: return -ENOMEM on framebuffer_alloc() failure
    video: fbdev: s3c-fb: return -ENOMEM on framebuffer_alloc() failure
    vga_switcheroo: Depend upon fbcon being built-in, if enabled
    video: fbdev: omap2: remove rfbi
    video: fbdev: atmel_lcdfb: remove redundant initialization to variable ret
    video: fbdev-MMP: Use struct_size() in devm_kzalloc()
    video: fbdev: controlfb: fix warnings about comparing pointer to 0
    efifb: BGRT: Add check for new BGRT status field rotation bits
    jz4740_fb: fix DMA API abuse
    video: fbdev: pvr2fb: fix link error for pvr2fb_pci_exit
    video: fbdev: s3c-fb: add COMPILE_TEST support
    video: fbdev: imxfb: fix sparse warnings about using incorrect types
    video: fbdev: pvr2fb: fix build warning when compiling as module
    fbcon: Export fbcon_update_vcs
    backlight: simplify lcd notifier
    staging/olpc_dcon: Add drm conversion to TODO
    ...

    Linus Torvalds
     

21 Jun, 2019

1 commit

  • Equivalent of drm's commit aa61321d4c08 ("drm/omap: remove rfbi").

    The RFBI driver has been marked as BROKEN and has not been
    included in the kernel build for many years. Just remove it
    (it can be trivially brought back from git repository if
    ever needed).

    Cc: Tomi Valkeinen
    Cc: Laurent Pinchart
    Cc: Aaro Koskinen
    Cc: Tony Lindgren
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Bartlomiej Zolnierkiewicz
     

19 Jun, 2019

2 commits

  • Based on 2 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation #

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 4122 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Enrico Weigelt
    Reviewed-by: Kate Stewart
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation this program is
    distributed in the hope that it will be useful but without any
    warranty without even the implied warranty of merchantability or
    fitness for a particular purpose see the gnu general public license
    for more details you should have received a copy of the gnu general
    public license along with this program if not see http www gnu org
    licenses

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 503 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Alexios Zavras
    Reviewed-by: Allison Randal
    Reviewed-by: Enrico Weigelt
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190602204653.811534538@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

14 Jun, 2019

1 commit

  • Only providing the input and output RGB/YUV space to the IC task init
    functions is not sufficient. To fully characterize a colorspace
    conversion, the Y'CbCr encoding standard, and quantization also
    need to be specified.

    Define a 'struct ipu_ic_colorspace' that includes all the above.

    This allows to actually enforce the fact that the IC:

    - can only encode to/from YUV and RGB full range. A follow-up patch will
    remove this restriction.
    - can only encode using BT.601 standard. A follow-up patch will add
    Rec.709 encoding support.

    The determination of the CSC coefficients based on the input/output
    'struct ipu_ic_colorspace' are moved to a new exported function
    ipu_ic_calc_csc(), and 'struct ic_csc_params' is exported as
    'struct ipu_ic_csc_params'. ipu_ic_calc_csc() fills a 'struct ipu_ic_csc'
    with the input/output 'struct ipu_ic_colorspace' and the calculated
    'struct ic_csc_params' from those input/output colorspaces.

    The functions ipu_ic_task_init(_rsc)() now take a filled 'struct
    ipu_ic_csc'.

    The existing CSC coefficient tables and ipu_ic_calc_csc() are moved
    to a new module ipu-ic-csc.c. This is in preparation for adding more
    coefficient tables for limited range quantization and more encoding
    standards.

    The existing ycbcr2rgb and inverse rgb2ycbcr tables defined the BT.601
    Y'CbCr encoding coefficients. The rgb2ycbcr table specifically described
    the BT.601 encoding from full range RGB to full range YUV. Table
    comments have been added in ipu-ic-csc.c to make this more clear.

    The ycbcr2rgb inverse table described encoding YUV limited range to RGB
    full range. To be consistent with the rgb2ycbcr table, this table is
    converted to YUV full range to RGB full range, and the comments are
    expanded in ipu-ic-csc.c.

    The ic_csc_rgb2rgb table was just an identity matrix, so it is renamed
    'identity' in ipu-ic-csc.c.

    Signed-off-by: Steve Longerbeam
    [p.zabel@pengutronix.de: removed a superfluous blank line]
    Signed-off-by: Philipp Zabel

    Steve Longerbeam
     

05 Jun, 2019

3 commits

  • Based on 1 normalized pattern(s):

    this file is released under the gplv2

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 68 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Armijn Hemel
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190531190114.292346262@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Based on 1 normalized pattern(s):

    this file is subject to the terms and conditions of the gnu general
    public license version 2 as published by the free software
    foundation

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 1 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Armijn Hemel
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190531081035.220801321@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation this program is
    distributed in the hope that it will be useful but without any
    warranty without even the implied warranty of merchantability or
    fitness for a particular purpose see the gnu general public license
    for more details you should have received a copy of the gnu general
    public license along with this program if not write to the free
    software foundation inc 59 temple place suite 330 boston ma 02111
    1307 usa

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 136 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Alexios Zavras
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190530000436.384967451@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

31 May, 2019

3 commits

  • Based on 3 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version this program is distributed in the
    hope that it will be useful but without any warranty without even
    the implied warranty of merchantability or fitness for a particular
    purpose see the gnu general public license for more details

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version [author] [kishon] [vijay] [abraham]
    [i] [kishon]@[ti] [com] this program is distributed in the hope that
    it will be useful but without any warranty without even the implied
    warranty of merchantability or fitness for a particular purpose see
    the gnu general public license for more details

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version [author] [graeme] [gregory]
    [gg]@[slimlogic] [co] [uk] [author] [kishon] [vijay] [abraham] [i]
    [kishon]@[ti] [com] [based] [on] [twl6030]_[usb] [c] [author] [hema]
    [hk] [hemahk]@[ti] [com] this program is distributed in the hope
    that it will be useful but without any warranty without even the
    implied warranty of merchantability or fitness for a particular
    purpose see the gnu general public license for more details

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 1105 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Reviewed-by: Richard Fontana
    Reviewed-by: Kate Stewart
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190527070033.202006027@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version this program is distributed in the
    hope that it will be useful but without any warranty without even
    the implied warranty of merchantability or fitness for a particular
    purpose see the gnu general public license for more details you
    should have received a copy of the gnu general public license along
    with this program if not write to the free software foundation inc
    59 temple place suite 330 boston ma 02111 1307 usa

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 1334 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Reviewed-by: Richard Fontana
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190527070033.113240726@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 3029 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190527070032.746973796@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

24 May, 2019

1 commit

  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the named license
    or any later version this program is distributed in the hope that it
    will be useful but without any warranty without even the implied
    warranty of merchantability or fitness for a particular purpose see
    the gnu general public license for more details you should have
    received a copy of the gnu general public license along with this
    program if not write to the free software foundation inc 59 temple
    place suite 330 boston ma 02111 1307 usa

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 7 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Reviewed-by: Kate Stewart
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190520170856.731149235@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

21 May, 2019

1 commit

  • Based on 2 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version this program is distributed in the
    hope that it will be useful but without any warranty without even
    the implied warranty of merchantability or fitness for a particular
    purpose see the gnu general public license for more details you
    should have received a copy of the gnu general public license along
    with this program if not see http www gnu org licenses

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version this program is distributed in the
    hope that it will be useful but without any warranty without even
    the implied warranty of merchantability or fitness for a particular
    purpose see the gnu general public license for more details [based]
    [from] [clk] [highbank] [c] you should have received a copy of the
    gnu general public license along with this program if not see http
    www gnu org licenses

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 355 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Kate Stewart
    Reviewed-by: Jilayne Lovejoy
    Reviewed-by: Steve Winslow
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190519154041.837383322@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

01 Apr, 2019

2 commits

  • Rendering calls may be done simultaneously from the workqueue,
    dlfb_ops_write, dlfb_ops_ioctl, dlfb_ops_set_par and dlfb_dpy_deferred_io.
    The code is robust enough so that it won't crash on concurrent rendering.

    However, concurrent rendering may cause display corruption if the same
    pixel is simultaneously being rendered. In order to avoid this corruption,
    this patch adds a mutex around the rendering calls.

    Signed-off-by: Mikulas Patocka
    Cc: Bernie Thompson
    Cc: Ladislav Michl
    Cc:
    [b.zolnierkie: replace "dlfb:" with "uldfb:" in the patch summary]
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Mikulas Patocka
     
  • If a framebuffer device is used as a console, the rendering calls
    (copyarea, fillrect, imageblit) may be done with the console spinlock
    held. On udlfb, these function call dlfb_handle_damage that takes a
    blocking semaphore before acquiring an URB.

    In order to fix the bug, this patch changes the calls copyarea, fillrect
    and imageblit to offload USB work to a workqueue.

    A side effect of this patch is 3x improvement in console scrolling speed
    because the device doesn't have to be updated after each copyarea call.

    Signed-off-by: Mikulas Patocka
    Cc: Bernie Thompson
    Cc: Ladislav Michl
    Cc:
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Mikulas Patocka
     

10 Mar, 2019

1 commit

  • Pull media updates from Mauro Carvalho Chehab:

    - remove sensor drivers that got converted from soc_camera

    - remaining soc_camera drivers got moved to staging

    - some documentation cleanups and improvements

    - the imx staging driver now supports imx7

    - the ov9640, mt9m001 and mt9m111 got converted from soc_camera

    - the vim2m driver now does what a m2m convert driver expects to do

    - epoll() fixes on media subsystems

    - several drivers fixes, typos, cleanups and improvements

    * tag 'media/v5.1-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (346 commits)
    media: dvb/earth-pt1: fix wrong initialization for demod blocks
    media: vim2m: Address some coding style issues
    media: vim2m: don't use BUG()
    media: vim2m: speedup passthrough copy
    media: vim2m: add an horizontal scaler
    media: vim2m: don't accept YUYV anymore as output format
    media: vim2m: add vertical linear scaler
    media: vim2m: better handle cap/out buffers with different sizes
    media: vim2m: use different framesizes for bayer formats
    media: vim2m: add support for VIDIOC_ENUM_FRAMESIZES
    media: vim2m: ensure that width is multiple of two
    media: vim2m: improve debug messages
    media: vim2m: add bayer capture formats
    media: a few more typos at staging, pci, platform, radio and usb
    media: Documentation: fix several typos
    media: staging: fix several typos
    media: include: fix several typos
    media: common: fix several typos
    media: v4l2-core: fix several typos
    media: usb: fix several typos
    ...

    Linus Torvalds
     

22 Feb, 2019

1 commit


17 Jan, 2019

2 commits

  • To support interlaced scan with planar formats, cpmem SLUV must
    be programmed with the correct chroma line stride. For full and
    partial planar 4:2:2 (YUV422P, NV16), chroma line stride must
    be doubled. For full and partial planar 4:2:0 (YUV420, YVU420, NV12),
    chroma line stride must _not_ be doubled, since a single chroma line
    is shared by two luma lines.

    Signed-off-by: Steve Longerbeam
    Reviewed-by: Philipp Zabel
    Signed-off-by: Hans Verkuil
    Signed-off-by: Mauro Carvalho Chehab

    Steve Longerbeam
     
  • The function ipu_csi_init_interface() was inverting the F-bit for
    NTSC case, in the CCIR_CODE_1/2 registers. The result being that
    for NTSC bottom-top field order, the CSI would swap fields and
    capture in top-bottom order.

    Instead, base field swap on the field order of the input to the CSI,
    and the field order of the requested output. If the input/output
    fields are sequential but different, swap fields, otherwise do
    not swap. This requires passing both the input and output mbus
    frame formats to ipu_csi_init_interface().

    Move this code to a new private function ipu_csi_set_bt_interlaced_codes()
    that programs the CCIR_CODE_1/2 registers for interlaced BT.656 (and
    possibly interlaced BT.1120 in the future).

    When detecting input video standard from the input frame width/height,
    make sure to double height if input field type is alternate, since
    in that case input height only includes lines for one field.

    Signed-off-by: Steve Longerbeam
    Reviewed-by: Philipp Zabel
    Signed-off-by: Hans Verkuil
    Signed-off-by: Mauro Carvalho Chehab

    Steve Longerbeam
     

14 Dec, 2018

2 commits


05 Nov, 2018

2 commits


08 Oct, 2018

1 commit

  • The udlfb driver maintained an open count and cleaned up itself when the
    count reached zero. But the console is also counted in the reference count
    - so, if the user unplugged the device, the open count would not drop to
    zero and the driver stayed loaded with console attached. If the user
    re-plugged the adapter, it would create a device /dev/fb1, show green
    screen and the access to the console would be lost.

    The framebuffer subsystem has reference counting on its own - in order to
    fix the unplug bug, we rely the framebuffer reference counting. When the
    user unplugs the adapter, we call unregister_framebuffer unconditionally.
    unregister_framebuffer will unbind the console, wait until all users stop
    using the framebuffer and then call the fb_destroy method. The fb_destroy
    cleans up the USB driver.

    This patch makes the following changes:
    * Drop dlfb->kref and rely on implicit framebuffer reference counting
    instead.
    * dlfb_usb_disconnect calls unregister_framebuffer, the rest of driver
    cleanup is done in the function dlfb_ops_destroy. dlfb_ops_destroy will
    be called by the framebuffer subsystem when no processes have the
    framebuffer open or mapped.
    * We don't use workqueue during initialization, but initialize directly
    from dlfb_usb_probe. The workqueue could race with dlfb_usb_disconnect
    and this racing would produce various kinds of memory corruption.
    * We use usb_get_dev and usb_put_dev to make sure that the USB subsystem
    doesn't free the device under us.

    Signed-off-by: Mikulas Patocka
    cc: Dave Airlie
    Cc: Bernie Thompson ,
    Cc: Ladislav Michl
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Mikulas Patocka
     

24 Aug, 2018

1 commit

  • Pull fbdev updates from Bartlomiej Zolnierkiewicz:
    "Mostly small fixes and cleanups for fb drivers (the biggest updates
    are for udlfb and pxafb drivers). This also adds deferred console
    takeover support to the console code and efifb driver.

    Summary:

    - add support for deferred console takeover, when enabled defers
    fbcon taking over the console from the dummy console until the
    first text is displayed on the console - together with the "quiet"
    kernel commandline option this allows fbcon to still be used
    together with a smooth graphical bootup (Hans de Goede)

    - improve console locking debugging code (Thomas Zimmermann)

    - copy the ACPI BGRT boot graphics to the framebuffer when deferred
    console takeover support is used in efifb driver (Hans de Goede)

    - update udlfb driver - fix lost console when the user unplugs a USB
    adapter, fix the screen corruption issue, fix locking and add some
    performance optimizations (Mikulas Patocka)

    - update pxafb driver - fix using uninitialized memory, switch to
    devm_* API, handle initialization errors and add support for
    lcd-supply regulator (Daniel Mack)

    - add support for boards booted with a DeviceTree in pxa3xx_gcu
    driver (Daniel Mack)

    - rename omap2 module to omap2fb.ko to avoid conflicts with omap1
    driver (Arnd Bergmann)

    - enable ACPI-based enumeration for goldfishfb driver (Yu Ning)

    - fix goldfishfb driver to make user space Android code use 60 fps
    (Christoffer Dall)

    - print big fat warning when nomodeset kernel parameter is used in
    vgacon driver (Lyude Paul)

    - remove VLA usage from fsl-diu-fb driver (Kees Cook)

    - misc fixes (Julia Lawall, Geert Uytterhoeven, Fredrik Noring,
    Yisheng Xie, Dan Carpenter, Daniel Vetter, Anton Vasilyev, Randy
    Dunlap, Gustavo A. R. Silva, Colin Ian King, Fengguang Wu)

    - misc cleanups (Roman Kiryanov, Yisheng Xie, Colin Ian King)"

    * tag 'fbdev-v4.19' of https://github.com/bzolnier/linux: (54 commits)
    Documentation/fb: corrections for fbcon.txt
    fbcon: Do not takeover the console from atomic context
    dummycon: Stop exporting dummycon_[un]register_output_notifier
    fbcon: Only defer console takeover if the current console driver is the dummycon
    fbcon: Only allow FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER if fbdev is builtin
    fbdev: omap2: omapfb: fix ifnullfree.cocci warnings
    fbdev: omap2: omapfb: fix bugon.cocci warnings
    fbdev: omap2: omapfb: fix boolreturn.cocci warnings
    fb: amifb: fix build warnings when not builtin
    fbdev/core: Disable console-lock warnings when fb.lockless_register_fb is set
    console: Replace #if 0 with atomic var 'ignore_console_lock_warning'
    udlfb: use spin_lock_irq instead of spin_lock_irqsave
    udlfb: avoid prefetch
    udlfb: optimization - test the backing buffer
    udlfb: allow reallocating the framebuffer
    udlfb: set line_length in dlfb_ops_set_par
    udlfb: handle allocation failure
    udlfb: set optimal write delay
    udlfb: make a local copy of fb_ops
    udlfb: don't switch if we are switching to the same videomode
    ...

    Linus Torvalds
     

25 Jul, 2018

5 commits

  • This patch changes udlfb so that it may reallocate the framebuffer when
    setting higher-resolution mode. If we boot the system without monitor
    attached, udlfb creates a framebuffer with the size 800x600. This patch
    makes it possible to select higher videomode with the fbset command when
    a monitor is attached.

    Note that there is no reliable way to prevent the system from touching the
    old framebuffer, so we must not free it. We add it to the list
    dlfb->deferred_free and free it when the driver is unloaded.

    Signed-off-by: Mikulas Patocka
    [b.zolnierkie: sparse fixes]
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Mikulas Patocka
     
  • The default delay 5 jiffies is too much when the kernel is compiled with
    HZ=100 - it results in jumpy cursor in Xwindow.

    In order to find out the optimal delay, I benchmarked the driver on
    1280x720x30fps video. I found out that with HZ=1000, 10ms is acceptable,
    but with HZ=250 or HZ=300, we need 4ms, so that the video is played
    without any frame skips.

    This patch changes the delay to this value.

    Signed-off-by: Mikulas Patocka
    Cc: stable@vger.kernel.org
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Mikulas Patocka
     
  • The defio subsystem overwrites the method fb_osp->mmap. That method is
    stored in module's static data - and that means that if we have multiple
    diplaylink adapters, they will over write each other's method.

    In order to avoid interference between multiple adapters, we copy the
    fb_ops structure to a device-local memory.

    Signed-off-by: Mikulas Patocka
    Cc: stable@vger.kernel.org
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Mikulas Patocka
     
  • The udlfb driver reprograms the hardware everytime the user switches the
    console, that makes quite unusable when working on the console.

    This patch makes the driver remember the videomode we are in and avoid
    reprogramming the hardware if we switch to the same videomode.

    We mask the "activate" field and the "FB_VMODE_SMOOTH_XPAN" flag when
    comparing the videomode, because they cause spurious switches when
    switching to and from the Xserver.

    Signed-off-by: Mikulas Patocka
    Cc: stable@vger.kernel.org
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Mikulas Patocka
     
  • I observed that the performance of the udl fb driver degrades over time.
    On a freshly booted machine, it takes 6 seconds to do "ls -la /usr/bin";
    after some time of use, the same operation takes 14 seconds.

    The reason is that the value of "limit_sem" decays over time.

    The udl driver uses a semaphore "limit_set" to specify how many free urbs
    are there on dlfb->urbs.list. If the count is zero, the "down" operation
    will sleep until some urbs are added to the freelist.

    In order to avoid some hypothetical deadlock, the driver will not call
    "up" immediately, but it will offload it to a workqueue. The problem is
    that if we call "schedule_delayed_work" on the same work item multiple
    times, the work item may only be executed once.

    This is happening:
    * some urb completes
    * dlfb_urb_completion adds it to the free list
    * dlfb_urb_completion calls schedule_delayed_work to schedule the function
    dlfb_release_urb_work to increase the semaphore count
    * as the urb is on the free list, some other task grabs it and submits it
    * the submitted urb completes, dlfb_urb_completion is called again
    * dlfb_urb_completion calls schedule_delayed_work, but the work is already
    scheduled, so it does nothing
    * finally, dlfb_release_urb_work is called, it increases the semaphore
    count by 1, although it should increase it by 2

    So, the semaphore count is decreasing over time, and this causes gradual
    performance degradation.

    Note that in the current kernel, the "up" function may be called from
    interrupt and it may race with the "down" function called by another
    thread, so we don't have to offload the call of "up" to a workqueue at
    all. This patch removes the workqueue code. The patch also changes
    "down_interruptible" to "down" in dlfb_free_urb_list, so that we will
    clean up the driver properly even if a signal arrives.

    With this patch, the performance of udlfb no longer degrades.

    Signed-off-by: Mikulas Patocka
    Cc: stable@vger.kernel.org
    [b.zolnierkie: fix immediatelly -> immediately typo]
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Mikulas Patocka