mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-26 00:05:35 +07:00
9ec9a87b1e
Will be needed in the future. No functional changes. Cc: Madhav Chauhan <madhav.chauhan@intel.com> Cc: Ville Syrjala <ville.syrjala@linux.intel.com> Reviewed-by: Madhav Chauhan <madhav.chauhan@intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/2cb427e5bc2ea88e4226bfcf162b3a6f307e32e1.1539613303.git.jani.nikula@intel.com
31 lines
533 B
C
31 lines
533 B
C
// SPDX-License-Identifier: MIT
|
|
/*
|
|
* Copyright © 2018 Intel Corporation
|
|
*/
|
|
|
|
#include <drm/drm_mipi_dsi.h>
|
|
#include "intel_dsi.h"
|
|
|
|
int intel_dsi_bitrate(const struct intel_dsi *intel_dsi)
|
|
{
|
|
int bpp = mipi_dsi_pixel_format_to_bpp(intel_dsi->pixel_format);
|
|
|
|
if (WARN_ON(bpp < 0))
|
|
bpp = 16;
|
|
|
|
return intel_dsi->pclk * bpp / intel_dsi->lane_count;
|
|
}
|
|
|
|
int intel_dsi_tlpx_ns(const struct intel_dsi *intel_dsi)
|
|
{
|
|
switch (intel_dsi->escape_clk_div) {
|
|
default:
|
|
case 0:
|
|
return 50;
|
|
case 1:
|
|
return 100;
|
|
case 2:
|
|
return 200;
|
|
}
|
|
}
|