Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5522231ybv; Mon, 17 Feb 2020 22:21:21 -0800 (PST) X-Google-Smtp-Source: APXvYqxvhihEjdDKFDwNcH6utKCU/h0GmMrcPX35dBdEPb/8I+yUWEI11W4kBQUuPdzuoXROfzw/ X-Received: by 2002:aca:5295:: with SMTP id g143mr299689oib.25.1582006881246; Mon, 17 Feb 2020 22:21:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582006881; cv=none; d=google.com; s=arc-20160816; b=RKyVKNqLyUxsqa4mAjNx0PgysnWaGNK01FrH7ZHptX/Oo/a7PTdVGeSugYUYBGHM2d vUc10RjOP2UBKJbBaTT8ri2TDCrseEn7mvEefdzPk+3vv7GDJ3Tfe9AHH2pD7AaBLyuI ZjViBJs/5qLbyvB5N7kfgF7608P8z7w4gFqLmImf+alPCgBxFfGfjh2wita2TNsSQv1V gcGxdQYeG/sI+YDx3Ha5sZ0eHyDnwSq00FeutBXLXNDeTsTRZ3i7tyn6JgKJVbusuNru AFkhTPbWiiDmBuQQsD9abL2HRXyEiWaxR+0kAwb9vOiIhFqSqi7vKrMX159WIVaJk4Wk qaDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=h/IV/F0QbpAv18eUQXLvrag9HkoF0+s99aXrVmJuJcM=; b=TJhpfHx8qy1fmGOd3wB+M0WfVQsKXGTK2dphMgg9Bx+6cGBmA+SbzEdymLQS0szgjm DnpiNrDjUEhp6fZavI4xPh7Bf01HhyXYlBKJ8ln5CVDZ+T0khEekf8e1S6v70ur3P0ps sUzB4vLZb+p3uohkIr2r7jkkcYEBUw7eFg2+Rqdktpmu2UAVtsPFa1ywUsn3hv335ORb GduXel4gYljIat7mz0EujozLswO53h5sxygycY41nDzpWQlj4ZxPPzvZvKVRpTP2BwpC 4t2QdykDaf7tpJhwUCEISHDr0mZKwWJKe253B0mYFCZiiJWw2fMtmOch/G9g+XavvLyC ik/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@kemnade.info header.s=20180802 header.b=GyI7KtpT; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i15si1319519otk.120.2020.02.17.22.21.09; Mon, 17 Feb 2020 22:21:21 -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=fail header.i=@kemnade.info header.s=20180802 header.b=GyI7KtpT; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726327AbgBRGU5 (ORCPT + 99 others); Tue, 18 Feb 2020 01:20:57 -0500 Received: from mail.andi.de1.cc ([85.214.55.253]:58056 "EHLO mail.andi.de1.cc" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726186AbgBRGUu (ORCPT ); Tue, 18 Feb 2020 01:20:50 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=kemnade.info; s=20180802; h=Content-Transfer-Encoding:MIME-Version: Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=h/IV/F0QbpAv18eUQXLvrag9HkoF0+s99aXrVmJuJcM=; b=GyI7KtpTnFwbMICTIDc1ZNYBqT hWpZ05DyIzCXTYGv1Gc0iIV7ClCJyNHWuEHhJ5xl9mLGhIW8Y23IBi8cCV4MsPPKn0CxmGwsm2ahy RyS4evkGeqZf3BhW4tjFaoSBiy51xrpR1cYXgzySX3Su3wJF5+Spv+edv0xrku5Ez6nA=; Received: from [77.247.85.102] (helo=localhost) by mail.andi.de1.cc with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1j3wFN-0000ov-Sx; Tue, 18 Feb 2020 07:20:42 +0100 Received: from andi by localhost with local (Exim 4.92) (envelope-from ) id 1j3wEr-0005rD-VQ; Tue, 18 Feb 2020 07:20:09 +0100 From: Andreas Kemnade To: knaack.h@gmx.de, lars@metafoo.de, pmeerw@pmeerw.net, lee.jones@linaro.org, b.galvani@gmail.com, linus.walleij@linaro.org, linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org, phh@phh.me, stefan@agner.ch, letux-kernel@openphoenux.org, martin.blumenstingl@googlemail.com, jic23@kernel.org Cc: Andreas Kemnade Subject: [PATCH v3 0/4] mfd: rn5t618: add ADC support Date: Tue, 18 Feb 2020 07:17:21 +0100 Message-Id: <20200218061725.22420-1-andreas@kemnade.info> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -1.0 (-) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org mfd: rn5t618: add ADC support This series adds support for the ADC in the RN5T618/RC5T619. It depends on the IRQ support added in the RTC support series here: https://lore.kernel.org/lkml/20191220122416.31881-1-andreas@kemnade.info/ I tested the driver only with the RC5T619 but it should work with the with the RN5T618 as well based on these facts: - The corresponding register definitions originally went into the kernel for the RN5T618 - Public datasheet sections about the ADC look same. - Out-of-tree code for these chips look same regarding to ADC But due to missing hardware I cannot test the patches 2/3 and 3/3 which add support for the RN5T618 ADC. I marked these untested patches as RFC, and IMHO they require a Tested-By. Feel free to ignore them if the whole series would be delayed just because of missing Tested-By for those. Changes in v3: - re-included former 2/5 of these patches, since it was not applied Changes in v2: - got an "Applied, thanks" message for the first two, so I do not include them anymore - some cleanups for the ADC driver itself Andreas Kemnade (4): mfd: rn5t618: add ADC subdevice for RC5T619 iio: adc: rn5t618: Add ADC driver for RN5T618/RC5T619 mfd: rn5t618: add IRQ definitions for RN5T618 mfd: rn5t618: add ADC subdevice for RN5T618 drivers/iio/adc/Kconfig | 10 ++ drivers/iio/adc/Makefile | 1 + drivers/iio/adc/rn5t618-adc.c | 258 ++++++++++++++++++++++++++++++++++ drivers/mfd/rn5t618.c | 48 ++++++- 4 files changed, 315 insertions(+), 2 deletions(-) create mode 100644 drivers/iio/adc/rn5t618-adc.c -- 2.20.1