Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp149622ybp; Thu, 10 Oct 2019 15:33:22 -0700 (PDT) X-Google-Smtp-Source: APXvYqw0Av650qKAdNZAbIvdcgXqryhLZoMrIenlFYmh2EJ7xM/upTz3eO6XP4mPh0wPFB5PsT+O X-Received: by 2002:a50:d794:: with SMTP id w20mr10616025edi.258.1570746802286; Thu, 10 Oct 2019 15:33:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570746802; cv=none; d=google.com; s=arc-20160816; b=D/JY3b5vBSPtSqvOTBLr0092F9wnzXq6Nt5RO1mgCSw8IMErov5iF+YC4rkRsHrhqq qDni/L3+ZJcFalYrrkqHe6VaycF1Eho3Bs5P2YZbql/62cbzdlOAIOhSsh834oiu/kA+ OcxNRUp6jaM6NYxMfDMdunPSxQqswUmBbAoK17D37d8H7fvP2hpRZaJpcyp+szQne00c y2mXGuZqskJnK1W8ARfPy/YoQ30rYPxzjj4pAHlf0vQ2Fp8vgLfddM1ABsktYzRhRJ5M T8T3mh22HRTBQUUfzO9rxgVvt7FFXKTfJxgf3rlP9fvHq/gdfSVcb47hcq0q7HCGSTgS leqA== 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:dkim-signature; bh=+Rq5CoTE2b9CRlBzcczaJbDgzRspVbnY0jyqvQtXOLk=; b=UMHZc+TdJliHr2MwX2SXQv9AwPKIDM4zOtIC6wnKJoZWmvfZfOfP/G+aCgPg4yrj1z yJ0tDgRLy4YiXwqZr88yPmVH3OkfNVSZmvv8vbm4bHfLM3ukBM3RNUJeUiKK0+V0PUrw YIOdlAKKxVu6jW+bnEX2h+PQdoFkSqX2uQnh0uHB0iXsB4eiPDmErvVTnQ2aprEW5GmH a9s1FqOQssxGEQLHDzyIAzC7T9+kJ6/n6PDGosRoUFrl5qdYofFjMTlTRRTD/qZUJuSd 9lh9fua7NJVpoewreNWKXiOlOCs5AdfJNJgmpzzOsY7Vne2ntuu4XulI5+KzrfiMZEIa 77rw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=F0TXQ8XO; 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 m17si4276280ejn.237.2019.10.10.15.32.58; Thu, 10 Oct 2019 15:33:22 -0700 (PDT) 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=F0TXQ8XO; 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 S1726705AbfJJWaA (ORCPT + 99 others); Thu, 10 Oct 2019 18:30:00 -0400 Received: from mail-pl1-f195.google.com ([209.85.214.195]:33667 "EHLO mail-pl1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726166AbfJJWaA (ORCPT ); Thu, 10 Oct 2019 18:30:00 -0400 Received: by mail-pl1-f195.google.com with SMTP id d22so3497724pls.0; Thu, 10 Oct 2019 15:29:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=+Rq5CoTE2b9CRlBzcczaJbDgzRspVbnY0jyqvQtXOLk=; b=F0TXQ8XOSIFR3LftRORcvg6zYvgwuWjXU/vMmsRqPOPJbp6sOmBg8cT/WR2SO4+7n7 YmoVnNKu6N76Qt8+eZ88+5IydI3fL1sL0ojTwUSN0V50JeV8uqQE7Dpd3/jGR6CUj6dO padyHY857EaLkA/6Js8ckRa0uRB6sYPuUvwYdfEQcI/pXCscm9U/3CCyonjBjvAcXloj bC8Jcip2EX3aXc7IC7deq7maBynlc80ExvuSzBctzGoHDk6PoErrk56bK+n1e+HWpWHJ DOdQQ945k1KQEG58m1UH5ATl38u5n/seJtzaFJugIOauRY7IObLwvl+fBP2dm+XicFy+ RdRw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=+Rq5CoTE2b9CRlBzcczaJbDgzRspVbnY0jyqvQtXOLk=; b=GIPzJlX3i9xFUmGQM1NbNuALZfnvsLlN1MGFB/YZp9vP9ST4tTaQ2k0iWJXA++BOrb 2FtuG/jLx6o8svSKdnWmZ6QZdLU9yAhE5koNwH6kSqVmhKiBnKqyZ/3KeHHPah1bvv3T 8RkHhVGj1QfT2MM7MKKNPJInyOe/BbpdZzs8TcSURLSpGyLROH/jyW9PQFjQ0TEHq7HU SjeRYB8TABQ5qCP5IVjYI1eI3mTHTgtXUjbRf1mU/6JEfvd0vtYtE5I1lvQfIwZTouGG bbqtseOb6yaaf7S5ba2938kQuTV108Psfb4qRoq+b8+QhR6/5BlPxdYdoIon3IAorINO A/+A== X-Gm-Message-State: APjAAAWp9GOiXJrsrbVPI8GwUfJD3H0gSNlRfLbQI0jGM4Tv0WDYJHDP FPt7Tz4+hMmgCgZygjAqNns= X-Received: by 2002:a17:902:6b06:: with SMTP id o6mr12111867plk.154.1570746598284; Thu, 10 Oct 2019 15:29:58 -0700 (PDT) Received: from dtor-ws ([2620:15c:202:201:3adc:b08c:7acc:b325]) by smtp.gmail.com with ESMTPSA id h70sm6222740pgc.48.2019.10.10.15.29.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Oct 2019 15:29:57 -0700 (PDT) Date: Thu, 10 Oct 2019 15:29:55 -0700 From: Dmitry Torokhov To: Guenter Roeck Cc: Arnd Bergmann , Kukjin Kim , Krzysztof Kozlowski , Jean Delvare , Sebastian Reichel , linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linus.walleij@linaro.org, linux-kernel@vger.kernel.org, linux-hwmon@vger.kernel.org, linux-input@vger.kernel.org, linux-pm@vger.kernel.org Subject: Re: [PATCH 15/36] ARM: s3c: adc: move header to linux/soc/samsung Message-ID: <20191010222955.GB229325@dtor-ws> References: <20191010202802.1132272-1-arnd@arndb.de> <20191010203043.1241612-1-arnd@arndb.de> <20191010203043.1241612-15-arnd@arndb.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: 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 On Thu, Oct 10, 2019 at 03:20:32PM -0700, Guenter Roeck wrote: > On 10/10/19 1:29 PM, Arnd Bergmann wrote: > > There are multiple drivers using the private adc interface. > > It seems unlikely that they would ever get converted to iio, > > so make the current state official by making the header file > > global. > > > > The s3c2410_ts driver needs a couple of register definitions > > as well. > > > > Signed-off-by: Arnd Bergmann > > For hwmon: > > Acked-by: Guenter Roeck For input: Acked-by: Dmitry Torokhov > > > --- > > arch/arm/mach-s3c64xx/mach-crag6410.c | 2 +- > > arch/arm/mach-s3c64xx/mach-mini6410.c | 2 +- > > arch/arm/mach-s3c64xx/mach-real6410.c | 2 +- > > arch/arm/mach-s3c64xx/mach-smdk6410.c | 2 +- > > arch/arm/plat-samsung/adc.c | 2 +- > > arch/arm/plat-samsung/devs.c | 2 +- > > drivers/hwmon/s3c-hwmon.c | 2 +- > > drivers/input/touchscreen/s3c2410_ts.c | 37 ++++++++++++++++++- > > drivers/power/supply/s3c_adc_battery.c | 2 +- > > .../linux/soc/samsung/s3c-adc.h | 0 > > 10 files changed, 43 insertions(+), 10 deletions(-) > > rename arch/arm/plat-samsung/include/plat/adc.h => include/linux/soc/samsung/s3c-adc.h (100%) > > > > diff --git a/arch/arm/mach-s3c64xx/mach-crag6410.c b/arch/arm/mach-s3c64xx/mach-crag6410.c > > index da5b50981a14..133453562d23 100644 > > --- a/arch/arm/mach-s3c64xx/mach-crag6410.c > > +++ b/arch/arm/mach-s3c64xx/mach-crag6410.c > > @@ -57,7 +57,7 @@ > > #include > > #include > > #include > > -#include > > +#include > > #include > > #include > > #include > > diff --git a/arch/arm/mach-s3c64xx/mach-mini6410.c b/arch/arm/mach-s3c64xx/mach-mini6410.c > > index 0dd36ae49e6a..c7140300bd3f 100644 > > --- a/arch/arm/mach-s3c64xx/mach-mini6410.c > > +++ b/arch/arm/mach-s3c64xx/mach-mini6410.c > > @@ -27,7 +27,7 @@ > > #include > > #include > > -#include > > +#include > > #include > > #include > > #include > > diff --git a/arch/arm/mach-s3c64xx/mach-real6410.c b/arch/arm/mach-s3c64xx/mach-real6410.c > > index 0ff88b6859c4..f55097fde94c 100644 > > --- a/arch/arm/mach-s3c64xx/mach-real6410.c > > +++ b/arch/arm/mach-s3c64xx/mach-real6410.c > > @@ -29,7 +29,7 @@ > > #include > > #include > > -#include > > +#include > > #include > > #include > > #include > > diff --git a/arch/arm/mach-s3c64xx/mach-smdk6410.c b/arch/arm/mach-s3c64xx/mach-smdk6410.c > > index 95bdcfe95a53..3042f6cbffd9 100644 > > --- a/arch/arm/mach-s3c64xx/mach-smdk6410.c > > +++ b/arch/arm/mach-s3c64xx/mach-smdk6410.c > > @@ -60,7 +60,7 @@ > > #include > > #include > > -#include > > +#include > > #include > > #include > > #include > > diff --git a/arch/arm/plat-samsung/adc.c b/arch/arm/plat-samsung/adc.c > > index ee3d5c989a76..623a9774cc52 100644 > > --- a/arch/arm/plat-samsung/adc.c > > +++ b/arch/arm/plat-samsung/adc.c > > @@ -20,7 +20,7 @@ > > #include > > #include > > -#include > > +#include > > /* This driver is designed to control the usage of the ADC block between > > * the touchscreen and any other drivers that may need to use it, such as > > diff --git a/arch/arm/plat-samsung/devs.c b/arch/arm/plat-samsung/devs.c > > index fd94a35e22f8..ddd90f0bb380 100644 > > --- a/arch/arm/plat-samsung/devs.c > > +++ b/arch/arm/plat-samsung/devs.c > > @@ -44,7 +44,7 @@ > > #include > > #include > > -#include > > +#include > > #include > > #include > > #include > > diff --git a/drivers/hwmon/s3c-hwmon.c b/drivers/hwmon/s3c-hwmon.c > > index b490fe3d2ee8..f2703c5460d0 100644 > > --- a/drivers/hwmon/s3c-hwmon.c > > +++ b/drivers/hwmon/s3c-hwmon.c > > @@ -20,7 +20,7 @@ > > #include > > #include > > -#include > > +#include > > #include > > struct s3c_hwmon_attr { > > diff --git a/drivers/input/touchscreen/s3c2410_ts.c b/drivers/input/touchscreen/s3c2410_ts.c > > index b346e7cafd62..1a5a178ea286 100644 > > --- a/drivers/input/touchscreen/s3c2410_ts.c > > +++ b/drivers/input/touchscreen/s3c2410_ts.c > > @@ -21,10 +21,43 @@ > > #include > > #include > > -#include > > -#include > > +#include > > #include > > +#define S3C2410_ADCCON (0x00) > > +#define S3C2410_ADCTSC (0x04) > > +#define S3C2410_ADCDLY (0x08) > > +#define S3C2410_ADCDAT0 (0x0C) > > +#define S3C2410_ADCDAT1 (0x10) > > +#define S3C64XX_ADCUPDN (0x14) > > +#define S3C2443_ADCMUX (0x18) > > +#define S3C64XX_ADCCLRINT (0x18) > > +#define S5P_ADCMUX (0x1C) > > +#define S3C64XX_ADCCLRINTPNDNUP (0x20) > > + > > +/* ADCTSC Register Bits */ > > +#define S3C2443_ADCTSC_UD_SEN (1 << 8) > > +#define S3C2410_ADCTSC_YM_SEN (1<<7) > > +#define S3C2410_ADCTSC_YP_SEN (1<<6) > > +#define S3C2410_ADCTSC_XM_SEN (1<<5) > > +#define S3C2410_ADCTSC_XP_SEN (1<<4) > > +#define S3C2410_ADCTSC_PULL_UP_DISABLE (1<<3) > > +#define S3C2410_ADCTSC_AUTO_PST (1<<2) > > +#define S3C2410_ADCTSC_XY_PST(x) (((x)&0x3)<<0) > > + > > +/* ADCDAT0 Bits */ > > +#define S3C2410_ADCDAT0_UPDOWN (1<<15) > > +#define S3C2410_ADCDAT0_AUTO_PST (1<<14) > > +#define S3C2410_ADCDAT0_XY_PST (0x3<<12) > > +#define S3C2410_ADCDAT0_XPDATA_MASK (0x03FF) > > + > > +/* ADCDAT1 Bits */ > > +#define S3C2410_ADCDAT1_UPDOWN (1<<15) > > +#define S3C2410_ADCDAT1_AUTO_PST (1<<14) > > +#define S3C2410_ADCDAT1_XY_PST (0x3<<12) > > +#define S3C2410_ADCDAT1_YPDATA_MASK (0x03FF) > > + > > + > > #define TSC_SLEEP (S3C2410_ADCTSC_PULL_UP_DISABLE | S3C2410_ADCTSC_XY_PST(0)) > > #define INT_DOWN (0) > > diff --git a/drivers/power/supply/s3c_adc_battery.c b/drivers/power/supply/s3c_adc_battery.c > > index 3d00b35cafc9..60b7f41ab063 100644 > > --- a/drivers/power/supply/s3c_adc_battery.c > > +++ b/drivers/power/supply/s3c_adc_battery.c > > @@ -22,7 +22,7 @@ > > #include > > #include > > -#include > > +#include > > #define BAT_POLL_INTERVAL 10000 /* ms */ > > #define JITTER_DELAY 500 /* ms */ > > diff --git a/arch/arm/plat-samsung/include/plat/adc.h b/include/linux/soc/samsung/s3c-adc.h > > similarity index 100% > > rename from arch/arm/plat-samsung/include/plat/adc.h > > rename to include/linux/soc/samsung/s3c-adc.h > > > -- Dmitry