From patchwork Sat Feb 1 18:52:16 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Fritz X-Patchwork-Id: 3565221 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 37334C02DC for ; Sat, 1 Feb 2014 18:53:03 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 272F0202C8 for ; Sat, 1 Feb 2014 18:53:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 41615202B8 for ; Sat, 1 Feb 2014 18:53:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753164AbaBASwY (ORCPT ); Sat, 1 Feb 2014 13:52:24 -0500 Received: from mail-lb0-f172.google.com ([209.85.217.172]:33102 "EHLO mail-lb0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752853AbaBASwX (ORCPT ); Sat, 1 Feb 2014 13:52:23 -0500 Received: by mail-lb0-f172.google.com with SMTP id c11so4354882lbj.17 for ; Sat, 01 Feb 2014 10:52:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=Owhn6dTymVeJZaE4phNa6JEdH7fvi7YeOzQtw4eBQfY=; b=dnda9tJhSWfN3TyiAVnLk8fN4Jft3P3vVWqIPhi/7N9+8dgQ3rLJGVhLXXuba5QF2r Jg1NXz3vn2CsT4V5lhiYY9Qfd4vr784Km3Wi6mm6LAk3w6+yItaXk4TgUm1FUTqPI0X9 Pzv3CLoRY2d/uiJ026+0ovRvLXPmCqMuQgyDmJeP2pg8/y2+W1meBLcRomo931sOpfEt 2lLz5LRhJhPRzhaI5hlStx7SgpXPsFHzXs1ZtpPGcgzNmt4hIlZ7TrnpqDjsbXxyQIL7 JzOEDjoUV2Jqh2+A6P7HCAjrPdPdXs6ZBahQUkT7nX+1xYwkClZlWnr91fFMwjNoG6cB BTVg== X-Received: by 10.112.138.233 with SMTP id qt9mr6566594lbb.34.1391280742005; Sat, 01 Feb 2014 10:52:22 -0800 (PST) Received: from mars ([46.246.44.60]) by mx.google.com with ESMTPSA id bl8sm14805493lbb.3.2014.02.01.10.52.19 for (version=TLSv1.1 cipher=RC4-SHA bits=128/128); Sat, 01 Feb 2014 10:52:20 -0800 (PST) Date: Sat, 1 Feb 2014 19:52:16 +0100 From: Christoph Fritz To: Nishanth Menon Cc: Tero Kristo , Tomi Valkeinen , Ivaylo Dimitrov , "linux-omap@vger.kernel.org" , linux-kernel@vger.kernel.org, pali.rohar@gmail.com, pavel@ucw.cz Subject: Re: OMAP: clock DT conversion issues with omap36xx Message-ID: <20140201185216.GA7125@mars> References: <52E697C0.6000202@gmail.com> <1390848104.4936.62.camel@mars> <52E772A3.4090401@ti.com> <1390901735.2963.8.camel@lovely> <52E77D03.8090001@ti.com> <52E7B361.2030601@ti.com> <1390928565.4904.88.camel@mars> <1390994505.5023.32.camel@mars> <52E95098.4060809@ti.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <52E95098.4060809@ti.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Spam-Status: No, score=-7.3 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Wed, Jan 29, 2014 at 01:03:52PM -0600, Nishanth Menon wrote: > To help us debug similar problems, I wrote a tool today: > https://github.com/nmenon/ctt-dump - it is a simple memory read utility, > Input file is CTT dump-out > For example: 3630 CTT is here: > http://www.ti.com/pdfs/wtbu/CTT-OMAP3630ES1.x-v1.6.0.4.zip > > to give an idea - i posted a screen shot here: > https://plus.google.com/112464029509057661457/posts/hNdee4gNfob > > After generating the the rd1 file from CTT, > we pick up the registers using ctt-dump -> any tool which can do > register reads could do, but it might be handy having this. > Example output on beagle-xm: http://slexy.org/view/s2YWmM1ium > importing it back into CTT and after setting up the correct sysclk, we > can compare clock frequencies Vs debugfs output - example: > http://slexy.org/view/s21iQyDTct > > > I mean, it is awesome having to debugfs data, but with nascent > systems, it is always good to compare to what the hardware is really > configured to - and CTT is the easy way to deal with it. Oscilloscope on pin sysclkout2 measures 24 Mhz with next_20140115 on this hardware here (omap3-lil-a83x). Its corresponding rd1 file, generated by ctt-dump, shows in CTT incorrectly 100 Mhz. The hardware has a 26 Mhz crystal. The error in CTT is that MUX_sys_clkout2 doesn't configure CLKOUT2SOURCE right. 0x2 is CM_96M_FCLK not CORE_CLK for example. This is the diff of clk registers before and after DT clock conversion patches: Thanks -- Christoph --- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- ctt_dump_lil_a83x_next_20140115__works_as_expected.rd1 +++ ctt_dump_lil_a83x_next_20140124__breaks.rd1 2014-02-01 @@ -22,23 +22,23 @@ 0x48004c10 0x0000002f 0x48004c30 0x0000023f 0x48004c40 0x00000014 -0x48004d00 0x10370037 +0x48004d00 0xf0371037 0x48004d04 0x00000017 0x48004d40 0x09900c00 0x48004d44 0x0483600c 0x48004d48 0x00000009 0x48004d4c 0x0000780c 0x48004d50 0x00000001 -0x48004d70 0x00000092 -0x48004e00 0x00000001 +0x48004d70 0x0000009a +0x48004e00 0x00000000 0x48004e10 0x00000001 0x48004e30 0x00000001 -0x48004e40 0x0000100f +0x48004e40 0x00001009 0x48004f00 0x00000000 0x48004f10 0x00000000 0x48004f30 0x00000001 0x48004f40 0x00000004 -0x48005000 0x00040800 +0x48005000 0x00000800 0x48005010 0x00078fff 0x48005030 0x0007ffff 0x48005040 0x000000ff