[alsa-devel] [asoc:fix/rt5645 1/1] sound/soc/codecs/rt5645.c:2947:3: warning: 'return' with no value, in function returning non-void
tree: git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git fix/rt5645 head: 3c2234569cfff83718792f810a9bb855b78c2473 commit: 3c2234569cfff83718792f810a9bb855b78c2473 [1/1] ASoC: rt5645: Check if codec is initialized in workqueue handler config: i386-randconfig-x009-201528 (attached as .config) reproduce: git checkout 3c2234569cfff83718792f810a9bb855b78c2473 # save the attached .config to linux build tree make ARCH=i386
All warnings (new ones prefixed by >>):
sound/soc/codecs/rt5645.c: In function 'rt5645_irq_detection':
sound/soc/codecs/rt5645.c:2947:3: warning: 'return' with no value, in function returning non-void [-Wreturn-type]
return; ^
vim +/return +2947 sound/soc/codecs/rt5645.c
2931 { 2932 int btn_type, val; 2933 2934 val = snd_soc_read(codec, RT5650_4BTN_IL_CMD1); 2935 pr_debug("val=0x%x\n", val); 2936 btn_type = val & 0xfff0; 2937 snd_soc_write(codec, RT5650_4BTN_IL_CMD1, val); 2938 2939 return btn_type; 2940 } 2941 2942 static int rt5645_irq_detection(struct rt5645_priv *rt5645) 2943 { 2944 int val, btn_type, gpio_state = 0, report = 0; 2945 2946 if (!rt5645->codec)
2947 return;
2948 2949 switch (rt5645->pdata.jd_mode) { 2950 case 0: /* Not using rt5645 JD */ 2951 if (rt5645->gpiod_hp_det) { 2952 gpio_state = gpiod_get_value(rt5645->gpiod_hp_det); 2953 dev_dbg(rt5645->codec->dev, "gpio_state = %d\n", 2954 gpio_state); 2955 report = rt5645_jack_detect(rt5645->codec, gpio_state);
--- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation
Hi Mark,
On Thu, Jul 16, 2015 at 8:32 PM, kbuild test robot fengguang.wu@intel.com wrote:
tree: git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git fix/rt5645 head: 3c2234569cfff83718792f810a9bb855b78c2473 commit: 3c2234569cfff83718792f810a9bb855b78c2473 [1/1] ASoC: rt5645: Check if codec is initialized in workqueue handler config: i386-randconfig-x009-201528 (attached as .config) reproduce: git checkout 3c2234569cfff83718792f810a9bb855b78c2473 # save the attached .config to linux build tree make ARCH=i386
All warnings (new ones prefixed by >>):
sound/soc/codecs/rt5645.c: In function 'rt5645_irq_detection':
sound/soc/codecs/rt5645.c:2947:3: warning: 'return' with no value, in function returning non-void [-Wreturn-type]
return; ^
Are you sending this patch to stable@?
This happens because I rebased the patch on f312bc59 "ASoC: rt5645: Remove irq_jack_detection function" (which was your for-next at the time), so it probably shouldn't be applied in its own branch...
The return value is ignored anyway, so the code should work as intended, but a "return 0;", or -EINVAL, would be more proper...
Thanks,
On Thu, Jul 16, 2015 at 09:03:29PM +0800, Nicolas Boichat wrote:
On Thu, Jul 16, 2015 at 8:32 PM, kbuild test robot
sound/soc/codecs/rt5645.c: In function 'rt5645_irq_detection':
sound/soc/codecs/rt5645.c:2947:3: warning: 'return' with no value, in function returning non-void [-Wreturn-type]
return; ^
Are you sending this patch to stable@?
My git tree is public... I'd not Cced it to stable but it looks like it's supposed to be a bug fix so I applied it as a bug fix.
This happens because I rebased the patch on f312bc59 "ASoC: rt5645: Remove irq_jack_detection function" (which was your for-next at the time), so it probably shouldn't be applied in its own branch...
The return value is ignored anyway, so the code should work as intended, but a "return 0;", or -EINVAL, would be more proper...
Please send a fixed version unless the issue doesn't exist in Linus' tree.
participants (3)
-
kbuild test robot
-
Mark Brown
-
Nicolas Boichat