From patchwork Fri Nov 9 15:26:39 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 10676175 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D18635A4 for ; Fri, 9 Nov 2018 15:27:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BE76828305 for ; Fri, 9 Nov 2018 15:27:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B2B512ED55; Fri, 9 Nov 2018 15:27:32 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id ECDEC28305 for ; Fri, 9 Nov 2018 15:27:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=k3oPhyOynmAfWlBnzFeRtftSj49d3c4Q/kuXCxuXFXE=; b=GZH Z80w/lW8xPiHmNc3PV7thhPLqS/tcmS643Jdz1W3lNH7KG+7dW+kpc87GwgJZ+2Ol0OCf/0rAC5j+ 6NjHUu9IWJr3fv023V6apSEEHySkMbtMbgoycMAmFo9CILT7Gc5vHOgjnshqi1hkP1oCZA7TYWg9Z rza4RSE1F2adAdSSVHFpjUDZyCCb/oT9b6u4JygBxDBDCJjKO0GM2JMa1i2N5B7cSh/LdsSMczxec F718w4/o6bf8g5lKfjUcTEWO6oPZtDuHNt2T5TX+ogy4nxsRtAjnyFblK2cDdVM0QaMhCNuT+ZIA/ F13buZXmENhpxzs78Gq1+mHruWWZQdg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gL8h0-0002mi-Ul; Fri, 09 Nov 2018 15:27:31 +0000 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gL8gl-0002YG-RE for linux-amlogic@lists.infradead.org; Fri, 09 Nov 2018 15:27:19 +0000 Received: by mail-wm1-x341.google.com with SMTP id f10-v6so2374352wme.3 for ; Fri, 09 Nov 2018 07:27:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=G7uAaBFq4pGvRNnB5gV/X1ZAwZn7pB4Azmgqi/ziD4U=; b=PuQqXlXv6F3+TZfpczh56MNgViEYmYs00rfIKn8nPfZ6HEfSGb9Ulz78PtOb6RPT1R 7J+06Gz275fINyhHoLQX5wBN8/zzVb+KS0/Ehkg4hQxMDhfIoLT/5WGryKlO4kYc/DuD o5FKyg5PeXxxeyp2RbQe4ffv/Eep2GxVDgLWjciprsK/n2RbY7tpytwv/fv8lc+4kExR EGKOgxxkJlYAGI2ufjGr7OP0ftRRkN3BWCWcePmVqwTsvr6QdN/btaTVU6EoxARYNeTY E462tJzyCpPrRgelxJCdAO115IZ2ksdz9B5fHy0cwtJHBpXbVeqM8TJOVB+BxrTDp/oz ucjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=G7uAaBFq4pGvRNnB5gV/X1ZAwZn7pB4Azmgqi/ziD4U=; b=k7i/D535C+4fe5sEu8idmHlcIdnIlixX9rx/VFf0kR+2DTr6SqQIJLgnMG3JL3beOA 7IAXlezggt4xk13tdA3e6ymuQfF0eLXF4uqqeKSxDuA4t79ZrdeBYwjaH1a5TTpuRxyI He1QVZiuSu7EedrCRYBEY7vKjVhAkzoM3Emz5SrmVP475R+m4kevPoHnlgxW2F3uxfsH 70ZGvby2pjKR6EIwwY1cnTwEB5Xfh0P6WO5tskpSjQWsV7PSRlhCKBimsEErG27aBTK0 cNGT5IYn5Iat8JFOBnJzbMau5kZm66Kp8LWncaQ4qE3jPcGXP7g7nBf+0NFcVHbbzmoG A+5Q== X-Gm-Message-State: AGRZ1gL3YZrtNgnvqJgVoxshEzs/bMqsT5aEG6r4CgYGiAAcYpTPEVQA isdTEGMlhIkJzoqDcr9cwEf13g== X-Google-Smtp-Source: AJdET5fmBX2Yq0AyKf0PLlZ3brdp5/9baE/5QTn28z24UknPFZ2zW9r+j18aVaHyBjQfRWlcG8kmkw== X-Received: by 2002:a1c:7203:: with SMTP id n3-v6mr5443034wmc.5.1541777221242; Fri, 09 Nov 2018 07:27:01 -0800 (PST) Received: from bender.baylibre.local ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id a127-v6sm1748545wmh.24.2018.11.09.07.27.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 09 Nov 2018 07:27:00 -0800 (PST) From: Neil Armstrong To: u-boot@lists.denx.de Subject: [PATCH u-boot 00/19] Amlogic Meson cleanup for AXG SoC support Date: Fri, 9 Nov 2018 16:26:39 +0100 Message-Id: <1541777218-472-1-git-send-email-narmstrong@baylibre.com> X-Mailer: git-send-email 2.7.4 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181109_072715_951279_DFE9F240 X-CRM114-Status: GOOD ( 15.87 ) X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-amlogic@lists.infradead.org, trini@konsulko.com, Neil Armstrong MIME-Version: 1.0 Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+patchwork-linux-amlogic=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP This patchset will refactor the Amlogic Meson SoC support in order to easily add support for the Amlogic AXg SoC family, and later the G12x SoCs. In order : - Cleanup the mach-meson configs - Move board support to reference design common boards - Move board Kconfig into mach-meson - Add AXG pinctrl & clock support - Add AXG device tree and mach-meson support - Add support for S400 reference design - Do a final factorization of the code - Add USB boot support in U-boot At the end of the patches, the board code is lighter and we maintain only the reference designs, where each board will differ in the defconfig. It will be simpler to add custom board support for future boards with more changes against the reference designs. The complete AXG support depends on the : - mmc: meson-gx: Add AXG compatible - net: designware: add meson meson axg compatible patches submitted to the U-Boot mailing list. Jerome Brunet (12): ARM: meson: clean-up platform selection configs: meson: remove unnecessary MESON_FDTFILE_SETTING board: amlogic: remove p212 derivatives board: amlogic: factorise gxbb boards ARM: rework amlogic configuration configs: meson: change default load addresses pinctrl: meson: rework gx pmx function pinctrl: meson: select generic pinctrl pinctrl: meson: add axg support clk: meson: silence debug print ARM: meson: rework soc arch file to prepare for new SoC ARM: meson: factorize common code out amlogic's boards Neil Armstrong (7): board: amlogic: move khadas-vim2 as q200 ref board clk: meson: add static to meson_gates table ARM: meson: Add support for AXG family ARM: dts: Sync Amlogic Meson AXG DT from Linux 4.20-rc1 clk: Add clock driver for AXG board: amlogic: add support for S400 board ARM: meson: Add boot device discovery arch/arm/dts/Makefile | 3 +- arch/arm/dts/meson-axg-s400.dts | 554 +++++++ arch/arm/dts/meson-axg.dtsi | 1589 ++++++++++++++++++++ arch/arm/include/asm/arch-meson/axg.h | 52 + arch/arm/include/asm/arch-meson/boot.h | 20 + arch/arm/include/asm/arch-meson/clock-axg.h | 104 ++ arch/arm/include/asm/arch-meson/clock-gx.h | 117 ++ arch/arm/include/asm/arch-meson/clock.h | 117 -- arch/arm/include/asm/arch-meson/eth.h | 6 +- arch/arm/include/asm/arch-meson/gx.h | 1 + arch/arm/include/asm/arch-meson/mem.h | 3 +- arch/arm/mach-meson/Kconfig | 132 +- arch/arm/mach-meson/Makefile | 4 +- arch/arm/mach-meson/board-axg.c | 118 ++ arch/arm/mach-meson/board-common.c | 118 ++ arch/arm/mach-meson/board-gx.c | 138 ++ arch/arm/mach-meson/board.c | 130 -- arch/arm/mach-meson/eth.c | 53 - arch/arm/mach-meson/sm.c | 1 - board/amlogic/khadas-vim/Kconfig | 12 - board/amlogic/khadas-vim/MAINTAINERS | 6 - board/amlogic/khadas-vim/Makefile | 6 - board/amlogic/khadas-vim/README | 102 -- board/amlogic/khadas-vim/khadas-vim.c | 57 - board/amlogic/khadas-vim2/Kconfig | 12 - board/amlogic/khadas-vim2/MAINTAINERS | 6 - board/amlogic/khadas-vim2/Makefile | 6 - board/amlogic/khadas-vim2/README | 103 -- board/amlogic/khadas-vim2/khadas-vim2.c | 62 - board/amlogic/libretech-cc/Kconfig | 12 - board/amlogic/libretech-cc/MAINTAINERS | 6 - board/amlogic/libretech-cc/Makefile | 6 - board/amlogic/libretech-cc/README | 102 -- board/amlogic/libretech-cc/libretech-cc.c | 57 - board/amlogic/nanopi-k2/Kconfig | 12 - board/amlogic/nanopi-k2/MAINTAINERS | 6 - board/amlogic/nanopi-k2/Makefile | 7 - board/amlogic/nanopi-k2/README | 99 -- board/amlogic/nanopi-k2/nanopi-k2.c | 55 - board/amlogic/odroid-c2/Kconfig | 12 - board/amlogic/odroid-c2/MAINTAINERS | 1 + board/amlogic/odroid-c2/README | 66 - board/amlogic/odroid-c2/README.nanopi-k2 | 99 ++ board/amlogic/odroid-c2/README.odroid-c2 | 66 + board/amlogic/odroid-c2/odroid-c2.c | 16 +- board/amlogic/p212/Kconfig | 12 - board/amlogic/p212/README | 103 -- board/amlogic/p212/README.khadas-vim | 102 ++ board/amlogic/p212/README.libretech-cc | 102 ++ board/amlogic/p212/README.p212 | 103 ++ board/amlogic/p212/p212.c | 16 +- board/amlogic/q200/MAINTAINERS | 6 + board/amlogic/q200/Makefile | 6 + board/amlogic/q200/README.khadas-vim2 | 103 ++ board/amlogic/q200/README.q200 | 102 ++ board/amlogic/q200/q200.c | 50 + board/amlogic/s400/MAINTAINERS | 6 + board/amlogic/s400/Makefile | 6 + board/amlogic/s400/README | 110 ++ board/amlogic/s400/s400.c | 21 + configs/khadas-vim2_defconfig | 1 - configs/khadas-vim_defconfig | 1 - configs/libretech-cc_defconfig | 1 - configs/nanopi-k2_defconfig | 2 - configs/odroid-c2_defconfig | 1 - configs/p212_defconfig | 1 - configs/s400_defconfig | 38 + drivers/clk/Makefile | 2 +- drivers/clk/clk_meson.c | 6 +- drivers/clk/clk_meson_axg.c | 316 ++++ drivers/pinctrl/meson/Kconfig | 18 +- drivers/pinctrl/meson/Makefile | 3 + drivers/pinctrl/meson/pinctrl-meson-axg-pmx.c | 125 ++ drivers/pinctrl/meson/pinctrl-meson-axg.c | 979 ++++++++++++ drivers/pinctrl/meson/pinctrl-meson-axg.h | 66 + drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c | 97 ++ drivers/pinctrl/meson/pinctrl-meson-gx.h | 48 + drivers/pinctrl/meson/pinctrl-meson-gxbb.c | 6 +- drivers/pinctrl/meson/pinctrl-meson-gxl.c | 6 +- drivers/pinctrl/meson/pinctrl-meson.c | 109 +- drivers/pinctrl/meson/pinctrl-meson.h | 37 +- include/configs/khadas-vim.h | 16 - include/configs/khadas-vim2.h | 18 - include/configs/libretech-cc.h | 16 - include/configs/meson-gx-common.h | 52 - include/configs/meson64.h | 73 + include/configs/nanopi-k2.h | 16 - include/configs/odroid-c2.h | 16 - include/configs/p212.h | 18 - include/dt-bindings/clock/axg-aoclkc.h | 26 + include/dt-bindings/clock/axg-audio-clkc.h | 94 ++ include/dt-bindings/clock/axg-clkc.h | 76 + include/dt-bindings/gpio/meson-axg-gpio.h | 116 ++ .../reset/amlogic,meson-axg-audio-arb.h | 17 + .../dt-bindings/reset/amlogic,meson-axg-reset.h | 124 ++ include/dt-bindings/reset/axg-aoclkc.h | 20 + 96 files changed, 6038 insertions(+), 1625 deletions(-) create mode 100644 arch/arm/dts/meson-axg-s400.dts create mode 100644 arch/arm/dts/meson-axg.dtsi create mode 100644 arch/arm/include/asm/arch-meson/axg.h create mode 100644 arch/arm/include/asm/arch-meson/boot.h create mode 100644 arch/arm/include/asm/arch-meson/clock-axg.h create mode 100644 arch/arm/include/asm/arch-meson/clock-gx.h delete mode 100644 arch/arm/include/asm/arch-meson/clock.h create mode 100644 arch/arm/mach-meson/board-axg.c create mode 100644 arch/arm/mach-meson/board-common.c create mode 100644 arch/arm/mach-meson/board-gx.c delete mode 100644 arch/arm/mach-meson/board.c delete mode 100644 arch/arm/mach-meson/eth.c delete mode 100644 board/amlogic/khadas-vim/Kconfig delete mode 100644 board/amlogic/khadas-vim/MAINTAINERS delete mode 100644 board/amlogic/khadas-vim/Makefile delete mode 100644 board/amlogic/khadas-vim/README delete mode 100644 board/amlogic/khadas-vim/khadas-vim.c delete mode 100644 board/amlogic/khadas-vim2/Kconfig delete mode 100644 board/amlogic/khadas-vim2/MAINTAINERS delete mode 100644 board/amlogic/khadas-vim2/Makefile delete mode 100644 board/amlogic/khadas-vim2/README delete mode 100644 board/amlogic/khadas-vim2/khadas-vim2.c delete mode 100644 board/amlogic/libretech-cc/Kconfig delete mode 100644 board/amlogic/libretech-cc/MAINTAINERS delete mode 100644 board/amlogic/libretech-cc/Makefile delete mode 100644 board/amlogic/libretech-cc/README delete mode 100644 board/amlogic/libretech-cc/libretech-cc.c delete mode 100644 board/amlogic/nanopi-k2/Kconfig delete mode 100644 board/amlogic/nanopi-k2/MAINTAINERS delete mode 100644 board/amlogic/nanopi-k2/Makefile delete mode 100644 board/amlogic/nanopi-k2/README delete mode 100644 board/amlogic/nanopi-k2/nanopi-k2.c delete mode 100644 board/amlogic/odroid-c2/Kconfig delete mode 100644 board/amlogic/odroid-c2/README create mode 100644 board/amlogic/odroid-c2/README.nanopi-k2 create mode 100644 board/amlogic/odroid-c2/README.odroid-c2 delete mode 100644 board/amlogic/p212/Kconfig delete mode 100644 board/amlogic/p212/README create mode 100644 board/amlogic/p212/README.khadas-vim create mode 100644 board/amlogic/p212/README.libretech-cc create mode 100644 board/amlogic/p212/README.p212 create mode 100644 board/amlogic/q200/MAINTAINERS create mode 100644 board/amlogic/q200/Makefile create mode 100644 board/amlogic/q200/README.khadas-vim2 create mode 100644 board/amlogic/q200/README.q200 create mode 100644 board/amlogic/q200/q200.c create mode 100644 board/amlogic/s400/MAINTAINERS create mode 100644 board/amlogic/s400/Makefile create mode 100644 board/amlogic/s400/README create mode 100644 board/amlogic/s400/s400.c create mode 100644 configs/s400_defconfig create mode 100644 drivers/clk/clk_meson_axg.c create mode 100644 drivers/pinctrl/meson/pinctrl-meson-axg-pmx.c create mode 100644 drivers/pinctrl/meson/pinctrl-meson-axg.c create mode 100644 drivers/pinctrl/meson/pinctrl-meson-axg.h create mode 100644 drivers/pinctrl/meson/pinctrl-meson-gx-pmx.c create mode 100644 drivers/pinctrl/meson/pinctrl-meson-gx.h delete mode 100644 include/configs/khadas-vim.h delete mode 100644 include/configs/khadas-vim2.h delete mode 100644 include/configs/libretech-cc.h delete mode 100644 include/configs/meson-gx-common.h create mode 100644 include/configs/meson64.h delete mode 100644 include/configs/nanopi-k2.h delete mode 100644 include/configs/odroid-c2.h delete mode 100644 include/configs/p212.h create mode 100644 include/dt-bindings/clock/axg-aoclkc.h create mode 100644 include/dt-bindings/clock/axg-audio-clkc.h create mode 100644 include/dt-bindings/clock/axg-clkc.h create mode 100644 include/dt-bindings/gpio/meson-axg-gpio.h create mode 100644 include/dt-bindings/reset/amlogic,meson-axg-audio-arb.h create mode 100644 include/dt-bindings/reset/amlogic,meson-axg-reset.h create mode 100644 include/dt-bindings/reset/axg-aoclkc.h