lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5j5dxvuki2hotlve2p3evv2ofkelqornzdyord4kvday5ukgr2@s743nvfri56k>
Date: Tue, 6 Jan 2026 01:41:30 +0200
From: Dmitry Baryshkov <dmitry.baryshkov@....qualcomm.com>
To: Praveen Talari <praveen.talari@....qualcomm.com>
Cc: Bjorn Andersson <andersson@...nel.org>,
        Konrad Dybcio <konradybcio@...nel.org>, Rob Herring <robh@...nel.org>,
        Krzysztof Kozlowski <krzk+dt@...nel.org>,
        Conor Dooley <conor+dt@...nel.org>,
        Linus Walleij <linus.walleij@...aro.org>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Jiri Slaby <jirislaby@...nel.org>, Dmitry Baryshkov <lumag@...nel.org>,
        linux-arm-msm@...r.kernel.org, devicetree@...r.kernel.org,
        linux-kernel@...r.kernel.org, linux-gpio@...r.kernel.org,
        linux-serial@...r.kernel.org, alexey.klimov@...aro.org,
        krzk@...nel.org, bryan.odonoghue@...aro.org,
        jorge.ramirez@....qualcomm.com,
        Konrad Dybcio <konrad.dybcio@....qualcomm.com>, psodagud@...cinc.com,
        djaggi@...cinc.com, quic_msavaliy@...cinc.com,
        quic_vtanuku@...cinc.com, quic_arandive@...cinc.com,
        quic_shazhuss@...cinc.com, quic_cchiluve@...cinc.com
Subject: Re: [PATCH v1 3/4] serial: qcom-geni: Enable PM runtime for serial
 driver

