Re: [PATCH v4 3/3] Bluetooth: NXP: Add protocol support for NXP Bluetooth chipsets

From
Neeraj sanjay kale <neeraj.sanjaykale@nxp.com>
Date
2023-02-23 10:41:00
Also in
linux-bluetooth, linux-devicetree, linux-serial, lkml
Reply to
Greg KH, 2023-02-21
Hi Greg,

Thank you for reviewing this patch.
quoted
+             bt_dev_info(hdev, "Set UART break: %s, status=%d",
+                         ps_state == PS_STATE_AWAKE ? "off" : "on",
+ status);
You have a lot of "noise" in this driver, remove all "info" messages, as if a
driver is working properly, it is quiet.
Replaced all bt_dev_info() and bt_dev_err() with bt_dev_dbg() for all instances where user action is not possible.
quoted
+     } else if (req_len == sizeof(uart_config)) {
+             uart_config.clkdiv.address = __cpu_to_le32(CLKDIVADDR);
+             uart_config.clkdiv.value = __cpu_to_le32(0x00c00000);
+             uart_config.uartdiv.address = __cpu_to_le32(UARTDIVADDR);
+             uart_config.uartdiv.value = __cpu_to_le32(1);
+             uart_config.mcr.address = __cpu_to_le32(UARTMCRADDR);
+             uart_config.mcr.value = __cpu_to_le32(MCR);
+             uart_config.re_init.address = __cpu_to_le32(UARTREINITADDR);
+             uart_config.re_init.value = __cpu_to_le32(INIT);
+             uart_config.icr.address = __cpu_to_le32(UARTICRADDR);
+             uart_config.icr.value = __cpu_to_le32(ICR);
+             uart_config.fcr.address = __cpu_to_le32(UARTFCRADDR);
+             uart_config.fcr.value = __cpu_to_le32(FCR);
+             uart_config.crc = swab32(nxp_fw_dnld_update_crc(0UL,
+                                                             (char *)&uart_config,
+                                                             sizeof(uart_config) - 4));
+             serdev_device_write_buf(nxpdev->serdev, (u8 *)&uart_config,
req_len);
quoted
+             serdev_device_wait_until_sent(nxpdev->serdev, 0);
You are sending magic commands over the serial connection, are you sure
that is ok?
Yes, we are sending this only when the BT chip's bootloader is requesting for payload for the CMD5 sent earlier during FW download.

Thanks,
Neeraj
Thread (10 messages) 10 messages, 4 authors, last reply 2023-02-23
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help