Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp4094821pxk; Tue, 29 Sep 2020 14:18:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx0SwL72X0coMaLggRu3ov5Nqx0sRLAdo51d7xBQbhcsxutLYB7WUagQwADoOv+MPi7GBtx X-Received: by 2002:a50:a693:: with SMTP id e19mr5265282edc.205.1601414300979; Tue, 29 Sep 2020 14:18:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601414300; cv=none; d=google.com; s=arc-20160816; b=QAAU0Ud2uJSVag/WFyMNAltODeYTXI/nwzLDHplwwkaT2MiwCe2GAyJC3ksiZexf2B PHJeOV2BM7JxtHeIBhbx7FKmQ706vMFJzJoqxGBtP67WORQK5K6pggJnupcseHpBePw0 txl2zTNQircoRbTPYzJvy0CQfoizmSK2w5Jm7l6aadsWZniPkKqIMk9vkifCRW+4DX3h 8vJWcjUUXCj0MVcApBwuKdfK6TNpGYNLdJIJ1AFx5ZI7AYRSoOWPg9csQFt55JM9gi2g Eol+LO5vCkAuKT+J7TqiNcagzIcHI3Ti3KZs5vbo8lwI6+2y3etaiCKc5qGAR4J8UMsS btUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:references:cc :to:from:subject:dkim-signature; bh=nTqRPB3v1tkiwN7Cg1ds4smhECywcgz+mhK9iqkYF2I=; b=DZihwgzFuIL4Xbpnp1umcDvrS68nZDK7kwWQ5FGaNgFPrvBMZRsq4OEQPRfBulAHo2 u4tywlSfxXlYcM7Fu2Jafq/HpPE/DGLQERllYepqRVQMueSJYcLS4Hv4KcHyoORjo8Yj oBVI5VX5tVm3d+nEy8aoIB4+ev1pR7RB56A6IOStaCSsfUf61tkoKnJGxRzqK+9zQqul GmBlJVno/QCP5o/X5llUy8Llo4w3g0ABrQg7ywtYHCGIGHnvZX9fEGNFHaBg6aExgXDp vR1knmDuQanpCnPwQiLlqrXg8J7Gc5M3Nt+/vdQ+rnU0cdCiQG/xkWwwh892HbD1jVqn 9tlA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ZVcgqr1e; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id lt17si3465755ejb.56.2020.09.29.14.17.57; Tue, 29 Sep 2020 14:18:20 -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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=ZVcgqr1e; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729140AbgI2VQy (ORCPT + 99 others); Tue, 29 Sep 2020 17:16:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43610 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726643AbgI2VQy (ORCPT ); Tue, 29 Sep 2020 17:16:54 -0400 Received: from mail-lf1-x142.google.com (mail-lf1-x142.google.com [IPv6:2a00:1450:4864:20::142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A14B1C061755; Tue, 29 Sep 2020 14:16:53 -0700 (PDT) Received: by mail-lf1-x142.google.com with SMTP id z19so7269925lfr.4; Tue, 29 Sep 2020 14:16:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:from:to:cc:references:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=nTqRPB3v1tkiwN7Cg1ds4smhECywcgz+mhK9iqkYF2I=; b=ZVcgqr1eJH2THDTRaxDQl1RhHaVCg3p3KCfxr/2U52C+17STyk7+SfAHRsDwfd6N1M LA/DhkvC1Dl1Dam0E0C6Qbwem0AsqPhk/exsjZirWA6X/6iSv8pwYfBnJfoqtsCCwUtA bSfPLpIWtuWKsJQhiDVuhhPPEl8TZvl+JtKz8mbfiYyZKI+fvXDpPu7sjXGSmxbqEOYJ gH7c2eqvhHK7laPgxpRW4IdKhftVfiQarhXwcz2RCFQJzLFhuJy3QJcRpd9dxSXtUmrV scQFaoeO1+D/xt7pjV7cXn3X0a+mDZCCJnDKDNSp1471mWqNh28y87m4RbAn6oExcDHT LhzA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:from:to:cc:references:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=nTqRPB3v1tkiwN7Cg1ds4smhECywcgz+mhK9iqkYF2I=; b=kZvapGl2zZ846LCE1W5yWYdt2xSbu60QAJGzJINLbmiQYJA/mqUoCjYV6W5VCSAmdh EbYHA424FCN61+M5mJQYJdqXJ4HvPRiBdcQS5igsJ18knza5VliE7YDkq/XKRKY3Jpiy KVYJMzy7Ilqz0OXBlShTD0+j+9reChtlKTz4Wcd3aRmY492m0+go1Yl6DtmffFnV6KRM /psJbLABOQQqJH1bPiu2KIAk9TZ8n7ISFRDWW5OSQOKJHiDEylqRCa3Pb+q4/ZS0selF 8PQc97qSxn/BldWnQ+BQwHyplaIOSw+CxkGX4a9yeQGr0OgJEsdfKgm57lp01my4ybIX t+GA== X-Gm-Message-State: AOAM533JUxkAicEup68DH/r1xxohZ4Kn6OxVuCWiS6JLrqE/d2xkyERv Uolabit+2m3bE2k25PJmXOwxl9umq6E= X-Received: by 2002:ac2:4433:: with SMTP id w19mr2079597lfl.548.1601414211794; Tue, 29 Sep 2020 14:16:51 -0700 (PDT) Received: from [192.168.2.145] (109-252-170-211.dynamic.spd-mgts.ru. [109.252.170.211]) by smtp.googlemail.com with ESMTPSA id m203sm3387483lfd.195.2020.09.29.14.16.50 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 29 Sep 2020 14:16:51 -0700 (PDT) Subject: Re: [PATCH v8 23/32] i2c: tegra: Factor out packet header setup from tegra_i2c_xfer_msg() From: Dmitry Osipenko To: Thierry Reding , Jonathan Hunter , Laxman Dewangan , Wolfram Sang , =?UTF-8?B?TWljaGHFgiBNaXJvc8WCYXc=?= , Andy Shevchenko Cc: linux-i2c@vger.kernel.org, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org References: <20200922225155.10798-1-digetx@gmail.com> <20200922225155.10798-24-digetx@gmail.com> Message-ID: <2efb1256-dae8-34d1-1175-e70059b7cdec@gmail.com> Date: Wed, 30 Sep 2020 00:16:50 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <20200922225155.10798-24-digetx@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ... > + tegra_i2c_push_packet_header(i2c_dev, msg, end_state); > > if (!i2c_dev->msg_read) { > if (i2c_dev->is_curr_dma_xfer) { > - memcpy(buffer, msg->buf, msg->len); > + memcpy(i2c_dev->dma_buf, msg->buf, msg->len); I spotted that this now shall be i2c_dev->dma_buf + I2C_PACKET_HEADER_SIZE. I also checked that the enforced DMA mode doesn't work using v8 and it works fine after the fix. Will make v9 shortly.