On Mon, Jan 05, 2026 at 09:42:32PM +0530, Praveen Talari wrote:
> Hi Dmitry,
> 
> On 12/31/2025 11:21 AM, Dmitry Baryshkov wrote:
> > On 31/12/2025 07:49, Praveen Talari wrote:
> > > Hi Dmitry,
> > > 
> > > On 12/31/2025 8:30 AM, Dmitry Baryshkov wrote:
> > > > On 31/12/2025 05:00, Praveen Talari wrote:
> > > > > Hi Dmitry,
> > > > > 
> > > > > On 12/30/2025 11:53 PM, Dmitry Baryshkov wrote:
> > > > > > On Mon, Nov 10, 2025 at 03:40:42PM +0530, Praveen Talari wrote:
> > > > > > > The GENI serial driver currently handles power resource management
> > > > > > > through calls to the statically defined
> > > > > > > geni_serial_resources_on() and
> > > > > > > geni_serial_resources_off() functions. This approach
> > > > > > > reduces modularity
> > > > > > > and limits support for platforms with diverse power management
> > > > > > > mechanisms, including resource managed by firmware.
> > > > > > > 
> > > > > > > Improve modularity and enable better integration
> > > > > > > with platform- specific
> > > > > > > power management, introduce support for runtime PM. Use
> > > > > > > pm_runtime_resume_and_get() and pm_runtime_put_sync() within the
> > > > > > > qcom_geni_serial_pm() callback to control resource power state
> > > > > > > transitions based on UART power state changes.
> > > > > > > 
> > > > > > > Signed-off-by: Praveen Talari <praveen.talari@....qualcomm.com>
> > > > > > > ---
> > > > > > >   drivers/tty/serial/qcom_geni_serial.c | 24 ++++++++++++++++++++++--
> > > > > > >   1 file changed, 22 insertions(+), 2 deletions(-)
> > > > > > > 
> > > > > > 
> > > > > > This breaks BT support on the Qualcomm RB2 platform. With this patch
> > > > > > applied, I'm getting the following:
> > > > > > 
> > > > > > root@...m-armv8a:~# dmesg | grep tty\\\|hci0
> > > > > > [    0.000000] Kernel command line:  ignore_loglevel
> > > > > > console=ttyMSM0,115200n8 earlycon root=PARTLABEL=rootfs
> > > > > > rootwait systemd.mask=pd-mapper.service --
> > > > > > androidboot.bootdevice=4744000.sdhci
> > > > > > androidboot.serialno=2b89b520 androidboot.baseband=apq
> > > > > > msm_drm.dsi_display0=qcom,mdss_dsi_ext_bridge_1080p:
> > > > > > [    4.074354] 4a8c000.serial: ttyHS1 at MMIO 0x4a8c000
> > > > > > (irq = 140, base_baud = 0) is a MSM
> > > > > > [    4.099410] serial serial0: tty port ttyHS1 registered
> > > > > > [    4.131200] Bluetooth: hci0: setting up wcn399x
> > > > > > [    4.149847] 4a90000.serial: ttyMSM0 at MMIO 0x4a90000
> > > > > > (irq = 142, base_baud = 0) is a MSM
> > > > > > [    4.229099] printk: legacy console [ttyMSM0] enabled
> > > > > > [    6.499519] Bluetooth: hci0: command 0xfc00 tx timeout
> > > > > > [    6.514347] Bluetooth: hci0: Reading QCA version
> > > > > > information failed (-110)
> > > > > > [    6.559933] Bluetooth: hci0: Retry BT power ON:0
> > > > > > [    8.016330] systemd[1]: Created slice Slice /system/getty.
> > > > > > [    8.066194] systemd[1]: Created slice Slice /system/serial-getty.
> > > > > > [    8.148389] systemd[1]: Expecting device /dev/ttyMSM0...
> > > > > > [    8.956804] Bluetooth: hci0: command 0xfc00 tx timeout
> > > > > > [    8.962447] Bluetooth: hci0: Reading QCA version
> > > > > > information failed (-110)
> > > > > > [    8.976917] Bluetooth: hci0: Retry BT power ON:1
> > > > > > [   11.296715] Bluetooth: hci0: command 0xfc00 tx timeout
> > > > > > [   11.302340] Bluetooth: hci0: Reading QCA version
> > > > > > information failed (-110)
> > > > > > [   11.309534] Bluetooth: hci0: Retry BT power ON:2
> > > > > > [   13.660078] Bluetooth: hci0: command 0xfc00 tx timeout
> > > > > > [   13.665814] Bluetooth: hci0: Reading QCA version
> > > > > > information failed (-110)
> > > > > 
> > > > > Sure, will check and update.
> > > > > 
> > > > > If possible, can you share what is DT filename for RB2.
> > > > 
> > > > qrb4210-rb2.dts
> > > 
> > > Can you please try below change on target since i didn't get target yet?
> > 
> > Yes, I have this patch too. It didn't help.
> 
> As we discussed offline, On the RB2 target, Bluetooth fails during bootup
> but functions correctly once bootup is complete.
> 
> I suspect that GPIO configurations are being affected during the bootup
> process, possibly due to the wakeup registration sequence.
> 
> To address this, I have moved the wakeup registration process to occur
> before enabling PM runtime.
> 
> Could you please try below change and let me know result?

This patch seems to fix the issue. Please send it as a properly
formatted patch.

