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 64B9CC4332F for ; Tue, 13 Dec 2022 15:57:17 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id E6AA2854B8; Tue, 13 Dec 2022 16:57:14 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com 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=gmail.com header.i=@gmail.com header.b="LbXi+A0G"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 91225854B5; Tue, 13 Dec 2022 16:57:12 +0100 (CET) Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id E4E6C85492 for ; Tue, 13 Dec 2022 16:57:09 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=clamor95@gmail.com Received: by mail-wm1-x32d.google.com with SMTP id ay8-20020a05600c1e0800b003d0808d2826so1203281wmb.1 for ; Tue, 13 Dec 2022 07:57:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=6ejqSG8qb4fYPL/ZKQ7NfOwElkReXjZkRaCUyV9+oFo=; b=LbXi+A0G1G1d3gJbCeRGV+ImD+ht1DY1kgslcWzs48YZhYdEJvvog7C2djb6FwZeVr p1RabKbOm4DcD+egiNN9r68D3BMy6+3YuwbxVj9f1FpMjGj84j/h8d3Ub+Kra8G0Tocv ufkuRYiNfwXG/8me1X2lDEdjKLGzYSTXgywgANN0e3JTlY76wvrt+1hOMc9Z41qRytz7 lieQ/FKcKA20I2hNgcVPaM5RgH6fNyDy2nCjSCKvoX6HdYm9d3c8uNudZSvLkUzqzX4H CoSWBVSzRrhllzT1VqUcPIEus055ANZrlEANvR+Exh9rf/P6Tf0wKbvv0OejY9ofmTrC EOjg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=6ejqSG8qb4fYPL/ZKQ7NfOwElkReXjZkRaCUyV9+oFo=; b=QtU0zIZkj/cZMDfptlKWc0J0810MATsPUwXSbcN4Udf1gN/cDHxpUXR4xCmYzN6SHQ 7sOiGF6/FrbjbtwJqd278wL5iOdi5y4J2u38Jl8rg9q/yIdxaxkBt7B8Sgvp8iAxKWiI dIKPaPpIXqgyhm6sPUcs8oowuQVydCzu3rwQXygivgNVbPRFi7aJUeclF8VgHOrFezkU fSl2KxV69ucAor9bYz+GIZ+/rfm3HTaLsWapl0JP0NIb01F7O8hWLKDJNzZAkAdhulSb qjcGvrkRaSb89wUHhgHNIYWHuzfWCowuxiOSSR4eS4QtLw8VivlpTXGp+UoXZGgyx3Av LxJQ== X-Gm-Message-State: ANoB5pnubLJvEHlxE0P/persUovFLDHKsetJOTuJYY5AsDOjYwzlbcT8 82+XAAUon5veJDt7T8XOADk= X-Google-Smtp-Source: AA0mqf6tsAzBw3m9/o1JJM6YrtOroNEUhGqhIYa9Tggs6PCzhu1NDsQX6JDEiA6Q1YZgeGHoM3U9Iw== X-Received: by 2002:a05:600c:4f48:b0:3cf:e850:4435 with SMTP id m8-20020a05600c4f4800b003cfe8504435mr16121437wmq.13.1670947029213; Tue, 13 Dec 2022 07:57:09 -0800 (PST) Received: from xeon.. ([188.163.112.59]) by smtp.gmail.com with ESMTPSA id q184-20020a1c43c1000000b003b4fdbb6319sm13434493wma.21.2022.12.13.07.57.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Dec 2022 07:57:08 -0800 (PST) From: Svyatoslav Ryhel To: Tom Warren , Marek Vasut , Heinrich Schuchardt , Svyatoslav Ryhel , Michal Simek , Eugen Hristev , Stefan Roese , Nick Hawkins , Andre Przywara , Simon Glass , Jim Liu , William Zhang , Patrice Chotard , Stanley Chu , =?UTF-8?q?Jonas=20Schw=C3=B6bel?= , Jaehoon Chung , Maxim Schwalm Cc: u-boot@lists.denx.de Subject: [PATCH v3 0/3] Re-Send Timer support for ARM Tegra Date: Tue, 13 Dec 2022 17:56:44 +0200 Message-Id: <20221213155647.4504-1-clamor95@gmail.com> X-Mailer: git-send-email 2.37.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 3.5 weeks have passed and I got no reviews. Since deadline of timer dm driver implementation is approaching I am re-sending partches. - ARM: tegra: remap clock_osc_freq for all Tegra family Enum clock_osc_freq was designed to use only with T20. This patch remaps it to use additional frequencies, added in T30+ SoC while maintaining backwards compatibility with T20. - drivers: timer: add timer driver for ARMv7 based Tegra devices Add timer support for T20/T30/T114 and T124 based devices. Driver is based on DM, has device tree support and can be used on SPL and early boot stage. - ARM: tegra: include timer as default option Enable TIMER as default option for add Tegra devices and enable TEGRA_TIMER for TEGRA_ARMV7_COMMON. Additionally enable SPL_TIMER if build as SPL part and drop deprecated configs from common header. P. S. I have no arm64 Tegra and according to comment in tegra-common.h Use the Tegra US timer on ARMv7, but the architected timer on ARMv8. Svyatoslav Ryhel (3): ARM: tegra: remap clock_osc_freq for all Tegra family drivers: timer: add timer driver for ARMv7 based Tegra devices ARM: tegra: include timer as default option arch/arm/Kconfig | 1 + arch/arm/include/asm/arch-tegra/clock.h | 9 +- arch/arm/mach-tegra/Kconfig | 2 + arch/arm/mach-tegra/clock.c | 17 +++- arch/arm/mach-tegra/cpu.c | 70 ++++++++++--- arch/arm/mach-tegra/tegra114/clock.c | 13 +-- arch/arm/mach-tegra/tegra124/clock.c | 13 +-- arch/arm/mach-tegra/tegra20/clock.c | 4 +- arch/arm/mach-tegra/tegra210/clock.c | 22 +---- arch/arm/mach-tegra/tegra30/clock.c | 10 +- drivers/timer/Kconfig | 8 ++ drivers/timer/Makefile | 1 + drivers/timer/tegra-timer.c | 124 ++++++++++++++++++++++++ drivers/usb/host/ehci-tegra.c | 46 +++++++-- include/configs/tegra-common.h | 6 -- 15 files changed, 267 insertions(+), 79 deletions(-) create mode 100644 drivers/timer/tegra-timer.c -- 2.37.2