From patchwork Thu Sep 12 11:39:12 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tero Kristo X-Patchwork-Id: 173693 Delivered-To: patch@linaro.org Received: by 2002:a05:6e02:ce:0:0:0:0 with SMTP id r14csp2003809ilq; Thu, 12 Sep 2019 04:39:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqxS1D57O73FBJ2hl5W1IDJSPJj+IsN91OWmXV76Zt0SdNb4nTNdkEOC4ODOdzKl8puPiz31 X-Received: by 2002:a50:ccd3:: with SMTP id b19mr35716222edj.257.1568288385179; Thu, 12 Sep 2019 04:39:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568288385; cv=none; d=google.com; s=arc-20160816; b=evoI/zMDhXl7bcyPJhLDYyhzM0ysYmfCZrWoau3VC1IIYD9RoyaO0eqDfqjP/9MQ6v /DBuaYHOT7Qxz6WRdJkZR93E2Jkinpz54ha0AJKZnXl6flLg+e+UhpkRzF9nIq0G1XdW HyRuNg/bFCS7F0FGIFItLuBzM8TIXftCV5aGCo1Vrj6lzAKkX1rMsex6uj0iTGr0mGkM uIBBzmunta63BA7jWoMD9wMrxcllMUr8g/fCI/iJu91S5LueBAu1uI2Mq8Rz86T/mvJY wbSdRcf4YtcNfgG7Xohb/9Bl3U2Q9DWrUGx5dxTgJZOlqQHo3M/GEU97GllybKSRBWKL hKSw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=jVjHqDUh4JTBppk9XVlo05dAGntMMljP5k/tZSWLMM4=; b=uO+SvmZH/xFtmQ8nkXQ9MZurLu2sQMV7XlTQyyHKsvEgFomdQDsE0gN69VX+y2IppH UT/2ES4B+Mu9+/9d3dCrNW6B074R9beunTkwa56eCA0WPmUH/ZQNrqpIoBAa6dnaKlDi LJ/e2aCltHjuN2wuQ2RRNlNVs5RogfGi3IUX56NITldS4HF9L6Qx8fmXzfKhIPNE/lg/ 08fL+wFaGi1AJHU795zT63xVyTijpPgNeDYXoNGLXKUce/Y/JEW7z3a8NNhsQkUFO73x dzLSfh0sxdbRIrB5ZRasIySzgb7IpauyL+pamvaNDFoo3817v6rotk3EAA3JJHUy6Dp6 sSJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=LjpWqVrr; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z20si8881422edq.250.2019.09.12.04.39.44; Thu, 12 Sep 2019 04:39:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of devicetree-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=@ti.com header.s=ti-com-17Q1 header.b=LjpWqVrr; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731343AbfILLjo (ORCPT + 8 others); Thu, 12 Sep 2019 07:39:44 -0400 Received: from lelv0143.ext.ti.com ([198.47.23.248]:58768 "EHLO lelv0143.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731355AbfILLjo (ORCPT ); Thu, 12 Sep 2019 07:39:44 -0400 Received: from lelv0266.itg.ti.com ([10.180.67.225]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id x8CBdbU3024489; Thu, 12 Sep 2019 06:39:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1568288377; bh=jVjHqDUh4JTBppk9XVlo05dAGntMMljP5k/tZSWLMM4=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=LjpWqVrrZvtj6KaOSg1I952BCkyFcwVg4idx/vR0+5NmLZp7OpkX8+8k5C8JcBLhi /SuW1gMVaU3i83dlxTVmIYcH3yrh1qoOEOE5LmZWP0NcI2FwHX3VbhrCsgZNnvmViL RiBJLSRKMCCvuFb+cWg1Fx+yNldZpV4QE96RYI/w= Received: from DFLE115.ent.ti.com (dfle115.ent.ti.com [10.64.6.36]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id x8CBdbrN012772 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Thu, 12 Sep 2019 06:39:37 -0500 Received: from DFLE104.ent.ti.com (10.64.6.25) by DFLE115.ent.ti.com (10.64.6.36) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5; Thu, 12 Sep 2019 06:39:37 -0500 Received: from fllv0040.itg.ti.com (10.64.41.20) by DFLE104.ent.ti.com (10.64.6.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5 via Frontend Transport; Thu, 12 Sep 2019 06:39:36 -0500 Received: from sokoban.bb.dnainternet.fi (ileax41-snat.itg.ti.com [10.172.224.153]) by fllv0040.itg.ti.com (8.15.2/8.15.2) with ESMTP id x8CBdKcv120606; Thu, 12 Sep 2019 06:39:35 -0500 From: Tero Kristo To: , , , , , CC: , Subject: [PATCHv5 06/10] soc: ti: omap-prm: add data for am33xx Date: Thu, 12 Sep 2019 14:39:12 +0300 Message-ID: <20190912113916.20093-7-t-kristo@ti.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190912113916.20093-1-t-kristo@ti.com> References: <20190912113916.20093-1-t-kristo@ti.com> MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Add PRM instance data for AM33xx SoC. Includes some basic register definitions and reset data for now. Signed-off-by: Tero Kristo --- drivers/soc/ti/omap_prm.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) -- 2.17.1 -- Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki diff --git a/drivers/soc/ti/omap_prm.c b/drivers/soc/ti/omap_prm.c index 24b1da3492c0..a5fde34f6afd 100644 --- a/drivers/soc/ti/omap_prm.c +++ b/drivers/soc/ti/omap_prm.c @@ -58,6 +58,11 @@ struct omap_reset_data { #define OMAP_PRM_HAS_RESETS (OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_HAS_RSTST) +static const struct omap_rst_map rst_map_0[] = { + { .rst = 0, .st = 0 }, + { .rst = -1 }, +}; + static const struct omap_rst_map rst_map_01[] = { { .rst = 0, .st = 0 }, { .rst = 1, .st = 1 }, @@ -79,8 +84,27 @@ static const struct omap_prm_data omap4_prm_data[] = { { }, }; +static const struct omap_rst_map am3_per_rst_map[] = { + { .rst = 1 }, + { .rst = -1 }, +}; + +static const struct omap_rst_map am3_wkup_rst_map[] = { + { .rst = 3, .st = 5 }, + { .rst = -1 }, +}; + +static const struct omap_prm_data am3_prm_data[] = { + { .name = "per", .base = 0x44e00c00, .rstctrl = 0x0, .rstmap = am3_per_rst_map, .flags = OMAP_PRM_HAS_RSTCTRL, .clkdm_name = "pruss_ocp" }, + { .name = "wkup", .base = 0x44e00d00, .rstctrl = 0x0, .rstst = 0xc, .rstmap = am3_wkup_rst_map, .flags = OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_HAS_NO_CLKDM }, + { .name = "device", .base = 0x44e00f00, .rstctrl = 0x0, .rstst = 0x8, .rstmap = rst_map_01, .flags = OMAP_PRM_HAS_RSTCTRL | OMAP_PRM_HAS_NO_CLKDM }, + { .name = "gfx", .base = 0x44e01100, .rstctrl = 0x4, .rstst = 0x14, .rstmap = rst_map_0, .clkdm_name = "gfx_l3" }, + { }, +}; + static const struct of_device_id omap_prm_id_table[] = { { .compatible = "ti,omap4-prm-inst", .data = omap4_prm_data }, + { .compatible = "ti,am3-prm-inst", .data = am3_prm_data }, { }, };