Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp1595368rwb; Mon, 7 Nov 2022 03:37:38 -0800 (PST) X-Google-Smtp-Source: AMsMyM47QCOhnduzW2qxyfDYkq9v6JeMM4YF+TdvZnbLblBbJY/PxduXjyJdV+sEqxZobe4FkKTW X-Received: by 2002:a17:902:7485:b0:17d:5176:fe6e with SMTP id h5-20020a170902748500b0017d5176fe6emr50324770pll.147.1667821058093; Mon, 07 Nov 2022 03:37:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1667821058; cv=none; d=google.com; s=arc-20160816; b=PinXzw9sY5rAGahGBSNN1bEqqJ5Pa1xKje6QARga/cEI56pLfOkX2Z/oEsvgUKO3Eq 2KbOsZO42+Fbv84bXxpbeN2XQaIb7Lr6DPC7Etv3iZa45VXUeiz3wuxvDSTlSqVVKXmr rvjaVaHs4iIl6MDB9zTF2Jxn+SjmpCSLpiZRcZEbJkODLD5hg1n4ZwN5VdEjkhsBN+cS tCfAbNE6eVxb83/08Ja0NDt94LEpzrWY6+2kYAwMuMdBWfvNnTfvoLhXL3UgEUzFXFRY 628BT346T+i1vUST9F9RXGXLjNd5RdISiW7UNN6NhLFrwLX5Gvu4SbLfcqpfpvL4VLy/ YmOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=mwsOXXbcfC9fPjVivpon0nxUnv1iu8M1E4VwDE036so=; b=1BPNgKcn5LMHx7c/ONg7zfKsXqOOUzs8uCYdIU9pnlqPWXaHe3zMHjJuH0YxTPOaI1 N+EX4FTNy3EkMt1Kd4cK2MjflcgDkV9ijg9lp4tJ0G1oXmCOaBms+JBqYQIfFj+hBG4h e/G1IMLA7Fxuu8l6suHhCYIQo/2H7hM04gL0I7qWagWd4LKAcER/S/WdRZBTU5HS4pfu JpFA9emW7DIVEt7rSXQ2ICA2veaVOa7fOTwOArKPqzIURXjUvh7YYpTd/7SEQF3pcf5g 0f+e55N22YOvWR0s99nLzZ0me+st/4hGsOqqxnBR6EiUEkXLsI0gtG9cvzVY22NfmdKq uFzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=HwjEbCai; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n17-20020a170903405100b00186a06a3396si7968625pla.153.2022.11.07.03.37.24; Mon, 07 Nov 2022 03:37:38 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=HwjEbCai; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231843AbiKGLcN (ORCPT + 67 others); Mon, 7 Nov 2022 06:32:13 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47298 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231831AbiKGLcL (ORCPT ); Mon, 7 Nov 2022 06:32:11 -0500 Received: from mail-pg1-x533.google.com (mail-pg1-x533.google.com [IPv6:2607:f8b0:4864:20::533]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9ACC018E12; Mon, 7 Nov 2022 03:32:09 -0800 (PST) Received: by mail-pg1-x533.google.com with SMTP id 64so10201796pgc.5; Mon, 07 Nov 2022 03:32:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=mwsOXXbcfC9fPjVivpon0nxUnv1iu8M1E4VwDE036so=; b=HwjEbCai0XhnP/RUIQarlE9bfsmBkDgCqDCOF5dUFqyYssiqdFn8MvDkPr1Q0XQ1Pj CeEer3BdC00JYtah1OgHhWFD7FEeXIdTHqCNq/l5B5WtDmLbwvFTSEJh5WOMZqIfZ254 hIr1csj6KbkARIBEnmh7fNWIBxQZ9uXtlo/ONmYvdv8MlS2SzlyCP6fzFQ++AxnZHbJ1 Bw9hbjjKguoWE1dJIKht/T48yspuYjguQp12lk1TYz6b/UxuPuHk0h6y52HksR4TMHg9 ROwX96Tc2xwh7oVG7i/4rwPqek693EFnOuBPV9qtSRchs+6Ahsp/sda91TD8n5p40iv4 w/QA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mwsOXXbcfC9fPjVivpon0nxUnv1iu8M1E4VwDE036so=; b=TybRRweZYnBo3EHQ+fTSnSMp/Ljv/3EO92z7H8YLgEejrSlEsQjlC0CJMj+mwykb1X 1P9TVpxW/T7Rj7Hmwdi2L9moBVXwt0NB2aA5zWN8OwoNdmbhux2CazAm4aF+jB6lnGbP E2hOEIgOMd/NcuC9jA+fUMecMa3LEBhOfEP8GaZZAW8D1d8lP/XsE/PSzOI67KbJhnHz r1Pz4bmDjU/GMjgCzGVgjwoBByhnzF1U6j7sWxc6K1d4BoInqzPcCW6n9dm4kXCjxxU2 Vg7QVnhPsct2Z0VHBIuPY1sPJ1GibzWXC6ItgA9t7yC/csqiXmhn4oaYokbFsjkOJ0h5 GWmA== X-Gm-Message-State: ACrzQf3qukUHU7ZXhw0flxC42rDZdewHhU1Y8CtTnVSj0nbnNwwc2UyK KNIAlBG3yp5pm5xIGDeuG/u8DMRUAHTcEHLUxj0= X-Received: by 2002:a63:f801:0:b0:46f:fe3f:ea87 with SMTP id n1-20020a63f801000000b0046ffe3fea87mr26347950pgh.10.1667820728974; Mon, 07 Nov 2022 03:32:08 -0800 (PST) MIME-Version: 1.0 References: <20221105194943.826847-1-robimarko@gmail.com> <20221107112756.GB2220@thinkpad> In-Reply-To: <20221107112756.GB2220@thinkpad> From: Robert Marko Date: Mon, 7 Nov 2022 12:31:57 +0100 Message-ID: Subject: Re: [PATCH 1/2] bus: mhi: core: add SBL state callback To: Manivannan Sadhasivam Cc: kvalo@kernel.org, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, gregkh@linuxfoundation.org, elder@linaro.org, hemantk@codeaurora.org, quic_jhugo@quicinc.com, quic_qianyu@quicinc.com, bbhatt@codeaurora.org, mhi@lists.linux.dev, linux-arm-msm@vger.kernel.org, ath11k@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, ansuelsmth@gmail.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Mon, 7 Nov 2022 at 12:28, Manivannan Sadhasivam wrote: > > On Sat, Nov 05, 2022 at 08:49:42PM +0100, Robert Marko wrote: > > Add support for SBL state callback in MHI core. > > > > It is required for ath11k MHI devices in order to be able to set QRTR > > instance ID in the SBL state so that QRTR instance ID-s dont conflict i= n > > case of multiple PCI/MHI cards or AHB + PCI/MHI card. > > Setting QRTR instance ID is only possible in SBL state and there is > > currently no way to ensure that we are in that state, so provide a > > callback that the controller can trigger off. > > > > Where can I find the corresponding ath11k patch that makes use of this > callback? Hi Mani, ath11k patch was sent as part of the same series to everybody included in this patch as well under the name of "[PATCH 2/2] wifi: ath11k: use unique QRTR instance ID". If you did not receive it due to some kind of error, its available at the linux-wireless patchwork[1] or ath11k mailing list[2]. [1] https://patchwork.kernel.org/project/linux-wireless/patch/2022110519494= 3.826847-2-robimarko@gmail.com/ [2] http://lists.infradead.org/pipermail/ath11k/2022-November/003678.html Regards, Robert > > Thanks, > Mani > > > Signed-off-by: Robert Marko > > --- > > drivers/bus/mhi/host/main.c | 1 + > > include/linux/mhi.h | 2 ++ > > 2 files changed, 3 insertions(+) > > > > diff --git a/drivers/bus/mhi/host/main.c b/drivers/bus/mhi/host/main.c > > index df0fbfee7b78..8b03dd1f0cb8 100644 > > --- a/drivers/bus/mhi/host/main.c > > +++ b/drivers/bus/mhi/host/main.c > > @@ -900,6 +900,7 @@ int mhi_process_ctrl_ev_ring(struct mhi_controller = *mhi_cntrl, > > switch (event) { > > case MHI_EE_SBL: > > st =3D DEV_ST_TRANSITION_SBL; > > + mhi_cntrl->status_cb(mhi_cntrl, MHI_CB_EE= _SBL_MODE); > > break; > > case MHI_EE_WFW: > > case MHI_EE_AMSS: > > diff --git a/include/linux/mhi.h b/include/linux/mhi.h > > index a5441ad33c74..beffe102dd19 100644 > > --- a/include/linux/mhi.h > > +++ b/include/linux/mhi.h > > @@ -34,6 +34,7 @@ struct mhi_buf_info; > > * @MHI_CB_SYS_ERROR: MHI device entered error state (may recover) > > * @MHI_CB_FATAL_ERROR: MHI device entered fatal error state > > * @MHI_CB_BW_REQ: Received a bandwidth switch request from device > > + * @MHI_CB_EE_SBL_MODE: MHI device entered SBL mode > > */ > > enum mhi_callback { > > MHI_CB_IDLE, > > @@ -45,6 +46,7 @@ enum mhi_callback { > > MHI_CB_SYS_ERROR, > > MHI_CB_FATAL_ERROR, > > MHI_CB_BW_REQ, > > + MHI_CB_EE_SBL_MODE, > > }; > > > > /** > > -- > > 2.38.1 > > > > -- > =E0=AE=AE=E0=AE=A3=E0=AE=BF=E0=AE=B5=E0=AE=A3=E0=AF=8D=E0=AE=A3=E0=AE=A9= =E0=AF=8D =E0=AE=9A=E0=AE=A4=E0=AE=BE=E0=AE=9A=E0=AE=BF=E0=AE=B5=E0=AE=AE= =E0=AF=8D