From patchwork Wed Dec 9 17:29:23 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yang Shi X-Patchwork-Id: 58172 Delivered-To: patch@linaro.org Received: by 10.112.147.194 with SMTP id tm2csp824043lbb; Wed, 9 Dec 2015 09:49:43 -0800 (PST) X-Received: by 10.98.15.215 with SMTP id 84mr7283pfp.49.1449683383725; Wed, 09 Dec 2015 09:49:43 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id uk9si13978370pac.166.2015.12.09.09.49.43; Wed, 09 Dec 2015 09:49:43 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dkim=neutral (body hash did not verify) header.i=@linaro-org.20150623.gappssmtp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753285AbbLIRte (ORCPT + 28 others); Wed, 9 Dec 2015 12:49:34 -0500 Received: from mail-pf0-f176.google.com ([209.85.192.176]:35834 "EHLO mail-pf0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753071AbbLIRtZ (ORCPT ); Wed, 9 Dec 2015 12:49:25 -0500 Received: by pfu207 with SMTP id 207so33386053pfu.2 for ; Wed, 09 Dec 2015 09:49:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=aoL0ftsSKgMzgYcgIlp+iY7vbBE4uYLHhtWxy/V41BU=; b=U0kQocNIKwfshIq7ohfSGnrGhMkQv0/1yhxhw77Cttq4vKP6oEFOjvT/FrAaAyOf2h Wa3+Ym4xBWh19HSyrhXc/O4n9nhLJ78Vz9ANdQKgOCpIJjwIluAy/RYTHqoz9Cu5WqiB a9+E9M1KuRCYw/GPTGKHAzTTCK6X69tnRU36BjVsrwlCxKaYAI89l0tKKAnE8LgL/1Wn YjeW8MX/WVEdzOIM+l1sQGBy0ZyKRD8G/DuxBAx+/4vIXJm9BkH9xpg/rbxPe9Y+RNDw qNZ5g8xgFrr/DYDwnc0KDS/EZodXZd3O9S/o297wKADnrIg9zz4kNzVyXa+NIBm7Zsa/ E1lA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=aoL0ftsSKgMzgYcgIlp+iY7vbBE4uYLHhtWxy/V41BU=; b=fHTpjjcpF24/ITyXNu2UxquBUhG3xMkwWRc0gqR1TU7BRUlcCpZjbfQFkSlaaTJCqN uNZz7+m8Nlf23yf54BEME0J/cL89iL9IiuU7Kg1HPxSNlUJ2qBLOrvun46EsC1Ul1QWV tfIoG6+RfkuyrHSQ2XHJjHIOSua2fbJEvg5LC5PosqKLGX8CyQaGbOixmaXskk+zwW8P X/hCSPykniUHYmvjBWj1LyhvoHNX+JW/2SFcvbHDxYRpbsuaLxxOq3vtMAxO8IghrxK6 DIwrYZEfW1W3LIqR6KWfRk2F8zrZl4SshHlAvx0wE2QmlFev0mJJGIAl4tKPuTGc7oGg niBA== X-Gm-Message-State: ALoCoQkbGgmYNHU/vHBIQUN1eaZr9u2/wdakg8TBylCUc55ufuBtvKzml3jESqzLqr80eaJwX4H0eIhJ5GtMlroDfVavW8Zc3g== X-Received: by 10.98.15.215 with SMTP id 84mr5296pfp.49.1449683364620; Wed, 09 Dec 2015 09:49:24 -0800 (PST) Received: from yshi-Precision-T5600.corp.ad.wrs.com (unknown-216-82.windriver.com. [147.11.216.82]) by smtp.gmail.com with ESMTPSA id l20sm13049117pfi.10.2015.12.09.09.49.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 09 Dec 2015 09:49:23 -0800 (PST) From: Yang Shi To: akpm@linux-foundation.org, rostedt@goodmis.org, mingo@redhat.com Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linaro-kernel@lists.linaro.org, yang.shi@linaro.org, linux-sh@vger.kernel.org Subject: [PATCH v4 6/7] sh: mm/gup: add gup trace points Date: Wed, 9 Dec 2015 09:29:23 -0800 Message-Id: <1449682164-9933-7-git-send-email-yang.shi@linaro.org> X-Mailer: git-send-email 2.0.2 In-Reply-To: <1449682164-9933-1-git-send-email-yang.shi@linaro.org> References: <1449682164-9933-1-git-send-email-yang.shi@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Cc: linux-sh@vger.kernel.org Signed-off-by: Yang Shi --- arch/sh/mm/gup.c | 7 +++++++ 1 file changed, 7 insertions(+) -- 2.0.2 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ diff --git a/arch/sh/mm/gup.c b/arch/sh/mm/gup.c index e7af6a6..fa72aac 100644 --- a/arch/sh/mm/gup.c +++ b/arch/sh/mm/gup.c @@ -14,6 +14,9 @@ #include #include +#define CREATE_TRACE_POINTS +#include + static inline pte_t gup_get_pte(pte_t *ptep) { #ifndef CONFIG_X2TLB @@ -178,6 +181,8 @@ int __get_user_pages_fast(unsigned long start, int nr_pages, int write, (void __user *)start, len))) return 0; + trace_gup_get_user_pages_fast(start, nr_pages); + /* * This doesn't prevent pagetable teardown, but does prevent * the pagetables and pages from being freed. @@ -244,6 +249,8 @@ int get_user_pages_fast(unsigned long start, int nr_pages, int write, } while (pgdp++, addr = next, addr != end); local_irq_enable(); + trace_gup_get_user_pages_fast(start, nr_pages); + VM_BUG_ON(nr != (end - start) >> PAGE_SHIFT); return nr;