From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 42E93C4332F for ; Thu, 20 Oct 2022 13:31:13 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 14DF484E9D; Thu, 20 Oct 2022 15:31:10 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.b="MkE1fynH"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 1669084D30; Thu, 20 Oct 2022 15:31:07 +0200 (CEST) Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 1FCE384B67 for ; Thu, 20 Oct 2022 15:31:04 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=rogerq@kernel.org Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id AB5A0B8267E; Thu, 20 Oct 2022 13:31:03 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B6A3CC433D6; Thu, 20 Oct 2022 13:31:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1666272662; bh=Ss5TYocRwNHemVPKlKkFZnWgbAChx1PoQeQ/YWmV6n8=; h=From:To:Cc:Subject:Date:From; b=MkE1fynH2FtGU5BTPJcTvPTevDbHLmhWCmIKivI3+EJH8rQJnAqP0Ve3J1RGGw+Fy PRovz1yvaiD6ZKdn5nXs82zJWDLVXlILVZiilIks5z5I/ZQ221kFY9yavFTvT4J3iQ /Dd3CD0/92mmpy1Vcfa9Qu3PPW18KW5yg7gHlVC/ZXzCpm2f3w2PkMI8j3cBq0zmSZ NDgOtsHBC6Uq5mTYn9E4mx4kF6sPfes4A6ty3Ez69VBUIGG+wWaJ8YiKl4ybl5j2V3 Hw2HGPETPP4vyxUzrADQEZ7YZx0uj5QBG2Oh7TXRvMC8PAc4GeKbQiKK6RF2r/8dkc cY7WGD0qAIYVw== From: Roger Quadros To: trini@konsulko.com, sjg@chromium.org Cc: u-boot@lists.denx.de, praneeth@ti.com, Roger Quadros Subject: [u-boot][PATCH v3 0/4] Introduce MEMORY uclass and TI GPMC driver Date: Thu, 20 Oct 2022 16:30:45 +0300 Message-Id: <20221020133049.8398-1-rogerq@kernel.org> X-Mailer: git-send-email 2.17.1 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Hi, This series introduces the MEMORY controller uclass for the drivers that exist in drivers/memory directory. With that, we add the TI GPMC Memory controller driver as the first user of this uclass. The GPMC is a unified memory controller dedicated for interfacing with external memory devices like - Asynchronous SRAM-like memories and ASICs - Asynchronous, synchronous, and page mode burst NOR flash - NAND flash - Pseudo-SRAM devices The driver is pulled straight from the Linux kernel and adapted for u-boot. This driver will take care of setting up the GPMC based on the settings specified in the Device tree and then probe its children. cheers, -roger Changelog: v3: - Use CONFIG_MEMORY instead of CONFIG_DM_MEMORY - Introduce CONFIG_SPL_MEMORY and use it to gate inclusion of of drivers/memory for SPL build - Make TI_GPMC depend on OF_CONTROL and CLK as well v2: - Introduce MEMORY uclass Roger Quadros (4): dm: memory: Introduce new uclass scripts: Makefile.spl: Enable memory drivers to be built for SPL dt/bindings: memory: Add bindings for TI GPMC driver memory: Add TI GPMC driver arch/sandbox/dts/test.dts | 4 + common/spl/Kconfig | 7 + .../memory/ti,gpmc-child.yaml | 252 ++++ doc/device-tree-bindings/memory/ti,gpmc.yaml | 190 +++ drivers/memory/Kconfig | 36 + drivers/memory/Makefile | 3 + drivers/memory/memory-sandbox.c | 18 + drivers/memory/memory-uclass.c | 13 + drivers/memory/ti-gpmc.c | 1240 +++++++++++++++++ drivers/memory/ti-gpmc.h | 298 ++++ include/dm/uclass-id.h | 1 + include/linux/mtd/omap_gpmc.h | 3 + scripts/Makefile.spl | 1 + test/dm/Makefile | 1 + test/dm/memory.c | 21 + 15 files changed, 2088 insertions(+) create mode 100644 doc/device-tree-bindings/memory/ti,gpmc-child.yaml create mode 100644 doc/device-tree-bindings/memory/ti,gpmc.yaml create mode 100644 drivers/memory/memory-sandbox.c create mode 100644 drivers/memory/memory-uclass.c create mode 100644 drivers/memory/ti-gpmc.c create mode 100644 drivers/memory/ti-gpmc.h create mode 100644 test/dm/memory.c -- 2.17.1