Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp2400162imj; Mon, 11 Feb 2019 02:07:17 -0800 (PST) X-Google-Smtp-Source: AHgI3IbqeA6bOT9XqRbIr2tr5wZy0HV2N+r4+iipUWsDWp9AdWZEhpDFV7LkeviwZgligc1UKQMO X-Received: by 2002:a62:b511:: with SMTP id y17mr36127201pfe.199.1549879637486; Mon, 11 Feb 2019 02:07:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549879637; cv=none; d=google.com; s=arc-20160816; b=Xj5Ztgd3whvEsoNydQuFeSgdH7IyuusUhEfqCFgmXssYH8KEwe2Qbg4WZS2lJ+65hN OzX5WnSCL9Bgv0lIQxtvI0S5zgjvoLT2pUK1uorGS8C9Fp8tyZjspoLdst1YmXZJc4Eo s/Y9dJnIyP39Gfket/OKM2UvRe+noqvkLl9vUW0PUlf8fpqz0vWhJN5D+MLO6QYIo2zR tgWGmK65Jl0WD0aG2WgHqRhZQtr9W4LDZio66mtLIemNNtCgYpKY8JxJWmPK3Dd2WMNC ecsgBc29Hx8g6+4xPPx/u1Jg8P2+qGYcExI7Vo8ooVQUjmrmHQyA2FqbIzZAehU6WktF 7dpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=kwfPZdfuAKYP4mH028evPy84hNrtWVBdLPvNA0GYFv0=; b=TZD4nyDlaUYnobn3Lq4nPrIUFpUR2Hk+ohqKGs7+3kRfLnXm9pTEFgojRbjXo8Pr6M 0Z8FrVV+m7UEa+wfPVoI2i6GG4Q7T5KTd5oyjnMA7sk8wkMg7Wd47+/qpZCAn3gc00pc 8gM7OC2sp8uW8f0yKZY4WHcfkt8oyW/OgEFdnWJgegZ4wTVo195+7FJjE9vR7MbbNpQW T2m0NocM7rq/ifwKD7BLS6HT9ODWa/ZTrND442IusTO/VXAC56g1BXdI09lWgwvjnrEU ScK5qWPmARs5zf9Ff5tXl6QN4qAJ3hVmkt9uhVklOZnlF6UxepL+jpjzstxfkaqfQQAb 6alw== ARC-Authentication-Results: i=1; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n5si9399459plp.266.2019.02.11.02.07.00; Mon, 11 Feb 2019 02:07:17 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726243AbfBKKGm (ORCPT + 99 others); Mon, 11 Feb 2019 05:06:42 -0500 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:42786 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725931AbfBKKGm (ORCPT ); Mon, 11 Feb 2019 05:06:42 -0500 Received: from pps.filterd (m0098394.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x1BA63Vn106647 for ; Mon, 11 Feb 2019 05:06:41 -0500 Received: from e06smtp04.uk.ibm.com (e06smtp04.uk.ibm.com [195.75.94.100]) by mx0a-001b2d01.pphosted.com with ESMTP id 2qk4yfwtu6-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 11 Feb 2019 05:06:40 -0500 Received: from localhost by e06smtp04.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 11 Feb 2019 10:06:38 -0000 Received: from b06cxnps3074.portsmouth.uk.ibm.com (9.149.109.194) by e06smtp04.uk.ibm.com (192.168.101.134) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Mon, 11 Feb 2019 10:06:35 -0000 Received: from d06av25.portsmouth.uk.ibm.com (d06av25.portsmouth.uk.ibm.com [9.149.105.61]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x1BA6YkK47055086 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 11 Feb 2019 10:06:34 GMT Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 9D4C111C05E; Mon, 11 Feb 2019 10:06:34 +0000 (GMT) Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 6207E11C04A; Mon, 11 Feb 2019 10:06:34 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av25.portsmouth.uk.ibm.com (Postfix) with ESMTP; Mon, 11 Feb 2019 10:06:34 +0000 (GMT) From: Thomas Richter To: linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, acme@kernel.org Cc: brueckner@linux.vnet.ibm.com, schwidefsky@de.ibm.com, heiko.carstens@de.ibm.com, Thomas Richter Subject: [PATCH] perf report: Add s390 diagnosic sampling descriptor size Date: Mon, 11 Feb 2019 11:06:27 +0100 X-Mailer: git-send-email 2.16.4 X-TM-AS-GCONF: 00 x-cbid: 19021110-0016-0000-0000-00000254F7B5 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19021110-0017-0000-0000-000032AF1247 Message-Id: <20190211100627.85714-1-tmricht@linux.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-02-11_08:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=964 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1902110079 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On IBM z13 machine types 2964 and 2965 the descriptor sizes for sampling and diagnostic sampling entries might be missing in the trailer entry and are set to zero. This leads to a perf report failure when processing diagnostic sampling entries. This patch adds missing descriptor sizes when the trailer entry contains zero for these fields. Output before: [root@s38lp82 perf]# ./perf report --stdio | fgrep Samples 0xabbf0 [0x8]: failed to process type: 68 Error: failed to process sample [root@s38lp82 perf]# Output after: [root@s38lp82 perf]# ./perf report --stdio | fgrep Samples # Total Lost Samples: 0 # Samples: 3K of event 'SF_CYCLES_BASIC_DIAG' # Samples: 162 of event 'CF_DIAG' [root@s38lp82 perf]# Fixes: 2b1444f2e28b ("perf report: Add raw report support for s390 auxiliary trace") Signed-off-by: Thomas Richter Reviewed-by: Hendrik Brueckner --- tools/perf/util/s390-cpumsf.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tools/perf/util/s390-cpumsf.c b/tools/perf/util/s390-cpumsf.c index 68b2570304ec..08073a4d59a4 100644 --- a/tools/perf/util/s390-cpumsf.c +++ b/tools/perf/util/s390-cpumsf.c @@ -301,6 +301,11 @@ static bool s390_cpumsf_validate(int machine_type, *dsdes = 85; *bsdes = 32; break; + case 2964: + case 2965: + *dsdes = 112; + *bsdes = 32; + break; default: /* Illegal trailer entry */ return false; -- 2.19.1