Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

usb: musb: remove redundant stack buffers

aDate is always the empty string, so entirely pointless. The aRevision
formatting might as well be done as part of the pr_debug() call - that
also avoids it altogether if pr_debug is compiled out.

Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Signed-off-by: Bin Liu <b-liu@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Rasmus Villemoes and committed by
Greg Kroah-Hartman
21b031fb 48fed03b

+5 -7
+5 -7
drivers/usb/musb/musb_core.c
··· 1448 1448 { 1449 1449 u8 reg; 1450 1450 char *type; 1451 - char aInfo[90], aRevision[32], aDate[12]; 1451 + char aInfo[90]; 1452 1452 void __iomem *mbase = musb->mregs; 1453 1453 int status = 0; 1454 1454 int i; ··· 1482 1482 1483 1483 pr_debug("%s: ConfigData=0x%02x (%s)\n", musb_driver_name, reg, aInfo); 1484 1484 1485 - aDate[0] = 0; 1486 1485 if (MUSB_CONTROLLER_MHDRC == musb_type) { 1487 1486 musb->is_multipoint = 1; 1488 1487 type = "M"; ··· 1496 1497 1497 1498 /* log release info */ 1498 1499 musb->hwvers = musb_read_hwvers(mbase); 1499 - snprintf(aRevision, 32, "%d.%d%s", MUSB_HWVERS_MAJOR(musb->hwvers), 1500 - MUSB_HWVERS_MINOR(musb->hwvers), 1501 - (musb->hwvers & MUSB_HWVERS_RC) ? "RC" : ""); 1502 - pr_debug("%s: %sHDRC RTL version %s %s\n", 1503 - musb_driver_name, type, aRevision, aDate); 1500 + pr_debug("%s: %sHDRC RTL version %d.%d%s\n", 1501 + musb_driver_name, type, MUSB_HWVERS_MAJOR(musb->hwvers), 1502 + MUSB_HWVERS_MINOR(musb->hwvers), 1503 + (musb->hwvers & MUSB_HWVERS_RC) ? "RC" : ""); 1504 1504 1505 1505 /* configure ep0 */ 1506 1506 musb_configure_ep0(musb);