提交 3556dd40 编写于 作者: J Jani Nikula

drm/i915/bios: fix format string of the VBT signature logging

Specify the maximum number of letters to print from the potentially
unterminated buffer, not the minimum. While at it, use sizeof instead of
a magic number.
Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: NJani Nikula <jani.nikula@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1450271061-32646-2-git-send-email-jani.nikula@intel.com
上级 e23ceb83
...@@ -1326,8 +1326,8 @@ intel_bios_init(struct drm_device *dev) ...@@ -1326,8 +1326,8 @@ intel_bios_init(struct drm_device *dev)
bdb = get_bdb_header(vbt); bdb = get_bdb_header(vbt);
DRM_DEBUG_KMS("VBT signature \"%20s\", BDB version %d\n", DRM_DEBUG_KMS("VBT signature \"%.*s\", BDB version %d\n",
vbt->signature, bdb->version); (int)sizeof(vbt->signature), vbt->signature, bdb->version);
/* Grab useful general definitions */ /* Grab useful general definitions */
parse_general_features(dev_priv, bdb); parse_general_features(dev_priv, bdb);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册