* [broonie-ci:asoc-7.3 56/63] sound/soc/codecs/es8389.c:109 find_best_hpf_freq() warn: unsigned 'target_hz' is never less than zero.
@ 2026-07-02 3:56 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-07-02 3:56 UTC (permalink / raw)
To: Zhang Yi; +Cc: oe-kbuild-all, Mark Brown
tree: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/ci.git asoc-7.3
head: fb5d1b1c5f8a920ee697545fa6dee16825085717
commit: 87592da1a490abd2adeb57a49fb200d058403cc5 [56/63] ASoC: codecs: ES8389: Add private members about HPF
config: m68k-randconfig-r072-20260702 (https://download.01.org/0day-ci/archive/20260702/202607021153.zU3zkE2I-lkp@intel.com/config)
compiler: m68k-linux-gcc (GCC) 14.3.0
smatch: v0.5.0-9185-gbcc58b9c
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/202607021153.zU3zkE2I-lkp@intel.com/
smatch warnings:
sound/soc/codecs/es8389.c:109 find_best_hpf_freq() warn: unsigned 'target_hz' is never less than zero.
vim +/target_hz +109 sound/soc/codecs/es8389.c
101
102 static bool find_best_hpf_freq(u32 target_hz, u8 *hpf1, u8 *hpf2, u32 *out)
103 {
104 int best_row = -1, best_col = -1;
105 u32 min_diff = U32_MAX;
106 u32 f, diff;
107 int i, j;
108
> 109 if ((target_hz > 1020) | (target_hz < 0))
110 return false;
111
112 for (i = 0; i < 10; i++) {
113 for (j = i; j < 10; j++) {
114 f = hpf_table[i][j];
115
116 diff = (target_hz > f) ? (target_hz - f) : (f - target_hz);
117 if (diff < min_diff) {
118 min_diff = diff;
119 best_row = i;
120 best_col = j;
121 *out = f;
122 }
123 }
124 }
125
126 *hpf1 = best_col + ES8389_HPF_OFFSET;
127 *hpf2 = best_row + ES8389_HPF_OFFSET;
128
129 return true;
130 }
131
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-07-02 3:57 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-02 3:56 [broonie-ci:asoc-7.3 56/63] sound/soc/codecs/es8389.c:109 find_best_hpf_freq() warn: unsigned 'target_hz' is never less than zero kernel test robot
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.