Skip to content

Commit

Permalink
ASoC: Intel: avoid format string leak to thread name
Browse files Browse the repository at this point in the history
This makes sure a format string can never get processed into the worker
thread name from the device name.

Signed-off-by: Kees Cook <keescook@chromium.org>
Acked-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
  • Loading branch information
Kees Cook authored and Mark Brown committed May 26, 2014
1 parent 2fa190c commit 3538632
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion sound/soc/intel/sst-baytrail-ipc.c
Original file line number Diff line number Diff line change
Expand Up @@ -892,7 +892,7 @@ int sst_byt_dsp_init(struct device *dev, struct sst_pdata *pdata)
/* start the IPC message thread */
init_kthread_worker(&byt->kworker);
byt->tx_thread = kthread_run(kthread_worker_fn,
&byt->kworker,
&byt->kworker, "%s",
dev_name(byt->dev));
if (IS_ERR(byt->tx_thread)) {
err = PTR_ERR(byt->tx_thread);
Expand Down
2 changes: 1 addition & 1 deletion sound/soc/intel/sst-haswell-ipc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1735,7 +1735,7 @@ int sst_hsw_dsp_init(struct device *dev, struct sst_pdata *pdata)
/* start the IPC message thread */
init_kthread_worker(&hsw->kworker);
hsw->tx_thread = kthread_run(kthread_worker_fn,
&hsw->kworker,
&hsw->kworker, "%s",
dev_name(hsw->dev));
if (IS_ERR(hsw->tx_thread)) {
ret = PTR_ERR(hsw->tx_thread);
Expand Down

0 comments on commit 3538632

Please sign in to comment.