* Re: [PATCH v2 2/3] Bluetooth: btintel_pcie: Add support for PCIe transport
[not found] <20240507155658.294676-2-kiran.k@intel.com>
@ 2024-05-07 22:25 ` kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-05-07 22:25 UTC (permalink / raw)
To: Kiran K; +Cc: llvm, oe-kbuild-all
Hi Kiran,
kernel test robot noticed the following build warnings:
[auto build test WARNING on bluetooth-next/master]
[also build test WARNING on bluetooth/master linus/master v6.9-rc7 next-20240507]
[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/Kiran-K/Bluetooth-btintel_pcie-Add-support-for-PCIe-transport/20240507-234447
base: https://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git master
patch link: https://lore.kernel.org/r/20240507155658.294676-2-kiran.k%40intel.com
patch subject: [PATCH v2 2/3] Bluetooth: btintel_pcie: Add support for PCIe transport
config: arm-defconfig (https://download.01.org/0day-ci/archive/20240508/202405080647.VRBej6fA-lkp@intel.com/config)
compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project.git f28c006a5895fc0e329fe15fead81e37457cb1d1)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240508/202405080647.VRBej6fA-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/202405080647.VRBej6fA-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> drivers/bluetooth/btintel_pcie.c:184:6: warning: variable 'reg' set but not used [-Wunused-but-set-variable]
u32 reg;
^
>> drivers/bluetooth/btintel_pcie.c:192:26: warning: shift count >= width of type [-Wshift-count-overflow]
data->ci_p_addr >> 32);
^ ~~
>> drivers/bluetooth/btintel_pcie.c:458:15: warning: variable 'frbd' set but not used [-Wunused-but-set-variable]
struct frbd *frbd;
^
3 warnings generated.
vim +/reg +184 drivers/bluetooth/btintel_pcie.c
174
175 /* This function enables BT function by setting BTINTEL_PCIE_CSR_FUNC_CTRL_MAC_INIT bit in
176 * BTINTEL_PCIE_CSR_FUNC_CTRL_REG register and wait for MSI-X with
177 * BTINTEL_PCIE_MSIX_HW_INT_CAUSES_GP0.
178 * Then the host reads firmware version from BTINTEL_CSR_F2D_MBX and the boot stage
179 * from BTINTEL_PCIE_CSR_BOOT_STAGE_REG.
180 */
181 static int btintel_pcie_enable_bt(struct btintel_pcie_data *data)
182 {
183 int err;
> 184 u32 reg;
185
186 data->gp0_received = false;
187
188 /* Update the DMA address of CI struct to CSR */
189 btintel_pcie_wr_reg32(data, BTINTEL_PCIE_CSR_CI_ADDR_LSB_REG,
190 data->ci_p_addr & 0xffffffff);
191 btintel_pcie_wr_reg32(data, BTINTEL_PCIE_CSR_CI_ADDR_MSB_REG,
> 192 data->ci_p_addr >> 32);
193
194 /* Reset the cached value of boot stage. it is updated by the MSI-X
195 * gp0 interrupt handler.
196 */
197 data->boot_stage_cache = 0x0;
198
199 /* Set MAC_INIT bit to start primary bootloader */
200 reg = btintel_pcie_rd_reg32(data, BTINTEL_PCIE_CSR_FUNC_CTRL_REG);
201
202 btintel_pcie_set_reg_bits(data, BTINTEL_PCIE_CSR_FUNC_CTRL_REG,
203 BTINTEL_PCIE_CSR_FUNC_CTRL_MAC_INIT);
204
205 /* Wait until MAC_ACCESS is granted */
206 err = btintel_pcie_poll_bit(data, BTINTEL_PCIE_CSR_FUNC_CTRL_REG,
207 BTINTEL_PCIE_CSR_FUNC_CTRL_MAC_ACCESS_STS,
208 BTINTEL_PCIE_CSR_FUNC_CTRL_MAC_ACCESS_STS,
209 BTINTEL_DEFAULT_MAC_ACCESS_TIMEOUT_US);
210 if (err < 0)
211 return -ENODEV;
212
213 /* MAC is ready. Enable BT FUNC */
214 btintel_pcie_set_reg_bits(data, BTINTEL_PCIE_CSR_FUNC_CTRL_REG,
215 BTINTEL_PCIE_CSR_FUNC_CTRL_FUNC_ENA |
216 BTINTEL_PCIE_CSR_FUNC_CTRL_FUNC_INIT);
217
218 reg = btintel_pcie_rd_reg32(data, BTINTEL_PCIE_CSR_FUNC_CTRL_REG);
219
220 /* wait for interrupt from the device after booting up to primary
221 * bootloader.
222 */
223 err = wait_event_timeout(data->gp0_wait_q, data->gp0_received,
224 msecs_to_jiffies(BTINTEL_DEFAULT_INTR_TIMEOUT));
225 if (!err)
226 return -ETIME;
227
228 /* Check cached boot stage is BTINTEL_PCIE_CSR_BOOT_STAGE_ROM(BIT(0)) */
229 if (~data->boot_stage_cache & BTINTEL_PCIE_CSR_BOOT_STAGE_ROM)
230 return -ENODEV;
231
232 return 0;
233 }
234
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread