Received: by 2002:a25:23cc:0:0:0:0:0 with SMTP id j195csp338254ybj; Mon, 4 May 2020 22:54:33 -0700 (PDT) X-Google-Smtp-Source: APiQypJwhrMMbwkQ0IkdUtYQ1EkhVqDK9WDAEBdswO1FFeFoMNmtgtnyI7uCqP9+TC3WZQc6d8+l X-Received: by 2002:a05:6402:1618:: with SMTP id f24mr1149382edv.330.1588658073267; Mon, 04 May 2020 22:54:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588658073; cv=none; d=google.com; s=arc-20160816; b=dgLt9+H05472JyoUSKVsaY+IuFDn8gsop2wKQsc8MJuOielhK9as51Pq+DYqlP9XSM IKIPRyihzEGc7OClxnBHeuBSI4PhfuszLHCCmF6WKV47bhzbU5UGbYsmWTLTcvTUsMu6 cW67oAa3b/E1Nktg5Usre5VeLGR6pazLwg7Ab06Uyu/whtdvaoPqZYX4MqUVRDMEKCZa TlqiDwXg0F5AMTqnPawOed6PMGkbLBS1PE4NJqiJtDquaqamzas0hONKJnbThh6BUOpg IQBiuz7DNPXAjcvZntSQ/8gPjgSFKGay5Ebi61ZpD2SZ1KEXgM190fCwhRPJ/61N1g61 TZcg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=mYm1aPGrb5Sqtq3pKPGZgvor7iTnX4e9UCvFT95c2cI=; b=yEfZZNg/Tdo+1BrwXorkbk/KQLRbBu8VL9dIGjS9aUoJNJ0BukItHfqauO1ISbIXIX dyZqBLjXrkF2sV2NZ4V+l0Czt0bTM30/zIxv2cV2MfY04+4Pspr7dWzDvrRvCh7C0Ek+ 0GFebOD1vZbjV8dtYti9sNf6kjpmzIXNqdtTcoR5qZkD9eY3S3NdHfDO9KPZ+j5SjU91 9OvckQVf7FLW2UbAjgPW12C9BP6KPZRHYCtTvp3jLS4ba7yHQWeBUaBr4+2Vj7KsEsJx NVEQQpYPHkUhToSuydCfqNwpBQwEsWn+IJqBmbUhUA3eVbHMcIycg96MrbVi+9kgrHmj aslA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@st.com header.s=STMicroelectronics header.b=pPfbSQIn; 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=NONE dis=NONE) header.from=st.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e23si606188edq.517.2020.05.04.22.54.10; Mon, 04 May 2020 22:54:33 -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=@st.com header.s=STMicroelectronics header.b=pPfbSQIn; 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=NONE dis=NONE) header.from=st.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728248AbgEEFwp (ORCPT + 99 others); Tue, 5 May 2020 01:52:45 -0400 Received: from mx08-00178001.pphosted.com ([91.207.212.93]:31168 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725320AbgEEFwj (ORCPT ); Tue, 5 May 2020 01:52:39 -0400 Received: from pps.filterd (m0046660.ppops.net [127.0.0.1]) by mx07-00178001.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 0455lAIt026985; Tue, 5 May 2020 07:52:20 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=st.com; h=from : to : cc : subject : date : message-id : mime-version : content-type; s=STMicroelectronics; bh=mYm1aPGrb5Sqtq3pKPGZgvor7iTnX4e9UCvFT95c2cI=; b=pPfbSQIn3uVS+P4qi6urtq5nSV+ua/tIE9mhET/ZUw5Uas3suoH+HSTtZJXfEY/USViN YhOEhBaO9PXiUnyfhgC+Pq6w3QN412EJgXJApEyU06dybvmtOWZ9i2UmFH8TjY2SmLc9 hLNdhXxZZaCIfUmxep9AYNbaJ2ffRBJHxvRLzClz1ZNd0wRra6FKEu317HTwC7WkLQRT sMnu8iRwcl7aUaqqZqj6IewvKYMbuG7D+9CTSy7/6QZhMTGh3fow9oy4NtX7kGM9b1Kj QTAxgqTmbhvn9snOfYXUTm7g6F6Lj5XZPw5R7dTk6VYWZB6W2mIG9XkasspJhL81H4MX Rg== Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 30rx08e845-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 05 May 2020 07:52:20 +0200 Received: from euls16034.sgp.st.com (euls16034.sgp.st.com [10.75.44.20]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 31E3D10002A; Tue, 5 May 2020 07:52:20 +0200 (CEST) Received: from Webmail-eu.st.com (sfhdag3node2.st.com [10.75.127.8]) by euls16034.sgp.st.com (STMicroelectronics) with ESMTP id 00B7621CA80; Tue, 5 May 2020 07:52:19 +0200 (CEST) Received: from localhost (10.75.127.51) by SFHDAG3NODE2.st.com (10.75.127.8) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Tue, 5 May 2020 07:52:19 +0200 From: Alain Volmat To: , CC: , , , , , , , , , , Subject: [PATCH 0/4] stm32-f7: Addition of SMBus Alert / Host-notify features Date: Tue, 5 May 2020 07:51:07 +0200 Message-ID: <1588657871-14747-1-git-send-email-alain.volmat@st.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.75.127.51] X-ClientProxiedBy: SFHDAG2NODE1.st.com (10.75.127.4) To SFHDAG3NODE2.st.com (10.75.127.8) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.138,18.0.676 definitions=2020-05-05_02:2020-05-04,2020-05-05 signatures=0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This serie adds SMBus Alert and SMBus Host-Notify features for the i2c-stm32f7. For that purpore, I propose two enhancements to the i2c framework. 1. Addition of host-notify client handling as part of the i2c-core-smbus so that any other i2c adapter can benefit from it, even those without specific HW support for Host-Notify. 2. Addition of two i2c_algorithm reg_client and unreg_client allowing adapter to take some actions when a client is being probed. Indeed, in case of host-notify, the binding/flag is related to the client and the adapter might want to enable the host-notify feature only when there is a client requesting the host-notify. (Since SMBus host-notify is using the address 0x08 which is a valid I2C address, keeping host-notify always enabled would make the 0x08 I2C slave address non usable). Alain Volmat (4): i2c: smbus: add core function handling SMBus host-notify i2c: addition of client reg/unreg callbacks dt-bindings: i2c-stm32: add SMBus Alert bindings i2c: stm32f7: Add SMBus-specific protocols support .../devicetree/bindings/i2c/st,stm32-i2c.yaml | 4 + drivers/i2c/busses/Kconfig | 1 + drivers/i2c/busses/i2c-stm32f7.c | 198 +++++++++++++++++- drivers/i2c/i2c-core-base.c | 11 + drivers/i2c/i2c-core-smbus.c | 105 ++++++++++ include/linux/i2c-smbus.h | 2 + include/linux/i2c.h | 6 + 7 files changed, 317 insertions(+), 10 deletions(-) -- 2.17.1