|
60 | 60 | #include <linux/io.h>
|
61 | 61 | #include <linux/dma-mapping.h>
|
62 | 62 | #include <linux/gfp.h>
|
| 63 | +#include <linux/string.h> |
63 | 64 |
|
64 | 65 | #include <sound/core.h>
|
65 | 66 | #include <sound/pcm.h>
|
@@ -2239,7 +2240,7 @@ static int snd_dbri_pcm(struct snd_card *card)
|
2239 | 2240 |
|
2240 | 2241 | pcm->private_data = card->private_data;
|
2241 | 2242 | pcm->info_flags = 0;
|
2242 |
| - strcpy(pcm->name, card->shortname); |
| 2243 | + strscpy(pcm->name, card->shortname); |
2243 | 2244 |
|
2244 | 2245 | snd_pcm_set_managed_buffer_all(pcm, SNDRV_DMA_TYPE_CONTINUOUS,
|
2245 | 2246 | NULL, 64 * 1024, 64 * 1024);
|
@@ -2446,7 +2447,7 @@ static int snd_dbri_mixer(struct snd_card *card)
|
2446 | 2447 | return -EINVAL;
|
2447 | 2448 | dbri = card->private_data;
|
2448 | 2449 |
|
2449 |
| - strcpy(card->mixername, card->shortname); |
| 2450 | + strscpy(card->mixername, card->shortname); |
2450 | 2451 |
|
2451 | 2452 | for (idx = 0; idx < ARRAY_SIZE(dbri_controls); idx++) {
|
2452 | 2453 | err = snd_ctl_add(card,
|
@@ -2613,8 +2614,8 @@ static int dbri_probe(struct platform_device *op)
|
2613 | 2614 | if (err < 0)
|
2614 | 2615 | return err;
|
2615 | 2616 |
|
2616 |
| - strcpy(card->driver, "DBRI"); |
2617 |
| - strcpy(card->shortname, "Sun DBRI"); |
| 2617 | + strscpy(card->driver, "DBRI"); |
| 2618 | + strscpy(card->shortname, "Sun DBRI"); |
2618 | 2619 | rp = &op->resource[0];
|
2619 | 2620 | sprintf(card->longname, "%s at 0x%02lx:0x%016llx, irq %d",
|
2620 | 2621 | card->shortname,
|
|
0 commit comments