Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp668484ybz; Wed, 15 Apr 2020 16:17:26 -0700 (PDT) X-Google-Smtp-Source: APiQypIxdcL+UF5f6ADmBe+V0VFYyBDLxWUKIMDhtLh8IG5zoezW5s3DVwTcr29O2qeiiH1VlpTI X-Received: by 2002:a17:906:3047:: with SMTP id d7mr7259761ejd.141.1586992646773; Wed, 15 Apr 2020 16:17:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586992646; cv=none; d=google.com; s=arc-20160816; b=OAYY67EBylmLrtGEO4ZlPERIBml2BPVSKxDBWTe/LVyprnQAC14yLNUBCCRPIqLsnZ FIP7myS6pgZ9HTOKkHPIM/ycEDhvmvblrzKFtaIO2o25pkhH2nkN0GypE1X4IzfLpz+2 jzTJG7F//pvTfbtJp4FsxaO5I+GgukDqa9as6cZUe+jyaMc1cK2ehP27a3ufFu23oCVz HJDKRRlnJvVDElop5bzKSwVcZK6emP1VxQQIqZY7W60AawKN11ch6bAOZ/qBTannOZDj +frmRUWX4pASRzLZIelXZlrCuODSmL5MHaUfwzId7IcJlAwvgddijmeEbQd3JOQR06FY LOdw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=K14etdO9h3OPDjIA66xxEkAx1W4CqqUV+QxnwFP3pPQ=; b=0dysx5eUzGVPaJnaz5ovdB543Et6kQogPKvCTv299Jt0guSHjj35D2T+2BrU2rKfb5 eLEk089In+qYjRWZagmqeJUONc3ps/aZGWr+NjSOro2wpmCksrLj+pyJ76kGV71Ud46E 4Lkra5//k9AhM7w2E0rCdP588cAOowpuY/SJy2ngeKvdGekvV5jtjvudy03q9+rNcU9q K8tXXbY7n5uCKpkyNgOB4fpqKnZsCYiBtbEzTINvvSjZJHzmvyLS1Cm5sxTNIYBkaVoV lmePqqWxBzezNPx6CGWpg2FFERtDUHp87Zs3h61L6Cb0OCHQ28sQAIopJsVH0ptCZiJA DNvw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l3si11136841edw.569.2020.04.15.16.17.03; Wed, 15 Apr 2020 16:17:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2409116AbgDOMaH (ORCPT + 99 others); Wed, 15 Apr 2020 08:30:07 -0400 Received: from sauhun.de ([88.99.104.3]:53654 "EHLO pokefinder.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S369431AbgDOM3u (ORCPT ); Wed, 15 Apr 2020 08:29:50 -0400 Received: from localhost (p54B33507.dip0.t-ipconnect.de [84.179.53.7]) by pokefinder.org (Postfix) with ESMTPSA id 949342C1FF1; Wed, 15 Apr 2020 14:29:45 +0200 (CEST) Date: Wed, 15 Apr 2020 14:29:45 +0200 From: Wolfram Sang To: Rayagonda Kokatanur Cc: Ray Jui , Scott Branden , bcm-kernel-feedback-list@broadcom.com, Lori Hikichi , Shreesha Rajashekar , Nishka Dasgupta , linux-i2c@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v1 1/1] i2c: iproc: generate stop event for slave writes Message-ID: <20200415122945.GC910@ninjato> References: <20200322182019.32493-1-rayagonda.kokatanur@broadcom.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="96YOpH+ONegL0A3E" Content-Disposition: inline In-Reply-To: <20200322182019.32493-1-rayagonda.kokatanur@broadcom.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --96YOpH+ONegL0A3E Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Mar 22, 2020 at 11:50:19PM +0530, Rayagonda Kokatanur wrote: > When slave status is I2C_SLAVE_RX_END, generate I2C_SLAVE_STOP > event to i2c_client. >=20 > Fixes:=C2=A0c245d94ed106 ("i2c: iproc: Add multi byte read-write support = for slave mode") > Signed-off-by: Rayagonda Kokatanur Just to make sure: That means the HW has already detected a STOP condition on the bus? > --- > drivers/i2c/busses/i2c-bcm-iproc.c | 3 +++ > 1 file changed, 3 insertions(+) >=20 > diff --git a/drivers/i2c/busses/i2c-bcm-iproc.c b/drivers/i2c/busses/i2c-= bcm-iproc.c > index 30efb7913b2e..b58224b7ba79 100644 > --- a/drivers/i2c/busses/i2c-bcm-iproc.c > +++ b/drivers/i2c/busses/i2c-bcm-iproc.c > @@ -360,6 +360,9 @@ static bool bcm_iproc_i2c_slave_isr(struct bcm_iproc_= i2c_dev *iproc_i2c, > value =3D (u8)((val >> S_RX_DATA_SHIFT) & S_RX_DATA_MASK); > i2c_slave_event(iproc_i2c->slave, > I2C_SLAVE_WRITE_RECEIVED, &value); > + if (rx_status =3D=3D I2C_SLAVE_RX_END) > + i2c_slave_event(iproc_i2c->slave, > + I2C_SLAVE_STOP, &value); > } > } else if (status & BIT(IS_S_TX_UNDERRUN_SHIFT)) { > /* Master read other than start */ > --=20 > 2.17.1 >=20 --96YOpH+ONegL0A3E Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEOZGx6rniZ1Gk92RdFA3kzBSgKbYFAl6W/jUACgkQFA3kzBSg Kba56w//YyHFH3d77V7+5og30eKP1+eGDNLfHEL29jHAg9fqHDj+PlN8Z6kWxoir 2w/sI1a0Yj3e/G1q3G2bL7gWErqYjOMTHP8gYVJQSdNoFTMF3i1ynawW6x7aAXh6 HOLy/0ijpt52+YGlFvfwDdtzYf1lc6t5nBiqp3OiK7PKLWS6Oj88SjtImTwIFpZD yW3RdHndNZ7dj1nG+Ny+nVIlLRjPBPX415uKOgpcw759SGezT07llFsD65sK9c/r hWWHgKLq+l9bzFd3LQTF9WwqHyUzx8RTpiJ0U6hwh9PPTcRwuuomynDUdS4R0EeA PTYPmPrxpI6psoTJFAEKD3VTYS/QymiatT+TKmvZZXiGTStG3zIK2THaLPIPV93U UIwRD1DOPeSPX/EzBuZ7D31EYhjfmsJzpbIPgryIj4AFS567yrm7lwWMVlUwvQ5A GGyPrPDHraPDRibrDts+i3YXXOZrIrHJ6OVK25xoz3HcRYULe7Ik5t2YocwmHSHa ymjlay9LXDG0fTqjmo7KvAZ9Iv992jKH7an2n1m+TEWNZ6yVqQvJ304NHoDmbydO 05SgO8qnX7eAeGiNKls7H8J8+3uY3cEMiOLdQlccWpUZEP6fCN0fkFlR+oop2IgJ EKuHtdrx8QEMYgiRI8OuEqwINsqawezG89uWHCCSENvhh9Hu73s= =PQOf -----END PGP SIGNATURE----- --96YOpH+ONegL0A3E--