From patchwork Mon Feb 8 15:57:26 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 77767 X-Patchwork-Delegate: tomi.valkeinen@nokia.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o18FtCEe011834 for ; Mon, 8 Feb 2010 15:55:15 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753389Ab0BHPzM (ORCPT ); Mon, 8 Feb 2010 10:55:12 -0500 Received: from smtp.nokia.com ([192.100.122.233]:26866 "EHLO mgw-mx06.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753499Ab0BHPzK (ORCPT ); Mon, 8 Feb 2010 10:55:10 -0500 Received: from vaebh106.NOE.Nokia.com (vaebh106.europe.nokia.com [10.160.244.32]) by mgw-mx06.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o18Fsueh032340; Mon, 8 Feb 2010 17:55:07 +0200 Received: from vaebh104.NOE.Nokia.com ([10.160.244.30]) by vaebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 8 Feb 2010 17:55:04 +0200 Received: from mgw-da02.ext.nokia.com ([147.243.128.26]) by vaebh104.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Mon, 8 Feb 2010 17:55:03 +0200 Received: from localhost.localdomain (esdhcp041210.research.nokia.com [172.21.41.210]) by mgw-da02.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o18FsuKE017806; Mon, 8 Feb 2010 17:54:59 +0200 From: Tomi Valkeinen To: linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org Cc: Tomi Valkeinen Subject: [PATCH 02/17] OMAP: DSS2: DSI: remove auto-update perf measurement Date: Mon, 8 Feb 2010 17:57:26 +0200 Message-Id: <1265644661-3694-3-git-send-email-tomi.valkeinen@nokia.com> X-Mailer: git-send-email 1.6.5 In-Reply-To: <1265644661-3694-2-git-send-email-tomi.valkeinen@nokia.com> References: <1265644661-3694-1-git-send-email-tomi.valkeinen@nokia.com> <1265644661-3694-2-git-send-email-tomi.valkeinen@nokia.com> X-OriginalArrivalTime: 08 Feb 2010 15:55:04.0407 (UTC) FILETIME=[14371670:01CAA8D7] X-Nokia-AV: Clean Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Mon, 08 Feb 2010 15:55:15 +0000 (UTC) diff --git a/drivers/video/omap2/dss/dsi.c b/drivers/video/omap2/dss/dsi.c index 74df72b..a6ea8c8 100644 --- a/drivers/video/omap2/dss/dsi.c +++ b/drivers/video/omap2/dss/dsi.c @@ -261,8 +261,6 @@ static struct #ifdef DEBUG ktime_t perf_setup_time; ktime_t perf_start_time; - ktime_t perf_start_time_auto; - int perf_measure_frames; #endif int debug_read; int debug_write; @@ -338,12 +336,6 @@ static void dsi_perf_mark_start(void) dsi.perf_start_time = ktime_get(); } -static void dsi_perf_mark_start_auto(void) -{ - dsi.perf_measure_frames = 0; - dsi.perf_start_time_auto = ktime_get(); -} - static void dsi_perf_show(const char *name) { ktime_t t, setup_time, trans_time; @@ -374,72 +366,19 @@ static void dsi_perf_show(const char *name) dsi.active_update_region.h * dsi.active_update_region.device->ctrl.pixel_size / 8; - if (dsi.update_mode == OMAP_DSS_UPDATE_AUTO) { - static u32 s_total_trans_us, s_total_setup_us; - static u32 s_min_trans_us = 0xffffffff, s_min_setup_us; - static u32 s_max_trans_us, s_max_setup_us; - const int numframes = 100; - ktime_t total_time_auto; - u32 total_time_auto_us; - - dsi.perf_measure_frames++; - - if (setup_us < s_min_setup_us) - s_min_setup_us = setup_us; - - if (setup_us > s_max_setup_us) - s_max_setup_us = setup_us; - - s_total_setup_us += setup_us; - - if (trans_us < s_min_trans_us) - s_min_trans_us = trans_us; - - if (trans_us > s_max_trans_us) - s_max_trans_us = trans_us; - - s_total_trans_us += trans_us; - - if (dsi.perf_measure_frames < numframes) - return; - - total_time_auto = ktime_sub(t, dsi.perf_start_time_auto); - total_time_auto_us = (u32)ktime_to_us(total_time_auto); - - printk(KERN_INFO "DSI(%s): %u fps, setup %u/%u/%u, " - "trans %u/%u/%u\n", - name, - 1000 * 1000 * numframes / total_time_auto_us, - s_min_setup_us, - s_max_setup_us, - s_total_setup_us / numframes, - s_min_trans_us, - s_max_trans_us, - s_total_trans_us / numframes); - - s_total_setup_us = 0; - s_min_setup_us = 0xffffffff; - s_max_setup_us = 0; - s_total_trans_us = 0; - s_min_trans_us = 0xffffffff; - s_max_trans_us = 0; - dsi_perf_mark_start_auto(); - } else { - printk(KERN_INFO "DSI(%s): %u us + %u us = %u us (%uHz), " - "%u bytes, %u kbytes/sec\n", - name, - setup_us, - trans_us, - total_us, - 1000*1000 / total_us, - total_bytes, - total_bytes * 1000 / total_us); - } + printk(KERN_INFO "DSI(%s): %u us + %u us = %u us (%uHz), " + "%u bytes, %u kbytes/sec\n", + name, + setup_us, + trans_us, + total_us, + 1000*1000 / total_us, + total_bytes, + total_bytes * 1000 / total_us); } #else #define dsi_perf_mark_setup() #define dsi_perf_mark_start() -#define dsi_perf_mark_start_auto() #define dsi_perf_show(x) #endif @@ -2931,8 +2870,6 @@ static int dsi_set_update_mode(struct omap_dss_device *dssdev, dsi_set_update_region(dssdev, 0, 0, w, h); - dsi_perf_mark_start_auto(); - wake_up(&dsi.waitqueue); } }