summaryrefslogtreecommitdiff
path: root/include/linux/stacktrace.h
diff options
context:
space:
mode:
authorYaniv Gardi <ygardi@codeaurora.org>2014-08-20 00:12:01 +0300
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-22 10:57:14 -0700
commite740ae3bbe0d1921f8d4d5b203d6ab2978ab497d (patch)
treebbf84014dc51761f1e92b904d384edeebc3d665d /include/linux/stacktrace.h
parent155737fa4ee230b7cdd9b1631fbed28a977a1625 (diff)
scsi: ufs: null terminate buffer that is sent to strlcpy
strlcpy() must get null-terminated buffer as a second argument because inside strlcpy(), strlen() is invoked on that argument, and unterminated buffer will result incorrect value. In this case, str_desc_buf is a buffer that might return from ufshcd_read_string_desc() when it is no longer null-terminated. Therefor we must null-terminate it before sending it to strlcpy(). This change also fixes the type of the vendor variable that is read from the device descriptor. According to UFS device specification this field is 2 bytes wide. Its name is also changed to be compatible with UFS device specification. Change-Id: I3b1ba0311846881a1f3f1c984cc6f9d7109821b3 Signed-off-by: Yaniv Gardi <ygardi@codeaurora.org>
Diffstat (limited to 'include/linux/stacktrace.h')
0 files changed, 0 insertions, 0 deletions