diff options
author | Imre Deak <imre.deak@intel.com> | 2016-01-29 15:52:29 +0300 |
---|---|---|
committer | Imre Deak <imre.deak@intel.com> | 2016-02-02 19:28:32 +0300 |
commit | 05d25214c4d1cab99d1056f99b7e7d95e9e31ed0 (patch) | |
tree | d67ecd1912470806b9eaab6119493d41fe330dda /drivers/gpu/drm/i915/intel_tv.c | |
parent | b074eae12f1e9f8eb1aafa3d7b922427f9b8e68a (diff) | |
download | linux-05d25214c4d1cab99d1056f99b7e7d95e9e31ed0.tar.xz |
drm/i915: Properly terminate KMS mode name string during tv init
Signed-off-by: Imre Deak <imre.deak@intel.com>
Reviewed-by: David Weinehall <david.weinehall@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1454071949-24677-4-git-send-email-imre.deak@intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/intel_tv.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_tv.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/intel_tv.c b/drivers/gpu/drm/i915/intel_tv.c index 948cbff6c62e..5034b0055169 100644 --- a/drivers/gpu/drm/i915/intel_tv.c +++ b/drivers/gpu/drm/i915/intel_tv.c @@ -1420,6 +1420,7 @@ intel_tv_get_modes(struct drm_connector *connector) if (!mode_ptr) continue; strncpy(mode_ptr->name, input->name, DRM_DISPLAY_MODE_LEN); + mode_ptr->name[DRM_DISPLAY_MODE_LEN - 1] = '\0'; mode_ptr->hdisplay = hactive_s; mode_ptr->hsync_start = hactive_s + 1; |