Received: by 2002:ac0:aed5:0:0:0:0:0 with SMTP id t21csp1258917imb; Sat, 2 Mar 2019 08:23:22 -0800 (PST) X-Google-Smtp-Source: APXvYqwHz9oEYkLkrFAqWiKZTYsH8bnOAaD1vxCAnXA3ddihKFKDHoDLFJdgs7DSffPn4vfu/CHr X-Received: by 2002:a63:54c:: with SMTP id 73mr10250128pgf.295.1551543802559; Sat, 02 Mar 2019 08:23:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551543802; cv=none; d=google.com; s=arc-20160816; b=zbm27tsc97OQQwjKW9pZjUrDFFauV1LkhMZXeOGa8RcATkDLLAj9vSntFomDG5MlkV ju42SG3RLDDZLZ67bKSjEM5ZXsUjLT/GlqXh/6RLQz4IPg8Dpx5ZvvFOn0rCCJeQGFW7 L6dM+ML6Z8wOppDHFbUxIWl3NonI/OH5W24toTgr2ZL7y4durVgkjRpOd8bFYOtiF6hW DrR8So6Wbm2qLEt7Fp7XNojYh0yyXLeWotGpnCrZ7GW9nmFZH8uP+1yc6QnsiJmUGx4a pxGXn8ZULB/B5Ddz5oA6TD3PymVVZwKaknvNc5JIU5IIqlpg/tPsApfNE5qQC2Z0YZMB FLGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=ntKPzUe7j7kGqDRoDP5v3yJz1xED3KNbkmElCBRICcw=; b=ng2H0HXN7ObXIneDwK3MuS26itJmUBXCRjiO82xaMJbP9f4vcQz+EImwto74uwHoHO wEapcopMgWPCz0Bjo1rh5/+jry1YqnyEeCqZR7kgcbZxtVxsnU1EcXC41e0HTnQBt3Cy 6iNT1YPeRKo8Pn75tZgaELfzm6sVSFrSjo/H2lV24F44OdDUxPEzUIXeP0XHOMVJ+F3H IkCX0pnaWTwCLmVW+IGx5SsoJ+frg/gL3vd46zTj+Vt0bDETVx4tVA3i3bYDXfbTdTxj creRevmMJ8MVgqdXkXut6V+s0trUNWpWHm9BhAyQNX+akZnIXg2tszHjYyfRveF6WSG2 KI2A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=tkup03gw; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id h85si918201pfj.88.2019.03.02.08.22.54; Sat, 02 Mar 2019 08:23:22 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=tkup03gw; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1726646AbfCBQWW (ORCPT + 99 others); Sat, 2 Mar 2019 11:22:22 -0500 Received: from mail-pg1-f194.google.com ([209.85.215.194]:36883 "EHLO mail-pg1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726246AbfCBQWV (ORCPT ); Sat, 2 Mar 2019 11:22:21 -0500 Received: by mail-pg1-f194.google.com with SMTP id q206so473625pgq.4; Sat, 02 Mar 2019 08:22:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ntKPzUe7j7kGqDRoDP5v3yJz1xED3KNbkmElCBRICcw=; b=tkup03gwWhg7alEXd9dBQr/8qeu4UNdPOsEH9mupvGzV2tqGvse0Rh4Qy9/9VUAGLV ajx9bFdYJTLp8LgUBu1Z5RhgNhKMBJj6YEUNnNdY5doM9PwbwtY31zWOoPI1+Zj4jSAE /RJyRGeOgQg+866WfMk0e9fWAcSpDlOwB9ex/ssOJbIobEiQc3uS7moUcustjsCkUPp/ SuSfEkdLaCB6jnhaHLzqcjKxWbYBz5yHZ5F3qdn2FrdvyMOQwXC51aVLA/xZv/kxUo1E lgTVFK2tvQdNaQAKLfOj8Tm5eDCcN6F7kN0XcX9fE5R55+T5Ah3iNJnM8ZWXGs+/NzBB LRiA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ntKPzUe7j7kGqDRoDP5v3yJz1xED3KNbkmElCBRICcw=; b=StUwxakeDIHxRlcEOC+N54hzQjf0IOffcqBZuOXYnqidX6T72Ryo1IUrmPogYY6pZR wmWexECOqQluWlhG6zESj7zheeeQ08/u69jcFoAWpVlU6RpacN8abXOPkUXTAQtxrxsL 41PRPIfNNt2avunZlbA7rPP2PcVnRSUFBeE8P2/vHXehIFAjxqyhgf1aiAI/j+WYXI1e ja4+UP2PZwotcoA22/RdeXkNwJuOTMaF99Wfc8RDGq1hWZA4+y9/WBs1XJzpSqjdH9yd A7+7PvRT5g5wCV6Yik6o+WNWNlws6l/LwQU2F0+6X/t8baQRQ1wUgi70XAbQVnMY6yqE 9sTQ== X-Gm-Message-State: APjAAAUPZ/i9qXZxrDGsRGgOco/R7MCMe2PXlCOqkPnkPjRfog/ttra2 ysgFTvNTlMVZ+Ehtk/ZqCemHfD1rCjKb382SRiI= X-Received: by 2002:a62:5e41:: with SMTP id s62mr11253869pfb.232.1551543740539; Sat, 02 Mar 2019 08:22:20 -0800 (PST) MIME-Version: 1.0 References: <20190302134735.4393-1-wsa+renesas@sang-engineering.com> In-Reply-To: <20190302134735.4393-1-wsa+renesas@sang-engineering.com> From: Andy Shevchenko Date: Sat, 2 Mar 2019 18:22:08 +0200 Message-ID: Subject: Re: [RFC PATCH v2 0/7] i2c: core: introduce atomic transfers To: Wolfram Sang Cc: linux-i2c , Linux-Renesas , Linux Kernel Mailing List , linux-arm Mailing List , Keerthy , Peter Rosin , Tony Lindgren , Russell King , Andy Shevchenko , Stefan Lengfeld , Phil Reid , Tero Kristo , Linux OMAP Mailing List , linux-tegra@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Mar 2, 2019 at 3:49 PM Wolfram Sang wrote: > > So, finally, here is the second RFC for supporting I2C transfers in atomic > contexts (i.e. very late). This will need some text because I tried some things > on the way but had to discard them. However, I think it is important to have > that documented. > Sorry, no TLDR; text here - I think this topic deserves a few words ;) Thank you for this work! It was indeed interesting reading. And since your series is targetting some exiting use cases, I would drop as well academic variants of brain-damaged hw design, I think it worth to go. WRT patches, Reviewed-by: Andy Shevchenko for patches 1-2 and FWIW for patches 3-4. For the individual drivers I can't say much, code looks good, but I dunno if it's correct or not. > > Looking forward to comments, thanks! > > Wolfram > > > [1] http://patchwork.ozlabs.org/patch/1044789/ > > > Tero Kristo (1): > i2c: busses: omap: Add the master_xfer_irqless hook > > Wolfram Sang (6): > i2c: apply coding style for struct i2c_adapter > i2c: core: use I2C locking behaviour also for SMBUS > i2c: core: introduce callbacks for atomic transfers > i2c: demux: WIP: handle the new atomic callbacks > i2c: tegra-bpmp: convert to use new atomic callbacks > i2c: algo: bit: HACK! add atomic callback > > drivers/i2c/algos/i2c-algo-bit.c | 5 ++- > drivers/i2c/busses/i2c-omap.c | 79 +++++++++++++++++++++++++++++------ > drivers/i2c/busses/i2c-tegra-bpmp.c | 27 +++++++++--- > drivers/i2c/i2c-core-base.c | 17 ++++---- > drivers/i2c/i2c-core-smbus.c | 25 ++++++++--- > drivers/i2c/i2c-core.h | 15 +++++++ > drivers/i2c/muxes/i2c-demux-pinctrl.c | 3 ++ > include/linux/i2c.h | 38 +++++++++++------ > 8 files changed, 162 insertions(+), 47 deletions(-) > > -- > 2.11.0 > -- With Best Regards, Andy Shevchenko