From patchwork Fri Sep 14 08:06:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 146681 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp406856ljw; Fri, 14 Sep 2018 01:06:27 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYgR3/xMOpNXcggSAw03e7QR0B9cBmB5ypNXO+jZtEwAv0uDqdfANBi7wbtnEweWytM7vC+ X-Received: by 2002:a50:8c06:: with SMTP id p6-v6mr17154298edp.282.1536912387659; Fri, 14 Sep 2018 01:06:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536912387; cv=none; d=google.com; s=arc-20160816; b=p/DbVXa0/FQAnffA4Yh+hjEh+6A/gYielcpIKMHT1sqfmbYviR3Mmu0LO6qq5hI9fm Ml0kxu0YsLbakNLWXPPcGHCr8Oj9dSAI/HpHy2efta0ggYgF1+ijo9wOYQMyuN3+5bZP P0wve5LmZSy4yyg39TPghrQ6v7wgRPYfiWyEXogvvdq1YsyiN/ZuPsw4B1qhszW8PWy4 Q71uQemTcOL2ghDHDnREeZYQ6AiBc1cQX4DXXroEykFE+FsTmGs6GkRcyzTBLccUjxYW mQPxgJK/8uDWCXehEP2tyoqL5AE80BvMl0LxBrP211l1Vsn5RwYqHl5AiEby5H6erSKS 7VqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:message-id:date:to:from :dkim-signature; bh=Jo5bOiAwV65QT563j3Q6QRg+ikdmalJ4quclsDCcMno=; b=bQSz9XN8+/MZV2US+b0sCmlEkKLyjLq3vn7ymiO7qHf+gXEPwRbRsvs5tR9WXhE+ic c6jgRz3lmdB6/Zis/xb76egg4sfMtklyfz13KxM9ZM3lWgVrDe2N0NeaEl1gcsG8iOmi 2Qiig5X+L0w7E/2fLO+iwUZz9sfPD3UtpHCtGgf3UeDb3LjTZM/WjyBEqqVOVInM6cGU jCHUd5IMmg3rX45mp22CLNe3h5QOxLMd32OpRMOTJeTKMLw6nwZgcSjiviunWgv0ytO5 wFTehNiT4nFZnKATy2zgaPyCE/fM3F4GaypmJklQ+G5QLHU/9lCYdhRpPXBCO7te+kvX twwQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Xrfg5ZSj; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id n17-v6si1507890edf.195.2018.09.14.01.06.27; Fri, 14 Sep 2018 01:06:27 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) client-ip=81.169.180.215; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Xrfg5ZSj; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.denx.de (Postfix, from userid 105) id 194B5C21FF8; Fri, 14 Sep 2018 08:06:25 +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=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 6324DC21F2F; Fri, 14 Sep 2018 08:06:23 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id CE5F1C21F2F; Fri, 14 Sep 2018 08:06:21 +0000 (UTC) Received: from mail-pf1-f195.google.com (mail-pf1-f195.google.com [209.85.210.195]) by lists.denx.de (Postfix) with ESMTPS id 35893C21D9A for ; Fri, 14 Sep 2018 08:06:21 +0000 (UTC) Received: by mail-pf1-f195.google.com with SMTP id d4-v6so3950858pfn.0 for ; Fri, 14 Sep 2018 01:06:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=ikYUrW/Ae/4BzHgMxepT5zZazTFacSfGWzFOkibwQDU=; b=Xrfg5ZSjdBzBLtKml1Yq38WfrvN6SHBtff7mlYVdN/maNhLt5drsVq7kS5KTCZPTBe NPNzF7deZ5jT/COBdkryBJio+6FkCg42zZ0ITVU8AqrVUrOCdin5sRk5UAQ4xmkVBek3 58RAdVwLPg3Pt5t85yImZgkbF1LQQfTTiP3Hw= 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=ikYUrW/Ae/4BzHgMxepT5zZazTFacSfGWzFOkibwQDU=; b=ow0I5mCCYxgud8U6OqKLI0THSnPviq+e9INElj2JpktXhsqJuBk9yRrrFhCDgZ/78C bxiZkz0+TtobRP40E3HrEkm9O5a38xwpjvsxuJGb5SdcPBS0OXssaBbrbarty4eQvqkP 2gx0auWUdPNqxF77gxkefurGl4+dETnb6nohZCp0lvjZVZtjg2Tld4Em27JyhXPfolG8 oZWqH4uAb4aZdYsRrBCrnuZp3ZFDyFElOdvHRoIj+tIHPFMjJfqdGA+c8REOST9cUZT8 NIZveXKz0Mzj3Gnq1AUOPOvg4Ys8pb4E576kXt7b4H8cDOZ0JYJJ8qU26b3ZHoVDouLp 7Vkg== X-Gm-Message-State: APzg51DPKc/5MYaYWm/GzUImYEyhwhXLVUSxogMzC9a3b41TeZvvo+LG rG/RxRDzvN3WZ/JzjNNwCzagLRcin0g= X-Received: by 2002:a63:a40a:: with SMTP id c10-v6mr10497475pgf.346.1536912379746; Fri, 14 Sep 2018 01:06:19 -0700 (PDT) Received: from linaro.org ([121.95.100.191]) by smtp.googlemail.com with ESMTPSA id f184-v6sm9951064pfc.88.2018.09.14.01.06.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 14 Sep 2018 01:06:19 -0700 (PDT) From: "Akashi, Takahiro" To: trini@konsulko.com, sjg@chromium.org, tuomas.tynkkynen@iki.fi Date: Fri, 14 Sep 2018 17:06:52 +0900 Message-Id: <20180914080654.29035-1-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.18.0 Cc: xypron.glpk@gmx.de, agraf@suse.de, u-boot@lists.denx.de Subject: [U-Boot] [PATCH v4 0/2] arm: qemu-arm: enable PL031 (RTC) 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" Virtual Machines provided by qemu for arm are already equipped with RTCdevice (PL031). With this patch set, PL031 driver is converted to driver model and by default enabled on qemu-arm. It allows us not only to use date command but also to enable UEFI's GetTime/SetTime() services. This work is motivated by running UEFI SCT(Self-Certification Test) and measuring time. Heinrich has already posted UEFI's GetTime() implementation. This is a revised version of my proposal[1]. [1] https://lists.denx.de/pipermail/u-boot/2018-July/333534.html Changes in v4 (Sep 14, 2018) * rebased to v2018.09-rc as my v3 was incompletely merged * drop v3's patch#1 * remove duplicated CONFIG_RTC_PL031 and CONFIG_SYS_RTC_PL031_BASE Changes in v3 (July 11, 2018) * compile drivers/rtc/date.c if DM_RTC * rename pl031_rtc_xxx to pl031_xxx * make struct pl031_platdata private to the driver * add probe function, removing pl031_initted variable * use readl/writel() instead of private macros * add a debug message to pl031_rtc_set() * remove CONFIG_SYS_RTC_PL031_BASE from config_whitelist.txt * enable RTC_PL031 for QEMU_ARM in arch/arm/Kconfig Changes in v2 (July 4, 2018) * based on Heinrich's comments, * remove legacy mode interface * enable the driver in defconfig AKASHI Takahiro (2): rtc: pl031: convert the driver to driver model arm: qemu-arm: enable RTC (PL031) by default arch/arm/Kconfig | 2 + drivers/rtc/pl031.c | 126 ++++++++++++++++++++++------------- include/configs/qemu-arm.h | 3 - scripts/config_whitelist.txt | 1 - 4 files changed, 82 insertions(+), 50 deletions(-)