Received: by 2002:a05:7412:f690:b0:e2:908c:2ebd with SMTP id ej16csp1037690rdb; Fri, 20 Oct 2023 06:56:20 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFCWqE/gZJISjoE1CyrzHKHvwGVjX4SkHmevBheWRnrbPUxBcS59QTDvv4uACBelwho9Igt X-Received: by 2002:a17:902:f685:b0:1c9:bca2:d653 with SMTP id l5-20020a170902f68500b001c9bca2d653mr1853104plg.11.1697810179656; Fri, 20 Oct 2023 06:56:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697810179; cv=none; d=google.com; s=arc-20160816; b=NbfvH12w3HdawifYs0SESFRFxQsNBrEOgC3BfYVwW1TaIscU02buw8cL0LGj56ot4N pnSRwy5LrvFAr8vM+pHElUPlX0P+fvSp7abOUSqfyGoJSDN+w4s8umikVILnPBlmITrM iEemY2BPcomBan+XPvHizVTSZJVKAI0ZwzPrt9nifnpbUEDFLRCymL3pT1k2e+K2qAAv nNxtlFDhhxp5tmC4gXiCsFB5SrYg/78sACArZbMxUE6wpe3E+EswITnEMZ+UfbJpGG2C vOGGIWxCEC1EFiJLkAtMjgxj5hc25r63QJ20uVptmHI3r0ukqMjhrRZaEYJoWMnr0nXc jBQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:dkim-signature; bh=guw01RKGbn1f3hLQyDo30kntXr8E8ttJ8J7CZjAKzjs=; fh=2xI9wzEGy998P8XI6mhOllPkUHQsxCfN9aU+/WmuZw0=; b=QK6rWW/YLqsKLyW3n2UIAQhxk4hMsbWoylqClVopZpq9GDWVNMEYo3wr1UP4l7bLEp K2UzUjw1Ar9ql6+aokflp54dTacvZ43uvs6Nw+9k2buTMu4LD7voxzyVz5FXcp15V0Rx KELXyQNfTJqbE2xcAfQUwZdgJfO8Yz3oSImIHi5ksau7y1weN/8oJ1Y8Es4xN2X/X0sy b8ohLPy6LCqlUoH1JafVHoZ9GfZbRGoA188yLcWJM+G3g7AEGe8VLrOKekYIq3gifPkT bbxjKwkwAR3ugyb73YcPm4R8RFJMBos8h9K1Tjd+YGvAyreaySJSlDtDPE3mvuLqGAYb CkCA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=iAr0lMGu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id w4-20020a170902e88400b001c474ff2fdesi2013049plg.378.2023.10.20.06.56.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 20 Oct 2023 06:56:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=iAr0lMGu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id F1AA4806AFD9; Fri, 20 Oct 2023 06:56:16 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377419AbjJTN4K (ORCPT + 99 others); Fri, 20 Oct 2023 09:56:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39234 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377514AbjJTN4I (ORCPT ); Fri, 20 Oct 2023 09:56:08 -0400 Received: from relay1-d.mail.gandi.net (relay1-d.mail.gandi.net [IPv6:2001:4b98:dc4:8::221]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 404961A8 for ; Fri, 20 Oct 2023 06:56:06 -0700 (PDT) Received: by mail.gandi.net (Postfix) with ESMTPSA id D2F44240017; Fri, 20 Oct 2023 13:56:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1697810164; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=guw01RKGbn1f3hLQyDo30kntXr8E8ttJ8J7CZjAKzjs=; b=iAr0lMGu8lG5QiztzmvYFF7EeDTGk7e9deIr8sIygM2F03wozOgIGiI1DoxPx8aTtaoQrQ vQj0cte+G92WrfW2bba0M9XqksyCfSaq066ICISm66+OzOTimCLmNrX94ybnzwfQFuAsDA BaSQPVy2KSCZhyEVQgbhgfx/QMvd8Vxybkk1Huhvisek5eSEmgwGJ4YRew64YWuUKQ1Z/h IaobZza12XF0rPFnjtI4Yn46Paq8xIm4fG61Wqy0/qwwSjAK421P1H0DFf8bbmrRAEWTcR TwUlFvxG+TzbUj3KO3FnjkOxOCcpR4hmt6gj1dKdktqBER+rPr3iX5qnCDomvw== Date: Fri, 20 Oct 2023 15:56:03 +0200 From: Miquel Raynal To: Frank Li Cc: alexandre.belloni@bootlin.com, conor.culhane@silvaco.com, imx@lists.linux.dev, joe@perches.com, linux-i3c@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 2/6] i3c: master: svc: fix wrong data return when IBI happen during start frame Message-ID: <20231020155603.52cc7206@xps-13> In-Reply-To: <20231019222725.3598022-3-Frank.Li@nxp.com> References: <20231019222725.3598022-1-Frank.Li@nxp.com> <20231019222725.3598022-3-Frank.Li@nxp.com> Organization: Bootlin X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-GND-Sasl: miquel.raynal@bootlin.com X-Spam-Status: No, score=1.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SORTED_RECIPS,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Fri, 20 Oct 2023 06:56:17 -0700 (PDT) X-Spam-Level: * Hi Frank, Frank.Li@nxp.com wrote on Thu, 19 Oct 2023 18:27:21 -0400: > =E2=94=8C=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=90 = =E2=94=8F=E2=94=80=E2=94=80=E2=94=90 =E2=94=8F=E2=94=80=E2=94=80=E2=94=90 = =E2=94=8F=E2=94=80=E2=94=80=E2=94=90 =E2=94=8F=E2=94=80=E2=94=80=E2=94=90= =E2=94=8F=E2=94=80=E2=94=80=E2=94=90 =E2=94=8F=E2=94=80=E2=94=80=E2=94= =90 =E2=94=8F=E2=94=80=E2=94=80=E2=94=90 =E2=94=8F=E2=94=80=E2=94=80=E2= =94=90 =E2=94=8C=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80 > SCL: =E2=94=98 =E2=94=94=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80= =E2=94=9B =E2=94=94=E2=94=80=E2=94=80=E2=94=9B =E2=94=94=E2=94=80=E2=94= =80=E2=94=9B =E2=94=94=E2=94=80=E2=94=80=E2=94=9B =E2=94=94=E2=94=80=E2= =94=80=E2=94=9B =E2=94=94=E2=94=80=E2=94=80=E2=94=9B =E2=94=94=E2=94=80= =E2=94=80=E2=94=9B =E2=94=94=E2=94=80=E2=94=80=E2=94=9B =E2=94=94=E2=94= =80=E2=94=80=E2=94=98 > =E2=94=80=E2=94=80=E2=94=80=E2=94=90 =E2=94=8C= =E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=90 =E2=94=8C=E2=94= =80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=90 =E2=94=8C=E2=94=80=E2= =94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94= =80=E2=94=80=E2=94=90 > SDA: =E2=94=94=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80= =E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2= =94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94= =80=E2=94=98 =E2=94=94=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2= =94=98 =E2=94=94=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=98 = =E2=94=94=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80 > xxx=E2=95=B1 =E2=95=B2=E2=95=B1 = =E2=95=B2=E2=95=B1 =E2=95=B2=E2=95=B1 =E2=95=B2=E2=95=B1 =E2= =95=B2 > : xxx=E2=95=B2IBI =E2=95=B1=E2=95=B2 Addr(0x0a) = =E2=95=B1=E2=95=B2 RW =E2=95=B1=E2=95=B2NACK=E2=95=B1=E2=95=B2 S =E2= =95=B1 >=20 > If an In-Band Interrupt (IBI) occurs and IBI work thread is not immediate= ly > scheduled, When svc_i3c_master_priv_xfers() initiates the I3C transfer and nit: when > attempts to send address 0x7e, the target interprets it as an > IBI handler and returns the target address 0x0a. >=20 > However, svc_i3c_master_priv_xfers() does not handle this case and procee= ds > with other transfers, resulting in incorrect data being returned. >=20 > Add IBIWON check in svc_i3c_master_xfer(). In case this situation occurs, > return a failure to the driver. >=20 > Fixes: dd3c52846d59 ("i3c: master: svc: Add Silvaco I3C master driver") > Cc: stable@vger.kernel.org > Reviewed-by: Miquel Raynal > Signed-off-by: Frank Li > --- Thanks, Miqu=C3=A8l