From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matthias Kaehlcke Subject: Re: [PATCH v5 2/5] Bluetooth: hci_qca: Deassert RTS while baudrate change command Date: Thu, 17 Jan 2019 09:21:09 -0800 Message-ID: <20190117172109.GU261387@google.com> References: <20190109145224.GN14782@localhost> <20190110143928.GE3430@localhost> <61301df80bd6a8ee0265b31b7f6a3aa1@codeaurora.org> <20190111013707.GD261387@google.com> <194b5d18ea86830b6a24939d483a964c@codeaurora.org> <20190111235633.GK261387@google.com> <20190115234628.GQ261387@google.com> <20190117160944.GV3691@localhost> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Return-path: Content-Disposition: inline In-Reply-To: <20190117160944.GV3691@localhost> Sender: linux-kernel-owner@vger.kernel.org To: Johan Hovold Cc: Balakrishna Godavarthi , marcel@holtmann.org, johan.hedberg@gmail.com, linux-kernel@vger.kernel.org, linux-bluetooth@vger.kernel.org, hemantg@codeaurora.org, linux-arm-msm@vger.kernel.org, Johan Hovold List-Id: linux-arm-msm@vger.kernel.org On Thu, Jan 17, 2019 at 05:09:44PM +0100, Johan Hovold wrote: > On Tue, Jan 15, 2019 at 03:46:28PM -0800, Matthias Kaehlcke wrote: > > > Using RTS seems|ed like a nice solutions, since it's the native way to > > prevent the controller from sending data, instead of doing some custom > > hack. However Johan seems to be fairly convinced that flow control and > > manual toggling of RTS can be problematic, and we have seen that > > disabling flow control has its own problems. Maybe it's time to > > consider other solutions like the DISCARD_RX flag we discussed > > earlier. Not that I really liked this custom solution, but in the end > > it might be a more robust way to address the issue. > > > > Johan/Marcel/others: Do you have any further ideas or input on this? > > I don't see why deasserting RTS wouldn't work, well at least as long as > the RTS signal is wired correctly. > > My point was simply that calling serdev_device_set_rts() will generally > not work unless you first disable automatic (i.e. hw-managed) flow > control using serdev_device_set_flow_control(). The exact behaviour is > serial-controller dependent, but I assume the driver needs to be > platform agnostic. I observed that the qcom_geni_serial driver doesn't raise RTS with flow control disabled. It seems we have to investigate why that's the case. I agree that the driver should be platform agnostic. Cheers Matthias