From: Daniel Mack Date: Wed, 17 Oct 2012 20:17:35 +0000 (+0200) Subject: usb: musb: dsps: fix res_name length X-Git-Tag: v3.7-rc3~11^2~38^2~3 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ca749b2a2e72b39b3a46d1e4d096e338bf714a3c;p=pandora-kernel.git usb: musb: dsps: fix res_name length The res_name is used for the name construction of a DT property as follows: sprintf(res_name, "port%d-mode", id); Hence, res_name must be at least 11 characters long in order to store the name including the terminating '\0'. While at it, use to snprintf() rather than sprintf() when accessing this buffer. Reported-by: David Binderman Signed-off-by: Daniel Mack Signed-off-by: Felipe Balbi --- Reading git-diff-tree failed