From patchwork Tue Dec 3 16:41:31 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hanjun Guo X-Patchwork-Id: 21993 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pb0-f70.google.com (mail-pb0-f70.google.com [209.85.160.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id A59DA202AE for ; Tue, 3 Dec 2013 16:42:20 +0000 (UTC) Received: by mail-pb0-f70.google.com with SMTP id rq2sf39024584pbb.5 for ; Tue, 03 Dec 2013 08:42:19 -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=S2AqPuEHK+WlW7uGy+H74HmDReThco4Bvz6D9YnnCriip4si4PQJYRpzf+jtdatssP BjiaH4DtOYhoVKO1KKX1lb0RKQSc9aERHKEn3ZefHcjqvddnvgsMDb5i+nxr4XrwFTSF ZzOxJoGnDgVort8XKelg63blwskNWgiMxoAA/E+xPHoF7BlEIGr33zIDOyY4e1SG8hO0 Paacwyri3WMCX0AaAl8mMaf0qGva6KunpVY6m0OtUoYT1xsgnd6+L9uEGW4dT1N0oG2U j0yF0vsdZ/Lq7H3wcS93n2aYiV6uoZTdJhEjOQ+svamUA3kzrV/nnfzCalOrmYPJae+g kBew== X-Gm-Message-State: ALoCoQkpgzitD51w7ZlrzW57/FSpwR7SS9LaNtq1dl8IKB5jDkfnR2oT6TOyqdd2KBNXb2lf7zNh X-Received: by 10.66.66.109 with SMTP id e13mr18602840pat.1.1386088939963; Tue, 03 Dec 2013 08:42:19 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.17.103 with SMTP id n7ls1602613qed.52.gmail; Tue, 03 Dec 2013 08:42:19 -0800 (PST) X-Received: by 10.220.183.199 with SMTP id ch7mr5354073vcb.27.1386088939452; Tue, 03 Dec 2013 08:42:19 -0800 (PST) Received: from mail-vc0-f172.google.com (mail-vc0-f172.google.com [209.85.220.172]) by mx.google.com with ESMTPS id fc4si2914093vcb.86.2013.12.03.08.42.19 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 03 Dec 2013 08:42:19 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.172 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.172; Received: by mail-vc0-f172.google.com with SMTP id hz11so10097711vcb.31 for ; Tue, 03 Dec 2013 08:42:19 -0800 (PST) X-Received: by 10.58.19.195 with SMTP id h3mr120174vee.48.1386088939275; Tue, 03 Dec 2013 08:42:19 -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 u4csp222750vcz; Tue, 3 Dec 2013 08:42:18 -0800 (PST) X-Received: by 10.68.248.33 with SMTP id yj1mr39382888pbc.45.1386088938505; Tue, 03 Dec 2013 08:42:18 -0800 (PST) Received: from mail-pd0-f179.google.com (mail-pd0-f179.google.com [209.85.192.179]) by mx.google.com with ESMTPS id gn4si51816494pbc.321.2013.12.03.08.42.18 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 03 Dec 2013 08:42:18 -0800 (PST) Received-SPF: neutral (google.com: 209.85.192.179 is neither permitted nor denied by best guess record for domain of hanjun.guo@linaro.org) client-ip=209.85.192.179; Received: by mail-pd0-f179.google.com with SMTP id r10so20586912pdi.10 for ; Tue, 03 Dec 2013 08:42:18 -0800 (PST) X-Received: by 10.66.164.136 with SMTP id yq8mr75264379pab.67.1386088938029; Tue, 03 Dec 2013 08:42:18 -0800 (PST) Received: from localhost ([219.142.3.202]) by mx.google.com with ESMTPSA id rz6sm136460589pab.22.2013.12.03.08.42.10 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Tue, 03 Dec 2013 08:42:17 -0800 (PST) From: Hanjun Guo To: "Rafael J. Wysocki" , Catalin Marinas , Will Deacon , Russell King - ARM Linux , Daniel Lezcano Cc: linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Grant Likely , Matthew Garrett , Olof Johansson , Linus Walleij , Bjorn Helgaas , Rob Herring , Mark Rutland , Jon Masters , 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: Wed, 4 Dec 2013 00:41:31 +0800 Message-Id: <1386088891-2917-3-git-send-email-hanjun.guo@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1386088891-2917-1-git-send-email-hanjun.guo@linaro.org> References: <1386088891-2917-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.220.172 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");