From patchwork Tue Dec 3 11:15:28 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hanjun Guo X-Patchwork-Id: 21955 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qa0-f69.google.com (mail-qa0-f69.google.com [209.85.216.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 8057F202DA for ; Tue, 3 Dec 2013 11:25:03 +0000 (UTC) Received: by mail-qa0-f69.google.com with SMTP id ii20sf13630469qab.0 for ; Tue, 03 Dec 2013 03:25:02 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=2Pa+DZQz/kArkHs+YmS8JQrnQI43QRfXOU0BRoFbMvk=; b=Mf1IhXc04IduMA0AY0rpo/Vskrr8RR/8Xr6GhKSf9/vg63jJSAuRkeeHa59STZb3he PZpy0RVdrFp2Qyrf+5hojsIyca+K8i0Jp8/+TAf9hnqLB+d1k/VBkUEJODhxFG2DEWag ckXaJmqtkd/2er5XHxR6Ka/41LE5T7zlejvVLAEcCPV9q33aOKJ3OOPH9M3Yo09D7f9P F58rguTwBwkzefFhoECPqmY2ut8GfMTE5eCYCZ78Lx62173vhuv9Z4psamTJ7EdQWzfP PSHvNdEBT/+/ukpZHaS3E3HHxhMlCT5XmPqZg/8SeVeaxRMFiYHJZV1XIoRIQ6v0viFZ yxvg== X-Gm-Message-State: ALoCoQmKjtcEonyZSb5zEk35fCU80G53/RQjJ0QSwQ++UaB5iPMcB5gGvdc+lJXESKZMUyjU0S0x X-Received: by 10.58.2.98 with SMTP id 2mr21701711vet.3.1386069902448; Tue, 03 Dec 2013 03:25:02 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.121.131 with SMTP id lk3ls1087118qeb.59.gmail; Tue, 03 Dec 2013 03:25:02 -0800 (PST) X-Received: by 10.58.128.163 with SMTP id np3mr26912veb.62.1386069902352; Tue, 03 Dec 2013 03:25:02 -0800 (PST) Received: from mail-ve0-f178.google.com (mail-ve0-f178.google.com [209.85.128.178]) by mx.google.com with ESMTPS id dq5si17585847vcb.24.2013.12.03.03.25.02 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 03 Dec 2013 03:25:02 -0800 (PST) Received-SPF: neutral (google.com: 209.85.128.178 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.178; Received: by mail-ve0-f178.google.com with SMTP id c14so10035109vea.37 for ; Tue, 03 Dec 2013 03:25:02 -0800 (PST) X-Received: by 10.58.11.169 with SMTP id r9mr31742veb.52.1386069902144; Tue, 03 Dec 2013 03:25:02 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp199379vcz; Tue, 3 Dec 2013 03:25:01 -0800 (PST) X-Received: by 10.58.95.97 with SMTP id dj1mr5465953veb.21.1386069901166; Tue, 03 Dec 2013 03:25:01 -0800 (PST) Received: from hanjun-Latitude-D630 ([219.142.3.202]) by mx.google.com with ESMTPS id tj7si12422130vdc.33.2013.12.03.03.24.57 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 03 Dec 2013 03:25:01 -0800 (PST) Received-SPF: neutral (google.com: 219.142.3.202 is neither permitted nor denied by best guess record for domain of root@hanjun-latitude-d630) client-ip=219.142.3.202; Received: from hanjun-Latitude-D630 (localhost [127.0.0.1]) by hanjun-Latitude-D630 (8.14.4/8.14.4/Debian-2ubuntu2) with ESMTP id rB3BKfAE022617; Tue, 3 Dec 2013 19:20:41 +0800 Received: (from root@localhost) by hanjun-Latitude-D630 (8.14.4/8.14.4/Submit) id rB3BKOjL022552; Tue, 3 Dec 2013 19:20:24 +0800 From: Hanjun Guo To: Daniel Lezcano , "Rafael J. Wysocki" , Catalin Marinas , Will Deacon , Russell King - ARM Linux Cc: Grant Likely , Matthew Garrett , Olof Johansson , Linus Walleij , Bjorn Helgaas , Rob Herring , Mark Rutland , Jon Masters , linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org, patches@linaro.org, linux-kernel@vger.kernel.org, linaro-kernel@lists.linaro.org, linaro-acpi@lists.linaro.org, Hanjun Guo Subject: [RFC part3 PATCH 2/2] ARM64 / clocksource: Use arch_timer_acpi_init() Date: Tue, 3 Dec 2013 19:15:28 +0800 Message-Id: <1386069328-22502-3-git-send-email-hanjun.guo@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1386069328-22502-1-git-send-email-hanjun.guo@linaro.org> References: <1386069328-22502-1-git-send-email-hanjun.guo@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: hanjun.guo@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.178 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Use arch_timer_acpi_init() on ARM64 to initialise arch timer in ACPI way when DT is not available. Signed-off-by: Hanjun Guo --- arch/arm64/kernel/time.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm64/kernel/time.c b/arch/arm64/kernel/time.c index 29c39d5..fb009da 100644 --- a/arch/arm64/kernel/time.c +++ b/arch/arm64/kernel/time.c @@ -67,6 +67,10 @@ void __init time_init(void) clocksource_of_init(); + /* if can't be initialised from DT, try ACPI way */ + if (!arch_timer_get_rate()) + arch_timer_acpi_init(); + arch_timer_rate = arch_timer_get_rate(); if (!arch_timer_rate) panic("Unable to initialise architected timer.\n");