Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp136940ybl; Tue, 3 Dec 2019 23:30:47 -0800 (PST) X-Google-Smtp-Source: APXvYqyw8C4j8h8RnyT5+v/9E+OgnO8AmeKmiJQiGgRu/Ppa3LQrsT0zP7BaoWuiHnNs7Zh5DRU+ X-Received: by 2002:aca:ddc2:: with SMTP id u185mr1528603oig.174.1575444647009; Tue, 03 Dec 2019 23:30:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575444646; cv=none; d=google.com; s=arc-20160816; b=Hlz5kNQ8enbOegRrg0PQdsJEcq7tK2rMK2O2m51C5g1R1+ll3Yd3gj3HvYxmitnT9e bSK44accl+34T3T/O8FBT4uY9srUquaCuXUyrCdXwD02dxuyQzGyETroPsj/N72mq5Xp RoJp0hwu2JNu089lquFvAVWGPE6y2h3sqVimJyYE1zVH/2VWcDbFk01YXdHxFy1J6RL4 WR5x3VmsXwA7nCBTfF9oEa+50iXquKl9ki8JZBWX0XuSseC64DEM9I99J2ptadaguB0h at7ApIO5WKZmEKto1Mfp+oHebmAXesveYGBrK76NfR7b4hZoIALSJj2c+0du9/3RmufA n48Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:organization:from:cc:references:to:subject; bh=bpJth3Yj+HVWe3+IYys+VV+virdbOh0fa/an0Bc1Gf0=; b=s7oVEePCfE1/VePOB3dt3DQFXvwmENLNpuLdYFCz5KXOT4fyCmo+QzyesHS/X/TWxl zI6NbJc6s4F1hHwsVvIZqtHXQyIdxYM57rm6sCtfzKsVFAUnzE3QcDhy62azUfGCdsPV 4YKwBPpQreSto0Sdk1Z3sFztxxODdsudws5h/jF9022hJ35hIN9Evh0HgYEHfDnGW+5p BVmghgE8ziNB8StqaOjT8ptpH03D22WrpPlGRuxlgM3ZpnulqwmarSuIPuYIAdWyu9XP m/hfErLCA+gXDkc0DVrAe0ZCeH7SN8msIdq4Dx02VK7iKuicH4/T7fOvsydTXNIt6Eld tJsQ== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i13si2760604oie.232.2019.12.03.23.30.32; Tue, 03 Dec 2019 23:30:46 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727136AbfLDH23 (ORCPT + 99 others); Wed, 4 Dec 2019 02:28:29 -0500 Received: from mx2.suse.de ([195.135.220.15]:42342 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725958AbfLDH23 (ORCPT ); Wed, 4 Dec 2019 02:28:29 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 349DBACA5; Wed, 4 Dec 2019 07:28:27 +0000 (UTC) Subject: Re: perf record doesn't work on rtd129x SoC To: Wang YanQing References: <20191204045559.GA10458@udknight> Cc: linux-kernel@vger.kernel.org, linux-soc@vger.kernel.org, linux-realtek-soc@lists.infradead.org, "linux-arm-kernel@lists.infradead.org" , Mark Rutland , Will Deacon From: =?UTF-8?Q?Andreas_F=c3=a4rber?= Organization: SUSE Software Solutions Germany GmbH Message-ID: Date: Wed, 4 Dec 2019 08:28:26 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.1 MIME-Version: 1.0 In-Reply-To: <20191204045559.GA10458@udknight> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi YanQing, + LAKML + Mark + Will Am 04.12.19 um 05:55 schrieb Wang YanQing: > I use "perf record" to debug performance issue on RTD1296 SOC, it does't work, but > the "perf stat" is ok! Thanks for the report - which board, branch and (base) tag are you testing against? And are you building perf yourself from kernel sources, or are you using some distro package? I only have Busybox in my initrd on DS418; I have not tested perf. > After some dig in the kernel, I find the reason is no pmu overflow interrupt, I think > below pmu configuration isn't right for RTD1296: > " > arm_pmu: arm-pmu { > compatible = "arm,cortex-a53-pmu"; > interrupts = ; > }; > " > > We need 4 PMU SPI for RTD1296 (4 cores), and I guess the 48 isn't right too. Note that above rtd129x.dtsi snippet is not complete. See rtd1296.dtsi: &arm_pmu { interrupt-affinity = <&cpu0>, <&cpu1>, <&cpu2>, <&cpu3>; }; 48 and high/4 match what I see in the latest BSP: https://github.com/BPI-SINOVOIP/BPI-M4-bsp/blob/master/linux-rtk/arch/arm64/boot/dts/realtek/rtd129x/rtd-1296.dtsi#L116 > Any suggestion is welcome. > > Thanks! The only difference I see is "arm,cortex-a53-pmu" vs. "arm,armv8-pmuv3". By my reading of arch/arm64/kernel/perf_event.c the only difference between the two should be the name and an extra cache_map. You could try the other compatible string in your .dts, but I doubt it'll help. Hopefully the Realtek or Arm guys can shed some light. Regards, Andreas -- SUSE Software Solutions Germany GmbH Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Felix Imendörffer HRB 36809 (AG Nürnberg)