Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp1108899ybg; Wed, 23 Oct 2019 10:28:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqx8WpPcvW2PP1FnQ/5SpAEjBatSUNTuYsUAyrVxmVtIkleTuQ5NWvO6uwi6yYsNmks15JyT X-Received: by 2002:a05:6402:1157:: with SMTP id g23mr15218275edw.260.1571851688345; Wed, 23 Oct 2019 10:28:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571851688; cv=none; d=google.com; s=arc-20160816; b=l/Nk6ydO4N8PVU2pSsS9szeDcPe6Y3i9MBowk/CWi3L3C32RWNAG56q4bSg7LHc56Z 7bpaFNHd0jzGKdxBzfYasYQrgxnKckRAyRvkyh0FT/MA9r3E9n9HtPo2bvrxFT+eLWNS +rzGv/Ic1P2wZRwMK8OVhs3AYAuLNUXXXRNL8yk6ETfqPitsRvbYUUWbCtw7RIwPzxq2 gp/IfPkgc6lZK9ofiuOjlWKjAJIGcu5ltKCS5PsnGMEEvcPWPpR/hCpFukilI3nl8FCi 7kw9XzLM/bpu4fWscgeHb1qx+H01STQ2jL8jF1aagcWlXHlzbFnyBi7mVvmyxizoplC4 mIow== 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; bh=CQZd7Ks2W7nTjayD2ynvN6k8gSwIF6xLtKbZwC/BStI=; b=ZQLsKuP28adX5P9AdwZtzouQ7VU54xb77Pu8LOKf4wIn1gDDE5conIcb/Ewdbo7ldr m1eZfef5eB7EhoCuXI8FHtDwUFiQKWVv2ruMJuW0oL2hD9+zrT6L4JJlRciIGUgx6C/u S+sebp/3m5r0/uuMlTf+diPzKa2zVP2ROQ+gYwZzCGxl4MNKGuo1cK7TdSI8eZd1ZOIh tO/BC0LOHiAIm29MvEpXj6rIG0k9PBrgkRbjgnV8bV/YFnD9UStmTzZKCJsV3ov1WvKd tJFJo+GsaoszSyXQLGU3JgB0nIDFqbYpjWDtg5omExJm9U42btgz0sMsZ0uXGq0A2FLJ zd/Q== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r5si14171720edo.14.2019.10.23.10.27.43; Wed, 23 Oct 2019 10:28:08 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390186AbfJWMha (ORCPT + 99 others); Wed, 23 Oct 2019 08:37:30 -0400 Received: from mail-ed1-f67.google.com ([209.85.208.67]:38769 "EHLO mail-ed1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731301AbfJWMh3 (ORCPT ); Wed, 23 Oct 2019 08:37:29 -0400 Received: by mail-ed1-f67.google.com with SMTP id y8so3339379edu.5; Wed, 23 Oct 2019 05:37:25 -0700 (PDT) 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=CQZd7Ks2W7nTjayD2ynvN6k8gSwIF6xLtKbZwC/BStI=; b=h5PiE9MtiBt0M/t5itZumyrp+4+khDhdAcKtTJBxWZSI4jiJqt66AnfLg1fTDZprIW ozBgarjrXMERWr2jnK/IUzmJmojPj12bplAs7ytY5jLkwFmZy10FHUHZfpCFTM1UPito 6wHxr1smn/eCgeIdDMhKSqwy6TbJDTNdPFZm2mzVDx9wJHbA4FD24GyftvSOWRGksbtg 8Z4ABPNaHZgIxTNsaebnjcuXC2VsyQyiy0J4WYs7TgnmFNjR0hGGrop8ismT87sGwU4P SS/qp2GlPY7VnIwp1X+Us4Ld8Mi8N8Y31DSPyWv0R6npiAhLia0ztSLKKbQ8B9R7SQm1 u91Q== X-Gm-Message-State: APjAAAVxGHSKVwHcCOCEm6so3PDhducYXHnoGefAVLsyI32TTirmQyC/ fUCZVI9juCIEhj8ABcuRHeI= X-Received: by 2002:a17:906:27c5:: with SMTP id k5mr31969642ejc.173.1571834245072; Wed, 23 Oct 2019 05:37:25 -0700 (PDT) Received: from pi3 ([194.230.155.217]) by smtp.googlemail.com with ESMTPSA id u18sm130680ejr.67.2019.10.23.05.37.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 23 Oct 2019 05:37:24 -0700 (PDT) Date: Wed, 23 Oct 2019 14:37:22 +0200 From: Krzysztof Kozlowski To: Arnd Bergmann Cc: Kukjin Kim , Jean Delvare , Guenter Roeck , Dmitry Torokhov , 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: <20191023123722.GD11048@pi3> 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=utf-8 Content-Disposition: inline In-Reply-To: <20191010203043.1241612-15-arnd@arndb.de> User-Agent: Mutt/1.12.1 (2019-06-15) 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 10:29:59PM +0200, 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 > --- > 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 Can you update the name of header guard? __LINUX_SOC_SAMSUNG_S3C_ADC_H? Best regards, Krzysztof