From patchwork Mon Mar 6 09:52:36 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Tobin C. Harding" X-Patchwork-Id: 735652 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3vcFVj1kmBz9sNJ for ; Mon, 6 Mar 2017 20:54:05 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=tobin.cc header.i=@tobin.cc header.b="NVL4NJyS"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=messagingengine.com header.i=@messagingengine.com header.b="jr6X/eLy"; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 3vcFVj0h7vzDqY5 for ; Mon, 6 Mar 2017 20:54:05 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=tobin.cc header.i=@tobin.cc header.b="NVL4NJyS"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=messagingengine.com header.i=@messagingengine.com header.b="jr6X/eLy"; dkim-atps=neutral X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 3vcFTC3973zDqFh for ; Mon, 6 Mar 2017 20:52:47 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=tobin.cc header.i=@tobin.cc header.b="NVL4NJyS"; dkim=pass (1024-bit key; unprotected) header.d=messagingengine.com header.i=@messagingengine.com header.b="jr6X/eLy"; dkim-atps=neutral Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 4C7B5206D5; Mon, 6 Mar 2017 04:52:45 -0500 (EST) Received: from frontend2 ([10.202.2.161]) by compute5.internal (MEProxy); Mon, 06 Mar 2017 04:52:45 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=tobin.cc; h=cc :date:from:message-id:subject:to:x-me-sender:x-me-sender :x-sasl-enc:x-sasl-enc; s=mesmtp; bh=juehEeOPhAaqehbkUlidCQHJiIU =; b=NVL4NJyS2bZb8vr9YVRLYTRRCyosQIcDDtsWEYbMYr9farGpWp5sxVF7s9X P0hVqMSC2XPampmnklas6Ly7Y+LnOxXeMf0w7IumPcQsNOQfWnJ7eHkBDXuLIc+C Sb8E0ATTfP8yIOzZ6qmdYTqehZz0d+EQn0lzBXozOCgbJhoM= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=cc:date:from:message-id:subject:to :x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s=smtpout; bh=ju ehEeOPhAaqehbkUlidCQHJiIU=; b=jr6X/eLypplsgSb1THanVL6UmDmdx+Sp5+ /E3XnKugMluqKefe0JJWAGaJRlCCezc8pMklqDZ9ebNq/AFO3FMrXBKkrf77yMs6 NhKsbhM3BzRB95bmgDPX5zzLk04swcUkEOFLZYQMfTkkKcgw80qK71JwqztvWQyL y0jjR2wvw= X-ME-Sender: X-Sasl-enc: tSva/bFncAp/06wjDBuJ+BeENFUPys0mphIpPcYbJqiE 1488793964 Received: from eros.fritz.box (124-171-60-173.dyn.iinet.net.au [124.171.60.173]) by mail.messagingengine.com (Postfix) with ESMTPA id DEDF7240AF; Mon, 6 Mar 2017 04:52:42 -0500 (EST) From: "Tobin C. Harding" To: Michael Ellerman Subject: [PATCH] powerpc/pseries: move struct hcall_stats to c file Date: Mon, 6 Mar 2017 20:52:36 +1100 Message-Id: <1488793956-13188-1-git-send-email-me@tobin.cc> X-Mailer: git-send-email 2.7.4 X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paul Mackerras , linuxppc-dev@lists.ozlabs.org, "Tobin C. Harding" Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" struct hcall_stats is only used in hvCall_inst.c. Move struct hcall_stats to hvCall_inst.c Resolves: #54 Signed-off-by: Tobin C. Harding --- Is this correct, adding 'Resolves: #XX' when fixing github.com/linuxppc/linux issues? arch/powerpc/include/asm/hvcall.h | 10 ---------- arch/powerpc/platforms/pseries/hvCall_inst.c | 10 ++++++++++ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/arch/powerpc/include/asm/hvcall.h b/arch/powerpc/include/asm/hvcall.h index 77ff1ba..74599bd 100644 --- a/arch/powerpc/include/asm/hvcall.h +++ b/arch/powerpc/include/asm/hvcall.h @@ -364,16 +364,6 @@ long plpar_hcall_raw(unsigned long opcode, unsigned long *retbuf, ...); long plpar_hcall9(unsigned long opcode, unsigned long *retbuf, ...); long plpar_hcall9_raw(unsigned long opcode, unsigned long *retbuf, ...); -/* For hcall instrumentation. One structure per-hcall, per-CPU */ -struct hcall_stats { - unsigned long num_calls; /* number of calls (on this CPU) */ - unsigned long tb_total; /* total wall time (mftb) of calls. */ - unsigned long purr_total; /* total cpu time (PURR) of calls. */ - unsigned long tb_start; - unsigned long purr_start; -}; -#define HCALL_STAT_ARRAY_SIZE ((MAX_HCALL_OPCODE >> 2) + 1) - struct hvcall_mpp_data { unsigned long entitled_mem; unsigned long mapped_mem; diff --git a/arch/powerpc/platforms/pseries/hvCall_inst.c b/arch/powerpc/platforms/pseries/hvCall_inst.c index f02ec3a..892db4f 100644 --- a/arch/powerpc/platforms/pseries/hvCall_inst.c +++ b/arch/powerpc/platforms/pseries/hvCall_inst.c @@ -29,6 +29,16 @@ #include #include +/* For hcall instrumentation. One structure per-hcall, per-CPU */ +struct hcall_stats { + unsigned long num_calls; /* number of calls (on this CPU) */ + unsigned long tb_total; /* total wall time (mftb) of calls. */ + unsigned long purr_total; /* total cpu time (PURR) of calls. */ + unsigned long tb_start; + unsigned long purr_start; +}; +#define HCALL_STAT_ARRAY_SIZE ((MAX_HCALL_OPCODE >> 2) + 1) + DEFINE_PER_CPU(struct hcall_stats[HCALL_STAT_ARRAY_SIZE], hcall_stats); /*