From: kernel test robot <lkp@intel.com>
To: Mauro Carvalho Chehab <mchehab@kernel.org>,
Linux Doc Mailing List <linux-doc@vger.kernel.org>
Cc: kbuild-all@lists.01.org, clang-built-linux@googlegroups.com,
linux-media@vger.kernel.org,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Jonathan Corbet <corbet@lwn.net>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 56/56] scrpits: kernel-doc: validate kernel-doc markup with the actual names
Date: Sat, 24 Oct 2020 04:02:13 +0800 [thread overview]
Message-ID: <202010240356.04GQOaBt-lkp@intel.com> (raw)
In-Reply-To: <a21343a7012c87391c4850bf3151ebd82add8d1c.1603469755.git.mchehab+huawei@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 10394 bytes --]
Hi Mauro,
I love your patch! Perhaps something to improve:
[auto build test WARNING on next-20201023]
[cannot apply to linuxtv-media/master sound/for-next pci/next mkp-scsi/for-next scsi/for-next linus/master v5.9 v5.9-rc8 v5.9-rc7 v5.9]
[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]
url: https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Fix-several-bad-kernel-doc-markups/20201024-004025
base: 9695c4ff26459ff5bfe25c7d6179e4c9c00e1363
config: riscv-randconfig-r002-20201024 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 147b9497e79a98a8614b2b5eb4ba653b44f6b6f0)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install riscv cross compiling tool for clang build
# apt-get install binutils-riscv64-linux-gnu
# https://github.com/0day-ci/linux/commit/002bbfc5a97ce37daf3c570e0edd28fa0c7de5b8
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Mauro-Carvalho-Chehab/Fix-several-bad-kernel-doc-markups/20201024-004025
git checkout 002bbfc5a97ce37daf3c570e0edd28fa0c7de5b8
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=riscv
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> drivers/clk/analogbits/wrpll-cln28hpc.c:223: warning: expecting prototype for wrpll_configure(). Prototype was for wrpll_configure_for_rate() instead
vim +223 drivers/clk/analogbits/wrpll-cln28hpc.c
7b9487a9a5c41ce Paul Walmsley 2019-04-30 199
7b9487a9a5c41ce Paul Walmsley 2019-04-30 200 /**
7b9487a9a5c41ce Paul Walmsley 2019-04-30 201 * wrpll_configure() - compute PLL configuration for a target rate
7b9487a9a5c41ce Paul Walmsley 2019-04-30 202 * @c: ptr to a struct wrpll_cfg record to write into
7b9487a9a5c41ce Paul Walmsley 2019-04-30 203 * @target_rate: target PLL output clock rate (post-Q-divider)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 204 * @parent_rate: PLL input refclk rate (pre-R-divider)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 205 *
7b9487a9a5c41ce Paul Walmsley 2019-04-30 206 * Compute the appropriate PLL signal configuration values and store
7b9487a9a5c41ce Paul Walmsley 2019-04-30 207 * in PLL context @c. PLL reprogramming is not glitchless, so the
7b9487a9a5c41ce Paul Walmsley 2019-04-30 208 * caller should switch any downstream logic to a different clock
7b9487a9a5c41ce Paul Walmsley 2019-04-30 209 * source or clock-gate it before presenting these values to the PLL
7b9487a9a5c41ce Paul Walmsley 2019-04-30 210 * configuration signals.
7b9487a9a5c41ce Paul Walmsley 2019-04-30 211 *
7b9487a9a5c41ce Paul Walmsley 2019-04-30 212 * The caller must pass this function a pre-initialized struct
7b9487a9a5c41ce Paul Walmsley 2019-04-30 213 * wrpll_cfg record: either initialized to zero (with the
7b9487a9a5c41ce Paul Walmsley 2019-04-30 214 * exception of the .name and .flags fields) or read from the PLL.
7b9487a9a5c41ce Paul Walmsley 2019-04-30 215 *
7b9487a9a5c41ce Paul Walmsley 2019-04-30 216 * Context: Any context. Caller must protect the memory pointed to by @c
7b9487a9a5c41ce Paul Walmsley 2019-04-30 217 * from simultaneous access or modification.
7b9487a9a5c41ce Paul Walmsley 2019-04-30 218 *
7b9487a9a5c41ce Paul Walmsley 2019-04-30 219 * Return: 0 upon success; anything else upon failure.
7b9487a9a5c41ce Paul Walmsley 2019-04-30 220 */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 221 int wrpll_configure_for_rate(struct wrpll_cfg *c, u32 target_rate,
7b9487a9a5c41ce Paul Walmsley 2019-04-30 222 unsigned long parent_rate)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 @223 {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 224 unsigned long ratio;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 225 u64 target_vco_rate, delta, best_delta, f_pre_div, vco, vco_pre;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 226 u32 best_f, f, post_divr_freq;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 227 u8 fbdiv, divq, best_r, r;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 228 int range;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 229
7b9487a9a5c41ce Paul Walmsley 2019-04-30 230 if (c->flags == 0) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 231 WARN(1, "%s called with uninitialized PLL config", __func__);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 232 return -EINVAL;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 233 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 234
7b9487a9a5c41ce Paul Walmsley 2019-04-30 235 /* Initialize rounding data if it hasn't been initialized already */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 236 if (parent_rate != c->parent_rate) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 237 if (__wrpll_update_parent_rate(c, parent_rate)) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 238 pr_err("%s: PLL input rate is out of range\n",
7b9487a9a5c41ce Paul Walmsley 2019-04-30 239 __func__);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 240 return -ERANGE;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 241 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 242 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 243
7b9487a9a5c41ce Paul Walmsley 2019-04-30 244 c->flags &= ~WRPLL_FLAGS_RESET_MASK;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 245
7b9487a9a5c41ce Paul Walmsley 2019-04-30 246 /* Put the PLL into bypass if the user requests the parent clock rate */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 247 if (target_rate == parent_rate) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 248 c->flags |= WRPLL_FLAGS_BYPASS_MASK;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 249 return 0;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 250 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 251
7b9487a9a5c41ce Paul Walmsley 2019-04-30 252 c->flags &= ~WRPLL_FLAGS_BYPASS_MASK;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 253
7b9487a9a5c41ce Paul Walmsley 2019-04-30 254 /* Calculate the Q shift and target VCO rate */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 255 divq = __wrpll_calc_divq(target_rate, &target_vco_rate);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 256 if (!divq)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 257 return -1;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 258 c->divq = divq;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 259
7b9487a9a5c41ce Paul Walmsley 2019-04-30 260 /* Precalculate the pre-Q divider target ratio */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 261 ratio = div64_u64((target_vco_rate << ROUND_SHIFT), parent_rate);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 262
7b9487a9a5c41ce Paul Walmsley 2019-04-30 263 fbdiv = __wrpll_calc_fbdiv(c);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 264 best_r = 0;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 265 best_f = 0;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 266 best_delta = MAX_VCO_FREQ;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 267
7b9487a9a5c41ce Paul Walmsley 2019-04-30 268 /*
7b9487a9a5c41ce Paul Walmsley 2019-04-30 269 * Consider all values for R which land within
7b9487a9a5c41ce Paul Walmsley 2019-04-30 270 * [MIN_POST_DIVR_FREQ, MAX_POST_DIVR_FREQ]; prefer smaller R
7b9487a9a5c41ce Paul Walmsley 2019-04-30 271 */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 272 for (r = c->init_r; r <= c->max_r; ++r) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 273 f_pre_div = ratio * r;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 274 f = (f_pre_div + (1 << ROUND_SHIFT)) >> ROUND_SHIFT;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 275 f >>= (fbdiv - 1);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 276
7b9487a9a5c41ce Paul Walmsley 2019-04-30 277 post_divr_freq = div_u64(parent_rate, r);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 278 vco_pre = fbdiv * post_divr_freq;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 279 vco = vco_pre * f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 280
7b9487a9a5c41ce Paul Walmsley 2019-04-30 281 /* Ensure rounding didn't take us out of range */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 282 if (vco > target_vco_rate) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 283 --f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 284 vco = vco_pre * f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 285 } else if (vco < MIN_VCO_FREQ) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 286 ++f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 287 vco = vco_pre * f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 288 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 289
7b9487a9a5c41ce Paul Walmsley 2019-04-30 290 delta = abs(target_rate - vco);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 291 if (delta < best_delta) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 292 best_delta = delta;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 293 best_r = r;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 294 best_f = f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 295 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 296 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 297
7b9487a9a5c41ce Paul Walmsley 2019-04-30 298 c->divr = best_r - 1;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 299 c->divf = best_f - 1;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 300
7b9487a9a5c41ce Paul Walmsley 2019-04-30 301 post_divr_freq = div_u64(parent_rate, best_r);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 302
7b9487a9a5c41ce Paul Walmsley 2019-04-30 303 /* Pick the best PLL jitter filter */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 304 range = __wrpll_calc_filter_range(post_divr_freq);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 305 if (range < 0)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 306 return range;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 307 c->range = range;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 308
7b9487a9a5c41ce Paul Walmsley 2019-04-30 309 return 0;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 310 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 311
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 25404 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH v3 56/56] scrpits: kernel-doc: validate kernel-doc markup with the actual names
Date: Sat, 24 Oct 2020 04:02:13 +0800 [thread overview]
Message-ID: <202010240356.04GQOaBt-lkp@intel.com> (raw)
In-Reply-To: <a21343a7012c87391c4850bf3151ebd82add8d1c.1603469755.git.mchehab+huawei@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 10548 bytes --]
Hi Mauro,
I love your patch! Perhaps something to improve:
[auto build test WARNING on next-20201023]
[cannot apply to linuxtv-media/master sound/for-next pci/next mkp-scsi/for-next scsi/for-next linus/master v5.9 v5.9-rc8 v5.9-rc7 v5.9]
[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]
url: https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/Fix-several-bad-kernel-doc-markups/20201024-004025
base: 9695c4ff26459ff5bfe25c7d6179e4c9c00e1363
config: riscv-randconfig-r002-20201024 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 147b9497e79a98a8614b2b5eb4ba653b44f6b6f0)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install riscv cross compiling tool for clang build
# apt-get install binutils-riscv64-linux-gnu
# https://github.com/0day-ci/linux/commit/002bbfc5a97ce37daf3c570e0edd28fa0c7de5b8
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Mauro-Carvalho-Chehab/Fix-several-bad-kernel-doc-markups/20201024-004025
git checkout 002bbfc5a97ce37daf3c570e0edd28fa0c7de5b8
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=riscv
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> drivers/clk/analogbits/wrpll-cln28hpc.c:223: warning: expecting prototype for wrpll_configure(). Prototype was for wrpll_configure_for_rate() instead
vim +223 drivers/clk/analogbits/wrpll-cln28hpc.c
7b9487a9a5c41ce Paul Walmsley 2019-04-30 199
7b9487a9a5c41ce Paul Walmsley 2019-04-30 200 /**
7b9487a9a5c41ce Paul Walmsley 2019-04-30 201 * wrpll_configure() - compute PLL configuration for a target rate
7b9487a9a5c41ce Paul Walmsley 2019-04-30 202 * @c: ptr to a struct wrpll_cfg record to write into
7b9487a9a5c41ce Paul Walmsley 2019-04-30 203 * @target_rate: target PLL output clock rate (post-Q-divider)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 204 * @parent_rate: PLL input refclk rate (pre-R-divider)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 205 *
7b9487a9a5c41ce Paul Walmsley 2019-04-30 206 * Compute the appropriate PLL signal configuration values and store
7b9487a9a5c41ce Paul Walmsley 2019-04-30 207 * in PLL context @c. PLL reprogramming is not glitchless, so the
7b9487a9a5c41ce Paul Walmsley 2019-04-30 208 * caller should switch any downstream logic to a different clock
7b9487a9a5c41ce Paul Walmsley 2019-04-30 209 * source or clock-gate it before presenting these values to the PLL
7b9487a9a5c41ce Paul Walmsley 2019-04-30 210 * configuration signals.
7b9487a9a5c41ce Paul Walmsley 2019-04-30 211 *
7b9487a9a5c41ce Paul Walmsley 2019-04-30 212 * The caller must pass this function a pre-initialized struct
7b9487a9a5c41ce Paul Walmsley 2019-04-30 213 * wrpll_cfg record: either initialized to zero (with the
7b9487a9a5c41ce Paul Walmsley 2019-04-30 214 * exception of the .name and .flags fields) or read from the PLL.
7b9487a9a5c41ce Paul Walmsley 2019-04-30 215 *
7b9487a9a5c41ce Paul Walmsley 2019-04-30 216 * Context: Any context. Caller must protect the memory pointed to by @c
7b9487a9a5c41ce Paul Walmsley 2019-04-30 217 * from simultaneous access or modification.
7b9487a9a5c41ce Paul Walmsley 2019-04-30 218 *
7b9487a9a5c41ce Paul Walmsley 2019-04-30 219 * Return: 0 upon success; anything else upon failure.
7b9487a9a5c41ce Paul Walmsley 2019-04-30 220 */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 221 int wrpll_configure_for_rate(struct wrpll_cfg *c, u32 target_rate,
7b9487a9a5c41ce Paul Walmsley 2019-04-30 222 unsigned long parent_rate)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 @223 {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 224 unsigned long ratio;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 225 u64 target_vco_rate, delta, best_delta, f_pre_div, vco, vco_pre;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 226 u32 best_f, f, post_divr_freq;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 227 u8 fbdiv, divq, best_r, r;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 228 int range;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 229
7b9487a9a5c41ce Paul Walmsley 2019-04-30 230 if (c->flags == 0) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 231 WARN(1, "%s called with uninitialized PLL config", __func__);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 232 return -EINVAL;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 233 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 234
7b9487a9a5c41ce Paul Walmsley 2019-04-30 235 /* Initialize rounding data if it hasn't been initialized already */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 236 if (parent_rate != c->parent_rate) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 237 if (__wrpll_update_parent_rate(c, parent_rate)) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 238 pr_err("%s: PLL input rate is out of range\n",
7b9487a9a5c41ce Paul Walmsley 2019-04-30 239 __func__);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 240 return -ERANGE;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 241 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 242 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 243
7b9487a9a5c41ce Paul Walmsley 2019-04-30 244 c->flags &= ~WRPLL_FLAGS_RESET_MASK;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 245
7b9487a9a5c41ce Paul Walmsley 2019-04-30 246 /* Put the PLL into bypass if the user requests the parent clock rate */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 247 if (target_rate == parent_rate) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 248 c->flags |= WRPLL_FLAGS_BYPASS_MASK;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 249 return 0;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 250 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 251
7b9487a9a5c41ce Paul Walmsley 2019-04-30 252 c->flags &= ~WRPLL_FLAGS_BYPASS_MASK;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 253
7b9487a9a5c41ce Paul Walmsley 2019-04-30 254 /* Calculate the Q shift and target VCO rate */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 255 divq = __wrpll_calc_divq(target_rate, &target_vco_rate);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 256 if (!divq)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 257 return -1;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 258 c->divq = divq;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 259
7b9487a9a5c41ce Paul Walmsley 2019-04-30 260 /* Precalculate the pre-Q divider target ratio */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 261 ratio = div64_u64((target_vco_rate << ROUND_SHIFT), parent_rate);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 262
7b9487a9a5c41ce Paul Walmsley 2019-04-30 263 fbdiv = __wrpll_calc_fbdiv(c);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 264 best_r = 0;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 265 best_f = 0;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 266 best_delta = MAX_VCO_FREQ;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 267
7b9487a9a5c41ce Paul Walmsley 2019-04-30 268 /*
7b9487a9a5c41ce Paul Walmsley 2019-04-30 269 * Consider all values for R which land within
7b9487a9a5c41ce Paul Walmsley 2019-04-30 270 * [MIN_POST_DIVR_FREQ, MAX_POST_DIVR_FREQ]; prefer smaller R
7b9487a9a5c41ce Paul Walmsley 2019-04-30 271 */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 272 for (r = c->init_r; r <= c->max_r; ++r) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 273 f_pre_div = ratio * r;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 274 f = (f_pre_div + (1 << ROUND_SHIFT)) >> ROUND_SHIFT;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 275 f >>= (fbdiv - 1);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 276
7b9487a9a5c41ce Paul Walmsley 2019-04-30 277 post_divr_freq = div_u64(parent_rate, r);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 278 vco_pre = fbdiv * post_divr_freq;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 279 vco = vco_pre * f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 280
7b9487a9a5c41ce Paul Walmsley 2019-04-30 281 /* Ensure rounding didn't take us out of range */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 282 if (vco > target_vco_rate) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 283 --f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 284 vco = vco_pre * f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 285 } else if (vco < MIN_VCO_FREQ) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 286 ++f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 287 vco = vco_pre * f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 288 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 289
7b9487a9a5c41ce Paul Walmsley 2019-04-30 290 delta = abs(target_rate - vco);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 291 if (delta < best_delta) {
7b9487a9a5c41ce Paul Walmsley 2019-04-30 292 best_delta = delta;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 293 best_r = r;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 294 best_f = f;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 295 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 296 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 297
7b9487a9a5c41ce Paul Walmsley 2019-04-30 298 c->divr = best_r - 1;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 299 c->divf = best_f - 1;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 300
7b9487a9a5c41ce Paul Walmsley 2019-04-30 301 post_divr_freq = div_u64(parent_rate, best_r);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 302
7b9487a9a5c41ce Paul Walmsley 2019-04-30 303 /* Pick the best PLL jitter filter */
7b9487a9a5c41ce Paul Walmsley 2019-04-30 304 range = __wrpll_calc_filter_range(post_divr_freq);
7b9487a9a5c41ce Paul Walmsley 2019-04-30 305 if (range < 0)
7b9487a9a5c41ce Paul Walmsley 2019-04-30 306 return range;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 307 c->range = range;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 308
7b9487a9a5c41ce Paul Walmsley 2019-04-30 309 return 0;
7b9487a9a5c41ce Paul Walmsley 2019-04-30 310 }
7b9487a9a5c41ce Paul Walmsley 2019-04-30 311
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 25404 bytes --]
next prev parent reply other threads:[~2020-10-23 20:03 UTC|newest]
Thread overview: 162+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-23 16:32 [PATCH v3 00/56] Fix several bad kernel-doc markups Mauro Carvalho Chehab
2020-10-23 16:32 ` [PATCH v3 01/56] scripts: kernel-doc: fix typedef parsing Mauro Carvalho Chehab
2020-10-23 17:22 ` Jonathan Corbet
2020-10-23 18:01 ` Joe Perches
2020-10-26 7:03 ` Mauro Carvalho Chehab
2020-10-27 3:55 ` Joe Perches
2020-10-27 8:37 ` Mauro Carvalho Chehab
2020-10-24 6:43 ` Mauro Carvalho Chehab
2020-10-26 5:55 ` Mauro Carvalho Chehab
2020-10-23 16:32 ` [PATCH v3 02/56] drm: amdgpu_dm: fix a typo Mauro Carvalho Chehab
2020-10-23 16:32 ` Mauro Carvalho Chehab
2020-10-23 16:32 ` Mauro Carvalho Chehab
2020-10-23 19:02 ` Alex Deucher
2020-10-23 19:02 ` Alex Deucher
2020-10-23 19:02 ` Alex Deucher
2020-10-23 16:32 ` [PATCH v3 03/56] amdgpu: fix a few kernel-doc markup issues Mauro Carvalho Chehab
2020-10-23 16:32 ` Mauro Carvalho Chehab
2020-10-23 16:32 ` Mauro Carvalho Chehab
2020-10-23 16:38 ` Christian König
2020-10-23 16:38 ` Christian König
2020-10-23 16:38 ` Christian König
2020-10-23 18:58 ` Alex Deucher
2020-10-23 18:58 ` Alex Deucher
2020-10-23 18:58 ` Alex Deucher
2020-10-23 16:32 ` [PATCH v3 04/56] drm: drm_print.h: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-23 16:32 ` Mauro Carvalho Chehab
2020-10-23 16:32 ` [PATCH v3 05/56] s390: " Mauro Carvalho Chehab
2020-10-23 16:32 ` [PATCH v3 06/56] x86: mtrr: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-23 16:32 ` [PATCH v3 07/56] block: blk-mq: " Mauro Carvalho Chehab
2020-10-23 18:20 ` Jens Axboe
2020-10-23 16:32 ` [PATCH v3 08/56] ata: fix some kernel-doc markups Mauro Carvalho Chehab
2020-10-23 18:21 ` Jens Axboe
2020-10-23 16:32 ` [PATCH v3 09/56] drivers: base: " Mauro Carvalho Chehab
2020-10-23 16:32 ` [PATCH v3 10/56] EDAC: " Mauro Carvalho Chehab
2020-11-02 19:37 ` Borislav Petkov
2020-10-23 16:32 ` [PATCH v3 11/56] drm/amdgpu: " Mauro Carvalho Chehab
2020-10-23 16:32 ` Mauro Carvalho Chehab
2020-10-23 16:32 ` Mauro Carvalho Chehab
2020-10-23 16:50 ` Christian König
2020-10-23 16:50 ` Christian König
2020-10-23 16:50 ` Christian König
2020-10-23 18:59 ` Alex Deucher
2020-10-23 18:59 ` Alex Deucher
2020-10-23 18:59 ` Alex Deucher
2020-10-23 16:32 ` [PATCH v3 12/56] drm: " Mauro Carvalho Chehab
2020-10-23 16:32 ` [Intel-gfx] " Mauro Carvalho Chehab
2020-10-23 16:32 ` Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 13/56] HSI: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 14/56] IB: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-23 16:33 ` Mauro Carvalho Chehab
2020-10-24 21:50 ` Max Gurtovoy
2020-10-24 21:50 ` Max Gurtovoy
2020-10-23 16:33 ` [PATCH v3 15/56] media: " Mauro Carvalho Chehab
2020-10-23 16:33 ` Mauro Carvalho Chehab
2020-10-23 17:27 ` Sakari Ailus
2020-10-23 17:27 ` Sakari Ailus
2020-10-23 16:33 ` [PATCH v3 16/56] mei: bus: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 17/56] mtd: rawnand: " Mauro Carvalho Chehab
2020-10-23 16:33 ` Mauro Carvalho Chehab
2020-10-30 17:27 ` Miquel Raynal
2020-10-30 17:27 ` Miquel Raynal
2020-10-23 16:33 ` [PATCH v3 18/56] net: phy: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-23 21:04 ` Andrew Lunn
2020-10-23 16:33 ` [PATCH v3 19/56] net: datagram: fix some " Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 20/56] net: core: " Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 21/56] mac80211: fix " Mauro Carvalho Chehab
2020-10-27 7:26 ` Johannes Berg
2020-10-27 8:00 ` Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 22/56] parport: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 23/56] PCI: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-23 17:43 ` Bjorn Helgaas
2020-10-24 7:30 ` Mauro Carvalho Chehab
2020-11-05 14:44 ` Bjorn Helgaas
2020-10-23 16:33 ` [PATCH v3 24/56] PNP: " Mauro Carvalho Chehab
2020-10-27 18:24 ` Rafael J. Wysocki
2020-10-23 16:33 ` [PATCH v3 25/56] rapidio: fix kernel-doc a markup Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 26/56] regulator: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 27/56] scsi: fix some kernel-doc markups Mauro Carvalho Chehab
2020-10-27 1:54 ` Martin K. Petersen
2020-10-23 16:33 ` [PATCH v3 28/56] slimbus: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-23 16:33 ` Mauro Carvalho Chehab
2020-10-26 14:52 ` Srinivas Kandagatla
2020-10-26 14:52 ` Srinivas Kandagatla
2020-10-23 16:33 ` [PATCH v3 29/56] spi: fix a typo inside " Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 30/56] uio: fix some kernel-doc markups Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 31/56] usb: dwc3: fix " Mauro Carvalho Chehab
2020-10-27 6:58 ` Felipe Balbi
2020-10-28 9:08 ` Greg Kroah-Hartman
2020-10-28 9:13 ` Felipe Balbi
2020-10-23 16:33 ` [PATCH v3 32/56] video: fix some " Mauro Carvalho Chehab
2020-10-23 16:33 ` Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 33/56] vme: fix two " Mauro Carvalho Chehab
2020-10-23 16:33 ` Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 34/56] fs: fix " Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 35/56] jbd2: " Mauro Carvalho Chehab
2020-10-23 16:57 ` Jan Kara
2020-10-23 16:33 ` [PATCH v3 36/56] locks: fix a typo at a kernel-doc markup Mauro Carvalho Chehab
2020-10-26 12:01 ` Jeff Layton
2020-10-23 16:33 ` [PATCH v3 37/56] pstore/zone: fix " Mauro Carvalho Chehab
2020-10-23 17:40 ` Kees Cook
2020-10-23 16:33 ` [PATCH v3 38/56] clk: " Mauro Carvalho Chehab
2020-11-05 2:01 ` Stephen Boyd
2020-10-23 16:33 ` [PATCH v3 39/56] completion: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 40/56] firmware: stratix10-svc: " Mauro Carvalho Chehab
2020-10-27 17:31 ` Richard Gong
2020-10-23 16:33 ` [PATCH v3 41/56] connector: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 42/56] lib/crc7: " Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 43/56] hrtimer: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 44/56] genirq: " Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 45/56] iio: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-29 15:43 ` Jonathan Cameron
2020-10-23 16:33 ` [PATCH v3 46/56] list: fix a typo at the " Mauro Carvalho Chehab
2020-10-23 17:55 ` Andy Shevchenko
2020-10-23 20:50 ` Paul E. McKenney
2020-10-23 16:33 ` [PATCH v3 47/56] memblock: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-25 6:34 ` Mike Rapoport
2020-10-23 16:33 ` [PATCH v3 48/56] sound: " Mauro Carvalho Chehab
2020-10-23 16:33 ` Mauro Carvalho Chehab
2020-10-23 18:26 ` Mark Brown
2020-10-23 18:26 ` Mark Brown
2020-10-26 13:46 ` Takashi Iwai
2020-10-26 13:46 ` Takashi Iwai
2020-10-26 14:14 ` Mauro Carvalho Chehab
2020-10-26 14:14 ` Mauro Carvalho Chehab
2020-10-26 14:25 ` Takashi Iwai
2020-10-26 14:25 ` Takashi Iwai
2020-10-23 16:33 ` [PATCH v3 49/56] refcount.h: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-23 17:40 ` Kees Cook
2020-10-23 19:39 ` Peter Zijlstra
2020-10-23 19:47 ` Jonathan Corbet
2020-10-24 6:28 ` Mauro Carvalho Chehab
2020-10-26 8:10 ` Peter Zijlstra
2020-10-26 9:16 ` Mauro Carvalho Chehab
2020-10-26 9:38 ` Peter Zijlstra
2020-10-23 16:33 ` [PATCH v3 50/56] w1: " Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 51/56] audit: " Mauro Carvalho Chehab
2020-10-23 16:33 ` Mauro Carvalho Chehab
2020-10-25 22:10 ` Paul Moore
2020-10-25 22:10 ` Paul Moore
2020-10-25 22:38 ` Mauro Carvalho Chehab
2020-10-25 22:38 ` Mauro Carvalho Chehab
2020-10-28 0:59 ` Paul Moore
2020-10-28 0:59 ` Paul Moore
2020-10-23 16:33 ` [PATCH v3 52/56] resource: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 53/56] shed: fix kernel-doc markup Mauro Carvalho Chehab
2020-10-23 17:53 ` Steven Rostedt
2020-10-26 10:07 ` Mauro Carvalho Chehab
2020-10-23 16:33 ` [PATCH v3 54/56] mm: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-23 17:46 ` Matthew Wilcox
2020-10-23 16:33 ` [PATCH v3 55/56] selftests: kselftest_harness.h: partially " Mauro Carvalho Chehab
2020-10-23 17:39 ` Kees Cook
2020-10-23 16:33 ` [PATCH v3 56/56] scrpits: kernel-doc: validate kernel-doc markup with the actual names Mauro Carvalho Chehab
2020-10-23 20:02 ` kernel test robot [this message]
2020-10-23 20:02 ` kernel test robot
2020-10-23 20:34 ` kernel test robot
2020-10-23 20:34 ` kernel test robot
2020-11-05 15:00 ` Matthew Wilcox
2020-11-05 15:15 ` Jonathan Corbet
2020-11-05 15:30 ` Matthew Wilcox
2020-11-05 15:20 ` Mauro Carvalho Chehab
2020-10-23 18:12 ` [PATCH v3 00/56] Fix several bad kernel-doc markups Jakub Kicinski
2020-10-23 18:22 ` 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=202010240356.04GQOaBt-lkp@intel.com \
--to=lkp@intel.com \
--cc=clang-built-linux@googlegroups.com \
--cc=corbet@lwn.net \
--cc=kbuild-all@lists.01.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
/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.