From patchwork Mon Apr 15 20:24:16 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 162267 Delivered-To: patch@linaro.org Received: by 2002:a02:c6d8:0:0:0:0:0 with SMTP id r24csp3370728jan; Mon, 15 Apr 2019 13:27:52 -0700 (PDT) X-Google-Smtp-Source: APXvYqyGuIWcXVud04udMM1q7wq4d5z+3z7mQ65Ut1kY4BrdASRLZ655Ojq9sqmEvtwFjsSm+hAO X-Received: by 2002:a17:902:7441:: with SMTP id e1mr75756531plt.13.1555360072911; Mon, 15 Apr 2019 13:27:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555360072; cv=none; d=google.com; s=arc-20160816; b=L2WXxXcDv1O4Tg/FnRbo/e8Css8CnNXZEvizEKhRvYv7hG+zzpiObs57f1h0ZDN8T2 QsLVHcw2G4x7+EC4ZonTvcr4xtStU21cwRDXlR4P4gYUzawjQTVWbc+t2LuyLZzfkoI3 F+0vxHZMwfK3vgmH4g/0dCwVm/+bKO9Q+OLuGTc1X11Pi1RlX5PhPMAD4nujJCPCUNtz ykwmTIE3wKAzJFCVtgCghHF/3xccDG3ZdRP1dEsQAEsx/Jqj3hhIhWhIAG/jDu57Nfk4 Ombbzq5aXShrDEQ2iX435Nftyyy+TiwsesPyfjpG3c2VrjMjbmdPec0XSWUYuWTXK4ZF uREA== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=cFnCbufp/A/y1kt47loHspIhm+mENfHLHZuKtz9QJ7A=; b=iQJUDhQsLzQdBILSFUOYVSLf6Nfm0ULvq6dPVsh9KQuB+nfs/Tq7vcnyxG6TsOta9l Zmm/CCZ7jU5kwmd1DY7468XXBsrKlu+7FiZ39zKSR3KsVoz8Wx5cI4dVsVsKnxdx3+PJ BCYMJj9e4atfd+GwAP0PMKz/tu8+AO0SA8Fz19PutWsno+Fia/c9VGRmbD2DorVF+fZH smwRIsSMrDx27YyhScpzZoIIhN6UnoIf0pJ5Rj38Hew9Ie1G4+mxDaVlU3pDBwwzW030 42RIQtrEZqdneOpLQDJgGGL8eBYo7XhC2GUHcGpVLjlduCVsMOnppSIG2K5Zybgqiz+D 22lQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-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 m1si45088431pgh.8.2019.04.15.13.27.52; Mon, 15 Apr 2019 13:27:52 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-gpio-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-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727831AbfDOU1w (ORCPT + 5 others); Mon, 15 Apr 2019 16:27:52 -0400 Received: from mout.kundenserver.de ([212.227.126.133]:36719 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727447AbfDOU1v (ORCPT ); Mon, 15 Apr 2019 16:27:51 -0400 Received: from threadripper.lan ([149.172.19.189]) by mrelayeu.kundenserver.de (mreue010 [212.227.15.129]) with ESMTPA (Nemesis) id 1Mtf7H-1h0FRt0VLz-00v7Sc; Mon, 15 Apr 2019 22:27:46 +0200 From: Arnd Bergmann To: Greg Ungerer Cc: Linus Walleij , arm@kernel.org, Arnd Bergmann , Bartosz Golaszewski , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org Subject: [PATCH 4/6] ARM: ks8695: move gpio code back into platform Date: Mon, 15 Apr 2019 22:24:16 +0200 Message-Id: <20190415202501.941196-4-arnd@arndb.de> X-Mailer: git-send-email 2.20.0 In-Reply-To: <20190415202501.941196-1-arnd@arndb.de> References: <20190415202501.941196-1-arnd@arndb.de> MIME-Version: 1.0 X-Provags-ID: V03:K1:HMe83s6pohIq/i3bMUw9/5Y38GKGIFa+UtVjWFJhBUsCcTyyx7n Gi1iz1hKJqvLPvGlsvmkwc63TPYBxkT0UaJSOeGypK86L0fpZUJq3iwi8bZ/TkWcb2WXplf AJNdEJdU31Ncc3IjFDxJL25DIWvBFVj3ds11KFKllCWMiwFWF3GD8QBfFPzXfPj5LIgTmCP oG9++Bt28owQxdjC7Zltw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1; V03:K0:q8TLkGYH7ao=:7tbN0O9vt0g0Uo0lpplzUn /uv1sRo7/rgsXEYThWrqNaVbxpEKGpA882wAB1Lbn6v7cMpjvW4MmB1Mda/fiAlG4sxHIdy/c /LlRjWVQb64f93FAaQtlJiQVePg/xCKSrF/e38RBBpCoQkCZc+b+LhIWlCCqav6Nc4jL5ETG/ bW3c0v8g/iHtFWXqIacXeNhC9sFjbdBy6soKKx7NhHoieRgecO8Suk/1O2omycu/socdRiv2n gshc0uyOuG2E0q+4aIBwEynQ9SJ8ny4M/LxhQavsHxdbcr4o5DsEqQbbG2UsUGf/0ECkgzYH+ SdaUbLxynr5p9+j1N25VRtO840zNEgnyAKdwqsHjR3bWgMaPpfsNHx+eDP4OSQYCHCYChnPm5 rx5AWtFAevb1ckg7Pg1D+11dv0ppykPEm9F09DPYNDterffZcOzwgJJGpHZ7jSEetGrlRMu6L 1Z9QI15TDM9sgUFrcfoGu0eUpqxwHkJGvTQyEYtUZE+or2nuJCi7PZ4Okzplumt++/I+GiQzr 0nMj5LXu45dwh9K//2LN3VOJlAXe0FOvzLFqwa1qsyKybh8K8CLxJoUO572lpe5MnPLm8Mhe3 5ulZ1hQ8uRY/rN8dKXPhOE9gt5la8dOlq8865Zb/LxLByeK9sDlaLUlaINGtbnWLYPRWyOAie P0Iq6sbPc/BZvjUPeNpXCFfOpm6oZIZyZ2HSWFbv7ugr5kdiiZ2gWWLEBjZyrJSCISuS4P47/ EYSY1g78XKe2JEq82uf/5DM8+YPW7hoJrsRZbA== Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Properly splitting this out into a portable driver is hard, as the gpio code tightly interacts with the irqchip code. Give up and move it back to its original location, but make the headers private in the process. Signed-off-by: Arnd Bergmann --- arch/arm/mach-ks8695/Makefile | 2 +- arch/arm/mach-ks8695/board-acs5k.c | 2 +- arch/arm/mach-ks8695/board-dsm320.c | 2 +- arch/arm/mach-ks8695/board-micrel.c | 2 +- arch/arm/mach-ks8695/board-og.c | 4 ++-- arch/arm/mach-ks8695/{include/mach => }/gpio-ks8695.h | 0 drivers/gpio/gpio-ks8695.c => arch/arm/mach-ks8695/gpio.c | 6 +++--- arch/arm/mach-ks8695/irq.c | 2 +- arch/arm/mach-ks8695/{include/mach => }/regs-gpio.h | 2 -- drivers/gpio/Makefile | 1 - 10 files changed, 10 insertions(+), 13 deletions(-) rename arch/arm/mach-ks8695/{include/mach => }/gpio-ks8695.h (100%) rename drivers/gpio/gpio-ks8695.c => arch/arm/mach-ks8695/gpio.c (98%) rename arch/arm/mach-ks8695/{include/mach => }/regs-gpio.h (97%) -- 2.20.0 Acked-by: Linus Walleij diff --git a/arch/arm/mach-ks8695/Makefile b/arch/arm/mach-ks8695/Makefile index 439b22255a32..0a64557c3050 100644 --- a/arch/arm/mach-ks8695/Makefile +++ b/arch/arm/mach-ks8695/Makefile @@ -4,7 +4,7 @@ # Makefile for KS8695 architecture support # -obj-y := cpu.o irq.o time.o devices.o +obj-y := cpu.o irq.o time.o devices.o gpio.o # PCI support is optional obj-$(CONFIG_PCI) += pci.o diff --git a/arch/arm/mach-ks8695/board-acs5k.c b/arch/arm/mach-ks8695/board-acs5k.c index 5783062224c3..9baa7f91811e 100644 --- a/arch/arm/mach-ks8695/board-acs5k.c +++ b/arch/arm/mach-ks8695/board-acs5k.c @@ -34,7 +34,7 @@ #include #include "devices.h" -#include +#include "gpio-ks8695.h" #include "generic.h" diff --git a/arch/arm/mach-ks8695/board-dsm320.c b/arch/arm/mach-ks8695/board-dsm320.c index 13537e9c5485..d3cfc9c955ad 100644 --- a/arch/arm/mach-ks8695/board-dsm320.c +++ b/arch/arm/mach-ks8695/board-dsm320.c @@ -29,7 +29,7 @@ #include #include "devices.h" -#include +#include "gpio-ks8695.h" #include "generic.h" diff --git a/arch/arm/mach-ks8695/board-micrel.c b/arch/arm/mach-ks8695/board-micrel.c index 69cfb9935fc1..69a27dfe8232 100644 --- a/arch/arm/mach-ks8695/board-micrel.c +++ b/arch/arm/mach-ks8695/board-micrel.c @@ -18,7 +18,7 @@ #include #include -#include +#include "gpio-ks8695.h" #include "devices.h" #include "generic.h" diff --git a/arch/arm/mach-ks8695/board-og.c b/arch/arm/mach-ks8695/board-og.c index 478ebd1f2b0f..7b962ba1425d 100644 --- a/arch/arm/mach-ks8695/board-og.c +++ b/arch/arm/mach-ks8695/board-og.c @@ -19,8 +19,8 @@ #include #include #include "devices.h" -#include -#include +#include "regs-gpio.h" +#include "gpio-ks8695.h" #include "generic.h" static int og_pci_map_irq(const struct pci_dev *dev, u8 slot, u8 pin) diff --git a/arch/arm/mach-ks8695/include/mach/gpio-ks8695.h b/arch/arm/mach-ks8695/gpio-ks8695.h similarity index 100% rename from arch/arm/mach-ks8695/include/mach/gpio-ks8695.h rename to arch/arm/mach-ks8695/gpio-ks8695.h diff --git a/drivers/gpio/gpio-ks8695.c b/arch/arm/mach-ks8695/gpio.c similarity index 98% rename from drivers/gpio/gpio-ks8695.c rename to arch/arm/mach-ks8695/gpio.c index d6d6140ffc40..3a6c8f804f91 100644 --- a/drivers/gpio/gpio-ks8695.c +++ b/arch/arm/mach-ks8695/gpio.c @@ -28,10 +28,10 @@ #include #include -#include +#include -#include -#include +#include "regs-gpio.h" +#include "gpio-ks8695.h" /* * Configure a GPIO line for either GPIO function, or its internal diff --git a/arch/arm/mach-ks8695/irq.c b/arch/arm/mach-ks8695/irq.c index 31439f2ee21e..ee3f08f66e7e 100644 --- a/arch/arm/mach-ks8695/irq.c +++ b/arch/arm/mach-ks8695/irq.c @@ -32,7 +32,7 @@ #include #include -#include +#include "regs-gpio.h" static void ks8695_irq_mask(struct irq_data *d) { diff --git a/arch/arm/mach-ks8695/include/mach/regs-gpio.h b/arch/arm/mach-ks8695/regs-gpio.h similarity index 97% rename from arch/arm/mach-ks8695/include/mach/regs-gpio.h rename to arch/arm/mach-ks8695/regs-gpio.h index 90614a7d0548..c97414b8825a 100644 --- a/arch/arm/mach-ks8695/include/mach/regs-gpio.h +++ b/arch/arm/mach-ks8695/regs-gpio.h @@ -1,6 +1,4 @@ /* - * arch/arm/mach-ks8695/include/mach/regs-gpio.h - * * Copyright (C) 2007 Andrew Victor * * KS8695 - GPIO control registers and bit definitions. diff --git a/drivers/gpio/Makefile b/drivers/gpio/Makefile index 54d55274b93a..a3b44ef6a8ea 100644 --- a/drivers/gpio/Makefile +++ b/drivers/gpio/Makefile @@ -64,7 +64,6 @@ obj-$(CONFIG_GPIO_IOP) += gpio-iop.o obj-$(CONFIG_GPIO_IT87) += gpio-it87.o obj-$(CONFIG_GPIO_JANZ_TTL) += gpio-janz-ttl.o obj-$(CONFIG_GPIO_KEMPLD) += gpio-kempld.o -obj-$(CONFIG_ARCH_KS8695) += gpio-ks8695.o obj-$(CONFIG_GPIO_INTEL_MID) += gpio-intel-mid.o obj-$(CONFIG_GPIO_LOONGSON) += gpio-loongson.o obj-$(CONFIG_GPIO_LP3943) += gpio-lp3943.o