> 
> diff --git a/drivers/tty/serial/qcom_geni_serial.c
> b/drivers/tty/serial/qcom_geni_serial.c
> index 6ce6528f5c10..46a9c71630d5 100644
> --- a/drivers/tty/serial/qcom_geni_serial.c
> +++ b/drivers/tty/serial/qcom_geni_serial.c
> @@ -1888,12 +1888,6 @@ static int qcom_geni_serial_probe(struct
> platform_device *pdev)
>         if (ret)
>                 goto error;
> 
> -       devm_pm_runtime_enable(port->se.dev);
> -
> -       ret = uart_add_one_port(drv, uport);
> -       if (ret)
> -               goto error;
> -
>         if (port->wakeup_irq > 0) {
>                 device_init_wakeup(&pdev->dev, true);
>                 ret = dev_pm_set_dedicated_wake_irq(&pdev->dev,
> @@ -1906,6 +1900,12 @@ static int qcom_geni_serial_probe(struct
> platform_device *pdev)
>                 }
>         }
> 
> +       devm_pm_runtime_enable(port->se.dev);
> +
> +       ret = uart_add_one_port(drv, uport);
> +       if (ret)
> +               goto error;
> +
>         return 0;
> 
> Thanks,
> Praveen Talari
> > 
> > > 
> > > diff --git a/arch/arm64/boot/dts/qcom/qrb4210-rb2.dts b/arch/arm64/
> > > boot/ dts/qcom/qrb4210-rb2.dts
> > > index 0cd36c54632f..5f8613150bdd 100644
> > > --- a/arch/arm64/boot/dts/qcom/qrb4210-rb2.dts
> > > +++ b/arch/arm64/boot/dts/qcom/qrb4210-rb2.dts
> > > @@ -694,7 +694,7 @@ sdc2_card_det_n: sd-card-det-n-state {
> > > 
> > >   &uart3 {
> > >          interrupts-extended = <&intc GIC_SPI 330 IRQ_TYPE_LEVEL_HIGH>,
> > > -                             <&tlmm 11 IRQ_TYPE_LEVEL_HIGH>;
> > > +                             <&tlmm 11 IRQ_TYPE_EDGE_FALLING>;
> > >          pinctrl-0 = <&uart3_default>;
> > >          pinctrl-1 = <&uart3_sleep>;
> > >          pinctrl-names = "default", "sleep";
> > > 
> > > Thanks,
> > > Praveen Talari
> > > 
> > > > 
> > > > > 
> > > > > Earlier I had validated on RB1 and Kodiak.
> > > > > 
> > > > > Thanks,
> > > > > Praveen
> > > > > 
> > > > > > 
> > > > > > After reverting the next and this patches, BT is back to normal:
> > > > > > 
> > > > > > [    4.067201] 4a8c000.serial: ttyHS1 at MMIO 0x4a8c000
> > > > > > (irq = 140, base_baud = 0) is a MSM
> > > > > > [    4.082426] serial serial0: tty port ttyHS1 registered
> > > > > > [    4.106122] 4a90000.serial: ttyMSM0 at MMIO 0x4a90000
> > > > > > (irq = 142, base_baud = 0) is a MSM
> > > > > > [    4.108647] Bluetooth: hci0: setting up wcn399x
> > > > > > [    4.125371] printk: legacy console [ttyMSM0] enabled
> > > > > > [    4.445205] Bluetooth: hci0: QCA Product ID   :0x0000000a
> > > > > > [    4.450927] Bluetooth: hci0: QCA SOC Version  :0x40020150
> > > > > > [    4.456470] Bluetooth: hci0: QCA ROM Version  :0x00000201
> > > > > > [    4.462006] Bluetooth: hci0: QCA Patch Version:0x00000001
> > > > > > [    4.509408] Bluetooth: hci0: QCA controller version 0x01500201
> > > > > > [    4.515656] Bluetooth: hci0: QCA Downloading qca/apbtfw11.tlv
> > > > > > [    5.488739] Bluetooth: hci0: QCA Downloading qca/apnv11.bin
> > > > > > [    5.671740] Bluetooth: hci0: QCA setup on UART is completed
> > > > > > [    7.993368] systemd[1]: Created slice Slice /system/getty.
> > > > > > [    8.045612] systemd[1]: Created slice Slice /system/serial-getty.
> > > > > > [    8.125418] systemd[1]: Expecting device /dev/ttyMSM0...
> > > > > > 
> > > > > > 
> > > > 
> > > > 
> > > 
> > 
> > 
> 

-- 
With best wishes
Dmitry

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