diff options
author | Tony Lindgren <tony@atomide.com> | 2012-11-09 14:58:01 -0800 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2012-11-09 14:58:01 -0800 |
commit | edf8dde393f879fc2d8c22d4bc01ff8d37b80e1a (patch) | |
tree | 61425adc8b2059a9c12a3ce66ba7361fea1b0bb3 /drivers/usb/musb | |
parent | 6ba54ab4a49bbad736b0254aa6bdf0cb83013815 (diff) | |
parent | 3d70f8c617a436c7146ecb81df2265b4626dfe89 (diff) | |
download | linux-3.10-edf8dde393f879fc2d8c22d4bc01ff8d37b80e1a.tar.gz linux-3.10-edf8dde393f879fc2d8c22d4bc01ff8d37b80e1a.tar.bz2 linux-3.10-edf8dde393f879fc2d8c22d4bc01ff8d37b80e1a.zip |
Merge branch 'linus' into omap-for-v3.8/cleanup-headers-prepare-multiplatform-v3
Diffstat (limited to 'drivers/usb/musb')
-rw-r--r-- | drivers/usb/musb/musb_dsps.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/usb/musb/musb_dsps.c b/drivers/usb/musb/musb_dsps.c index a67af21c146..aa34f22181c 100644 --- a/drivers/usb/musb/musb_dsps.c +++ b/drivers/usb/musb/musb_dsps.c @@ -457,11 +457,11 @@ static int __devinit dsps_create_musb_pdev(struct dsps_glue *glue, u8 id) struct platform_device *musb; struct resource *res; struct resource resources[2]; - char res_name[10]; + char res_name[11]; int ret, musbid; /* get memory resource */ - sprintf(res_name, "musb%d", id); + snprintf(res_name, sizeof(res_name), "musb%d", id); res = platform_get_resource_byname(pdev, IORESOURCE_MEM, res_name); if (!res) { dev_err(dev, "%s get mem resource failed\n", res_name); @@ -472,7 +472,7 @@ static int __devinit dsps_create_musb_pdev(struct dsps_glue *glue, u8 id) resources[0] = *res; /* get irq resource */ - sprintf(res_name, "musb%d-irq", id); + snprintf(res_name, sizeof(res_name), "musb%d-irq", id); res = platform_get_resource_byname(pdev, IORESOURCE_IRQ, res_name); if (!res) { dev_err(dev, "%s get irq resource failed\n", res_name); @@ -529,7 +529,7 @@ static int __devinit dsps_create_musb_pdev(struct dsps_glue *glue, u8 id) of_property_read_u32(np, "num-eps", (u32 *)&config->num_eps); of_property_read_u32(np, "ram-bits", (u32 *)&config->ram_bits); - sprintf(res_name, "port%d-mode", id); + snprintf(res_name, sizeof(res_name), "port%d-mode", id); of_property_read_u32(np, res_name, (u32 *)&pdata->mode); of_property_read_u32(np, "power", (u32 *)&pdata->power); config->multipoint = of_property_read_bool(np, "multipoint"); |