From patchwork Thu Jan 22 09:55:40 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Magnus Damm X-Patchwork-Id: 3557 X-Patchwork-Delegate: lethal@linux-sh.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n0M9qe7Y000565 for ; Thu, 22 Jan 2009 01:52:57 -0800 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754485AbZAVJ5i (ORCPT ); Thu, 22 Jan 2009 04:57:38 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754659AbZAVJ5i (ORCPT ); Thu, 22 Jan 2009 04:57:38 -0500 Received: from rv-out-0506.google.com ([209.85.198.224]:5621 "EHLO rv-out-0506.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754485AbZAVJ5i (ORCPT ); Thu, 22 Jan 2009 04:57:38 -0500 Received: by rv-out-0506.google.com with SMTP id k40so4065474rvb.1 for ; Thu, 22 Jan 2009 01:57:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:date:message-id :in-reply-to:references:subject; bh=UjaFzZlxnxr+rB826aB2qx19iM+7DfSK4l/cudtRfKg=; b=gBlUpzkEky/RfWLer6vLldQs5gEw7PJAzm+PoTs7q0ZdohCcF5whKbbJK4+3zlVIUt 1j9FgH1UgUJdVxbAGhIZzv+9XVoefC7YBQ26cx/oNtf1kVvY1aRBVmOkynbirV2craja KU/a/KAgFVyqQ7M8qEtUKPdp2T4lhJ/bpMNsE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:date:message-id:in-reply-to:references:subject; b=o6AlabPJqyYfH0uMZxzu3gchnxL7zDuBYj589M7Lnk7v9q440/xibjFetnBltn+96f Y/KS08/YjBD7nspnL9mtagW8kVFLysNFhTAPt+eFgjq7mHELTyibzahQ37XJ7RwhKiJc /iFXWXPuQHlhNhaWgri7oSnmWK7kp8KZZl1EU= Received: by 10.140.226.13 with SMTP id y13mr4502999rvg.93.1232618257672; Thu, 22 Jan 2009 01:57:37 -0800 (PST) Received: from rx1.opensource.se (114.8.221.202.ts.2iij.net [202.221.8.114]) by mx.google.com with ESMTPS id k37sm17347046rvb.1.2009.01.22.01.57.34 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 22 Jan 2009 01:57:36 -0800 (PST) From: Magnus Damm To: linux-sh@vger.kernel.org Cc: akpm@linux-foundation.org, johnstul@us.ibm.com, lethal@linux-sh.org, Magnus Damm , mingo@redhat.com, tglx@linutronix.de Date: Thu, 22 Jan 2009 18:55:40 +0900 Message-Id: <20090122095540.31653.65134.sendpatchset@rx1.opensource.se> In-Reply-To: <20090122095521.31653.35942.sendpatchset@rx1.opensource.se> References: <20090122095521.31653.35942.sendpatchset@rx1.opensource.se> Subject: [PATCH 02/05] sh: tmu disable support Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org From: Magnus Damm Add TMU disable support so we can use other clockevents. Also, setup the clockevent rating. Signed-off-by: Magnus Damm --- arch/sh/kernel/timers/timer-tmu.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- 0015/arch/sh/kernel/timers/timer-tmu.c +++ work/arch/sh/kernel/timers/timer-tmu.c 2009-01-22 17:58:50.000000000 +0900 @@ -146,7 +146,14 @@ static irqreturn_t tmu_timer_interrupt(i _tmu_clear_status(TMU0); _tmu_set_irq(TMU0,tmu0_clockevent.mode != CLOCK_EVT_MODE_ONESHOT); - evt->event_handler(evt); + switch (tmu0_clockevent.mode) { + case CLOCK_EVT_MODE_ONESHOT: + case CLOCK_EVT_MODE_PERIODIC: + evt->event_handler(evt); + break; + default: + break; + } return IRQ_HANDLED; } @@ -271,6 +278,7 @@ static int tmu_timer_init(void) clockevent_delta2ns(1, &tmu0_clockevent); tmu0_clockevent.cpumask = cpumask_of(0); + tmu0_clockevent.rating = 100; clockevents_register_device(&tmu0_clockevent);