From 6da549ec851117293a07e64f97170f7dc9d55578 Mon Sep 17 00:00:00 2001 From: Vaibhav Agarwal Date: Tue, 29 Mar 2016 16:32:35 +0530 Subject: [PATCH] greybus: audio: Fix widget pointer update during control parsing widget pointer was incorrectly modfied while parsing kcontrol Signed-off-by: Vaibhav Agarwal Reviewed-by: Mark Greer Signed-off-by: Greg Kroah-Hartman --- drivers/staging/greybus/audio_topology.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/greybus/audio_topology.c b/drivers/staging/greybus/audio_topology.c index 4901348a2ada..9e36fb27faf8 100644 --- a/drivers/staging/greybus/audio_topology.c +++ b/drivers/staging/greybus/audio_topology.c @@ -834,7 +834,7 @@ static int gbaudio_tplg_process_widgets(struct gbaudio_module_info *module, list_add(&widget->list, &module->widget_list); ncontrols = curr->ncontrols; curr++; - curr += ncontrols * sizeof(struct gb_audio_control); + curr = (void *)curr + ncontrols*sizeof(struct gb_audio_control); } module->dapm_widgets = dapm_widgets; -- 2.20.1