From patchwork Fri Dec 7 14:14:14 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bin Meng X-Patchwork-Id: 1009450 X-Patchwork-Delegate: uboot@andestech.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="pTYE9mID"; dkim-atps=neutral Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 43BDtv0qc8z9rxp for ; Sat, 8 Dec 2018 01:12:22 +1100 (AEDT) Received: by lists.denx.de (Postfix, from userid 105) id 873E2C2273F; Fri, 7 Dec 2018 14:10:20 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=FREEMAIL_FROM, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 2900CC22705; Fri, 7 Dec 2018 14:09:39 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 6BE36C226FD; Fri, 7 Dec 2018 14:09:36 +0000 (UTC) Received: from mail-pg1-f195.google.com (mail-pg1-f195.google.com [209.85.215.195]) by lists.denx.de (Postfix) with ESMTPS id A5C69C21E35 for ; Fri, 7 Dec 2018 14:09:35 +0000 (UTC) Received: by mail-pg1-f195.google.com with SMTP id v28so1776182pgk.10 for ; Fri, 07 Dec 2018 06:09:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:in-reply-to:references; bh=cUN5k8Yxhs7nzvMSIiBmy/dtTDH55++GevSyA+XWdAM=; b=pTYE9mIDTrF248MGdQGkh6m8q2YvzwuPM/SK/jLKGQi6TwhUr9Gfa2ZJgf+N9/MbCm 538CRFjVe5d4VXaSo6Dv255pRt/jKIufSkQtrkuoN7JUYp+vYyPTq9kaJvYu8MEFa7hs 17oXG180A90gmKPRCZe1LkaGiiGoMtSrF1C9cQW5FiMZ2avzAxutrMz5R9zMhF1oJR8h vYRk41HKrIG9BHD5ruF0Vn1UsgG4EuHKOXjBykDtkv2psffobZ4GgvH+YDiUryNakHP3 K1whrYxU7Nc+udJPDgl0njBLAv6nz7fsA+o+Wyu7yJ8+nov+uShMxgc565vQfocf/b6w vdMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=cUN5k8Yxhs7nzvMSIiBmy/dtTDH55++GevSyA+XWdAM=; b=CTvqjrgLCbYKYwEGBLFXVhxJh1UI7tNu+KGaw6wFcR0k0bBpaNTnPXpgl9OZgXyTrl 9Wk+bAznl4MF0Sb1xLGAzDz3n15e7ueK/Pe/p+cLdu2SbneY6wWQrCTeCar7RESOk5// u5sISD7zkzO3/V06a/QX5SX370KbcHli2FHXoUPYaEmh3Ymcp/f31GZmdHeyfXft3UvK 6W7ZOAJfqhJpwqe8BQ/pyHJxQUVK7Dt7SXJ5EOMny1BoIboWjE4XZE4smLOzvxJimiRi SRpkFPCEzfg7lwIJLwEw7eNc2IQKOqeOEDPLB340xfHNjaqgfBr+k6qpHtV8rc6b+MkE qGvQ== X-Gm-Message-State: AA+aEWb1zWRSP8cnmYQk9QjSPSy+nD82WCTnASk5fb14+VhaRFDqS9if z05e9cUSYXxeAgH8NSRdODg= X-Google-Smtp-Source: AFSGD/WvAYsFhL474gugjTRBtYhbRRd5lcbBib9zb3R36leoBRIQCIBoRul2AYH0wREQLjbDXnpUNg== X-Received: by 2002:a63:85c6:: with SMTP id u189mr2014454pgd.156.1544191774345; Fri, 07 Dec 2018 06:09:34 -0800 (PST) Received: from ala-d2121-lx1.wrs.com (unknown-156-139.windriver.com. [147.11.156.139]) by smtp.gmail.com with ESMTPSA id f6sm5206070pfg.188.2018.12.07.06.09.33 (version=TLS1_1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 07 Dec 2018 06:09:33 -0800 (PST) From: Bin Meng To: Rick Chen , Simon Glass , Lukas Auer , Anup Patel , U-Boot Mailing List Date: Fri, 7 Dec 2018 06:14:14 -0800 Message-Id: <1544192072-28764-3-git-send-email-bmeng.cn@gmail.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1544192072-28764-1-git-send-email-bmeng.cn@gmail.com> References: <1544192072-28764-1-git-send-email-bmeng.cn@gmail.com> Subject: [U-Boot] [PATCH v2 02/20] dm: cpu: Add timebase frequency to the platdata X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" This adds a timebase_freq member to the 'struct cpu_platdata', to hold the "timebase-frequency" value in the cpu or /cpus node. Signed-off-by: Bin Meng Reviewed-by: Simon Glass Reviewed-by: Lukas Auer --- Changes in v2: - Use 'Hz' instead of 'HZ' include/cpu.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/cpu.h b/include/cpu.h index 367c5f4..28dd48f 100644 --- a/include/cpu.h +++ b/include/cpu.h @@ -14,6 +14,8 @@ * @device_id: Driver-defined device identifier * @family: DMTF CPU Family identifier * @id: DMTF CPU Processor identifier + * @timebase_freq: the current frequency at which the cpu timer timebase + * registers are updated (in Hz) * * This can be accessed with dev_get_parent_platdata() for any UCLASS_CPU * device. @@ -24,6 +26,7 @@ struct cpu_platdata { ulong device_id; u16 family; u32 id[2]; + u32 timebase_freq; }; /* CPU features - mostly just a placeholder for now */