From: kernel test robot <lkp@intel.com>
To: Zhang Yi <zhangyi@everest-semi.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: Re: [PATCH] ASoC: codecs: ES8326: Reduce pop noise
Date: Mon, 30 Dec 2024 00:41:21 +0800 [thread overview]
Message-ID: <202412300023.AZpA3xBC-lkp@intel.com> (raw)
In-Reply-To: <20241220104322.31867-1-zhangyi@everest-semi.com>
Hi Zhang,
kernel test robot noticed the following build warnings:
[auto build test WARNING on broonie-sound/for-next]
[also build test WARNING on tiwai-sound/for-next tiwai-sound/for-linus linus/master v6.13-rc4 next-20241220]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Zhang-Yi/ASoC-codecs-ES8326-Reduce-pop-noise/20241229-205825
base: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
patch link: https://lore.kernel.org/r/20241220104322.31867-1-zhangyi%40everest-semi.com
patch subject: [PATCH] ASoC: codecs: ES8326: Reduce pop noise
config: arm64-randconfig-002-20241229 (https://download.01.org/0day-ci/archive/20241230/202412300023.AZpA3xBC-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241230/202412300023.AZpA3xBC-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202412300023.AZpA3xBC-lkp@intel.com/
All warnings (new ones prefixed by >>):
sound/soc/codecs/es8326.c: In function 'es8326_jack_button_handler':
>> sound/soc/codecs/es8326.c:786:20: warning: this statement may fall through [-Wimplicit-fallthrough=]
786 | if (es8326->version > ES8326_VERSION_B) {
| ^
sound/soc/codecs/es8326.c:790:9: note: here
790 | case 0x4b:
| ^~~~
vim +786 sound/soc/codecs/es8326.c
759
760 /*
761 * For button detection, set the following in soundcard
762 * snd_jack_set_key(jack->jack, SND_JACK_BTN_0, KEY_PLAYPAUSE);
763 * snd_jack_set_key(jack->jack, SND_JACK_BTN_1, KEY_VOLUMEUP);
764 * snd_jack_set_key(jack->jack, SND_JACK_BTN_2, KEY_VOLUMEDOWN);
765 */
766 static void es8326_jack_button_handler(struct work_struct *work)
767 {
768 struct es8326_priv *es8326 =
769 container_of(work, struct es8326_priv, button_press_work.work);
770 struct snd_soc_component *comp = es8326->component;
771 unsigned int iface;
772 static int button_to_report, press_count;
773 static int prev_button, cur_button;
774
775 if (!(es8326->jack->status & SND_JACK_HEADSET)) /* Jack unplugged */
776 return;
777
778 mutex_lock(&es8326->lock);
779 iface = snd_soc_component_read(comp, ES8326_HPDET_STA);
780 switch (iface) {
781 case 0x93:
782 /* pause button detected */
783 cur_button = SND_JACK_BTN_0;
784 break;
785 case 0x6f:
> 786 if (es8326->version > ES8326_VERSION_B) {
787 cur_button = SND_JACK_BTN_0;
788 break;
789 }
790 case 0x4b:
791 /* button volume up */
792 cur_button = SND_JACK_BTN_1;
793 break;
794 case 0x27:
795 /* button volume down */
796 cur_button = SND_JACK_BTN_2;
797 break;
798 case 0x1e:
799 case 0xe2:
800 /* button released or not pressed */
801 cur_button = 0;
802 break;
803 default:
804 break;
805 }
806
807 if ((prev_button == cur_button) && (cur_button != 0)) {
808 press_count++;
809 if (press_count > 3) {
810 /* report a press every 120ms */
811 snd_soc_jack_report(es8326->jack, cur_button,
812 SND_JACK_BTN_0 | SND_JACK_BTN_1 | SND_JACK_BTN_2);
813 press_count = 0;
814 }
815 button_to_report = cur_button;
816 queue_delayed_work(system_wq, &es8326->button_press_work,
817 msecs_to_jiffies(35));
818 } else if (prev_button != cur_button) {
819 /* mismatch, detect again */
820 prev_button = cur_button;
821 queue_delayed_work(system_wq, &es8326->button_press_work,
822 msecs_to_jiffies(35));
823 } else {
824 /* released or no pressed */
825 if (button_to_report != 0) {
826 snd_soc_jack_report(es8326->jack, button_to_report,
827 SND_JACK_BTN_0 | SND_JACK_BTN_1 | SND_JACK_BTN_2);
828 snd_soc_jack_report(es8326->jack, 0,
829 SND_JACK_BTN_0 | SND_JACK_BTN_1 | SND_JACK_BTN_2);
830 button_to_report = 0;
831 }
832 es8326_disable_micbias(es8326->component);
833 }
834 mutex_unlock(&es8326->lock);
835 }
836
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next prev parent reply other threads:[~2024-12-29 16:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-20 10:43 [PATCH] ASoC: codecs: ES8326: Reduce pop noise Zhang Yi
2024-12-29 16:09 ` kernel test robot
2024-12-29 16:41 ` kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-10-31 6:02 Zhang Yi
2024-11-05 16:38 ` Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202412300023.AZpA3xBC-lkp@intel.com \
--to=lkp@intel.com \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=zhangyi@everest-semi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.