LCOV - code coverage report
Current view: top level - drivers/video - videomode.c (source / functions) Hit Total Coverage
Test: gcov_data_raspi2_real_modules_combined.info Lines: 0 15 0.0 %
Date: 2020-09-30 20:25:40 Functions: 0 2 0.0 %
Branches: 0 2 0.0 %

           Branch data     Line data    Source code
       1                 :            : // SPDX-License-Identifier: GPL-2.0-only
       2                 :            : /*
       3                 :            :  * generic display timing functions
       4                 :            :  *
       5                 :            :  * Copyright (c) 2012 Steffen Trumtrar <s.trumtrar@pengutronix.de>, Pengutronix
       6                 :            :  */
       7                 :            : 
       8                 :            : #include <linux/errno.h>
       9                 :            : #include <linux/export.h>
      10                 :            : #include <video/display_timing.h>
      11                 :            : #include <video/videomode.h>
      12                 :            : 
      13                 :          0 : void videomode_from_timing(const struct display_timing *dt,
      14                 :            :                           struct videomode *vm)
      15                 :            : {
      16                 :          0 :         vm->pixelclock = dt->pixelclock.typ;
      17                 :          0 :         vm->hactive = dt->hactive.typ;
      18                 :          0 :         vm->hfront_porch = dt->hfront_porch.typ;
      19                 :          0 :         vm->hback_porch = dt->hback_porch.typ;
      20                 :          0 :         vm->hsync_len = dt->hsync_len.typ;
      21                 :            : 
      22                 :          0 :         vm->vactive = dt->vactive.typ;
      23                 :          0 :         vm->vfront_porch = dt->vfront_porch.typ;
      24                 :          0 :         vm->vback_porch = dt->vback_porch.typ;
      25                 :          0 :         vm->vsync_len = dt->vsync_len.typ;
      26                 :            : 
      27                 :          0 :         vm->flags = dt->flags;
      28                 :          0 : }
      29                 :            : EXPORT_SYMBOL_GPL(videomode_from_timing);
      30                 :            : 
      31                 :          0 : int videomode_from_timings(const struct display_timings *disp,
      32                 :            :                           struct videomode *vm, unsigned int index)
      33                 :            : {
      34                 :            :         struct display_timing *dt;
      35                 :            : 
      36                 :            :         dt = display_timings_get(disp, index);
      37         [ #  # ]:          0 :         if (!dt)
      38                 :            :                 return -EINVAL;
      39                 :            : 
      40                 :            :         videomode_from_timing(dt, vm);
      41                 :            : 
      42                 :          0 :         return 0;
      43                 :            : }
      44                 :            : EXPORT_SYMBOL_GPL(videomode_from_timings);

Generated by: LCOV version 1.14