From patchwork Wed Dec 9 21:22:28 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yang Shi X-Patchwork-Id: 58181 Delivered-To: patch@linaro.org Received: by 10.112.147.194 with SMTP id tm2csp106732lbb; Wed, 9 Dec 2015 13:42:33 -0800 (PST) X-Received: by 10.98.0.138 with SMTP id 132mr1614647pfa.131.1449697351761; Wed, 09 Dec 2015 13:42:31 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id be4si5963828pad.177.2015.12.09.13.42.31; Wed, 09 Dec 2015 13:42:31 -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 S1753209AbbLIVma (ORCPT + 28 others); Wed, 9 Dec 2015 16:42:30 -0500 Received: from mail-pa0-f54.google.com ([209.85.220.54]:32793 "EHLO mail-pa0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752799AbbLIVmZ (ORCPT ); Wed, 9 Dec 2015 16:42:25 -0500 Received: by pabur14 with SMTP id ur14so35923000pab.0 for ; Wed, 09 Dec 2015 13:42:25 -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=auEe5BE2UyyLggn0dbi3+mENLaR5mSlgo6fFE9oVkPM=; b=vlOpXkadrFqj4I3qw1v42K7tPdclZ9Zn24gScY1HpVRE4pGV1Jg7Z6eVEd7+Y9ylys W4RFPyr+Vt14F2BYfq+7bfNNfOnKhd/n0v00jG+lfMeSc3mh3X3VpPZxxsPhWPa8yYIQ 9wSR1OzfCIwBveo5HGWulYwc4P8bnyApSDcqhmDzOy67Dv6lZrpQm/ZQHLZFn9ff4wxL AT0Tx72Zucxp07DJFSVhIT32tCfU0yj44y37mo5q52K/HS50wqVoFH3RdM9KKHAshCSQ QGUKROv6tzhFoNt+TgCKYanD1tDKDv9ZeXCUsEWaFSmoWn3yT59Q1JyozNPsunYblORT qvMA== 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=auEe5BE2UyyLggn0dbi3+mENLaR5mSlgo6fFE9oVkPM=; b=cpHMmqi1xHhhz9x/3AFr24X59WvUV3w8dYiRNulJrDcUrLXDTITOQMgr4GHJnXGYZ3 x9PANVZnyMLnGVuKviwrDGglqlybQ+EH+bZO0uUvZbuVWRKs6uVaBfDChTrRWLDc4sq6 U4IuvShCrI+8vG5+fLalcMTCneyRex8WkDAx1MHe2m3Q19mcYzoQZu2fohIthnTClZTj INI56Oilt+976rwexmjVTfohSbarkBdLlsBo1h0o7NOFiRXYWG5By/jzlqH0A1tc9ur+ Y9XiOOzRCvxvQtoIF/HHL9V4fQi72xq9kB2e0kLjmyLsGUCZSkz3fLL+qBSjdWdHh41g jaiw== X-Gm-Message-State: ALoCoQmgXRnBfr9SPedafkxTuskRCGssIMjCarIc0SH+gO/AaCdiO/8XLCvhqXTDiQdBt7r0rtUQnd5GDlPRXPeuFezh7WzgXA== X-Received: by 10.66.172.164 with SMTP id bd4mr11375405pac.64.1449697345228; Wed, 09 Dec 2015 13:42:25 -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 f76sm13717090pfd.49.2015.12.09.13.42.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 09 Dec 2015 13:42:24 -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-mips@linux-mips.org Subject: [PATCH v5 4/7] mips: mm/gup: add gup trace points Date: Wed, 9 Dec 2015 13:22:28 -0800 Message-Id: <1449696151-4195-5-git-send-email-yang.shi@linaro.org> X-Mailer: git-send-email 2.0.2 In-Reply-To: <1449696151-4195-1-git-send-email-yang.shi@linaro.org> References: <1449696151-4195-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-mips@linux-mips.org Acked-by: Ralf Baechle Signed-off-by: Yang Shi --- arch/mips/mm/gup.c | 6 ++++++ 1 file changed, 6 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/mips/mm/gup.c b/arch/mips/mm/gup.c index 349995d..7d90883 100644 --- a/arch/mips/mm/gup.c +++ b/arch/mips/mm/gup.c @@ -15,6 +15,8 @@ #include #include +#include + static inline pte_t gup_get_pte(pte_t *ptep) { #if defined(CONFIG_PHYS_ADDR_T_64BIT) && defined(CONFIG_CPU_MIPS32) @@ -211,6 +213,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); + /* * XXX: batch / limit 'nr', to avoid large irq off latency * needs some instrumenting to determine the common sizes used by @@ -291,6 +295,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; slow: