From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1F7AFCD1283 for ; Thu, 28 Mar 2024 14:53:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=/irovzEjHHOLJkzQP4X8lOhbULGcYYP2KgXBiZl8lKw=; b=rHfiZdJGJoM0KQ ycVd5PYGg+pIiXATxqxj/zvvxUmblqZR2D+74S3FUGHYj6QkdxdUUmWFzNfRpua0FzGqqswpr8A41 qLdLqQY5KOugSO0ggIdELH0ZY3OLTd5DdnLL//h2hesQjpyiWzFZoiTDgFvSNI/BZ7b7AldWZ5pRn MBJP0NZ8K3jcGlyW9Rsw47NKtSjHNkv9JgXhLGNGNMRjN67H8s1EKa7gnkjRhlDsqk12sWkKeoxDR iH7t4+n1DWhEPjAz+TSBscAeAygWJrDfQIrkBoE5hKy+vhwVJK6uWgKhSGCamv4gZ/y+X9Yl7BoOe mM8cWvXb/Hoc9tbDG3Qw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rpr85-0000000EP08-0nzJ; Thu, 28 Mar 2024 14:53:21 +0000 Received: from mail-pg1-x532.google.com ([2607:f8b0:4864:20::532]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rpr81-0000000EOuJ-0Mxt for linux-arm-kernel@lists.infradead.org; Thu, 28 Mar 2024 14:53:19 +0000 Received: by mail-pg1-x532.google.com with SMTP id 41be03b00d2f7-5dbf7b74402so622851a12.0 for ; Thu, 28 Mar 2024 07:53:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1711637590; x=1712242390; darn=lists.infradead.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=i35qdfnmzb8GcWwYT9amTA4CeZI1vlYQS9XoH1d0sPs=; b=WSW/PWOPG0GXRqz/HblzOTdJIz0dPkhxwTjwibUXkXbkdVMcyWMYOTF/lYXdqAEnwy UZkPiMG1fix8kN4Rk1pGEqtjXsakZUSOHRB2WKUQyY4i5uAozO6NhOumST6JARHl9ZQ/ 15dZ+wje1HgVxJWfJD7RkG73SDfYEKJG8U+6zXtmI5qtYD/a6AwEz61Ujdj/fZlZQjn+ /F71X4To7Pl6T0cYLXMjeeKPaF1ZQdg2o0FWr7xzbIGJnfqSGtGQ9e5udIeMkVMqzuDe 76QePUFCdIEW+1GDIh+eABCqMHyli8rd4b4N9gy3XVtsyT+uU9Rs2kiQyxighTZIPGsc QJTw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711637590; x=1712242390; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=i35qdfnmzb8GcWwYT9amTA4CeZI1vlYQS9XoH1d0sPs=; b=o6JTkOyWwKAWE43u5wf09TFxrYPx0IpCMW9tFsNiwyPiNetCN+G1Z/ZtdETmCxlPdd 2Ldv5ogKwyRfdAARcxN3ntk1ehLJ6E46EDwx32N0XWrXO1LvuAO5ITCXeW73c+zMhSnL 2VkGHBVeZu5k/kQNQ66JVKfhu9KzGdmEOY9+JQoSM+wJd2FxlMaO1vzf7Jt0Cwx4E2/h oZOlgKtAkm12yaUY7EoskIOnSx1maxB5ssnLaaklV/c9Ty4/vYJ/yJGYvPbgvtCIxqvS pKBI8v+a1oAVw0Dz5k54QkhxKYnbgKafSLRW5Vv2r5tIlcwi2Tnev1zlxFLFQzdcB+hA 7lMQ== X-Forwarded-Encrypted: i=1; AJvYcCXx8kyVYbmnpLr+Kmxk4ZHF/Fq1UUjiDTiHqan4pQHUlR4M+8RW39XrcgyTmMC83VtUxG/lx+vakaR4eDmSfx6ALvndYA0Peio8CZhNxo6f1etxMp4= X-Gm-Message-State: AOJu0YzxdUsc0KsBRuHm7gzL01Yd+1IrXZ3L56sL1t18mSyF8jpi4PpF vuzG7aXTmhF5gULKdgzMwDkl5USeoBZU2uatSJpY/eXcX/I88BGCUaB9KrbdcuA= X-Google-Smtp-Source: AGHT+IFmQyWLTIrei9uhVcpsua/EJMAf1wlCb+J0ByUinXtKBfHleN0nvLuKjv1Py6t/0BRIaGnASQ== X-Received: by 2002:a17:90a:7786:b0:2a0:4a33:c3a6 with SMTP id v6-20020a17090a778600b002a04a33c3a6mr2612491pjk.44.1711637589915; Thu, 28 Mar 2024 07:53:09 -0700 (PDT) Received: from p14s ([2604:3d09:148c:c800:ff63:c57b:4625:b68c]) by smtp.gmail.com with ESMTPSA id c1-20020a17090a490100b002a04eef22c5sm1565909pjh.44.2024.03.28.07.53.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Mar 2024 07:53:09 -0700 (PDT) Date: Thu, 28 Mar 2024 08:53:06 -0600 From: Mathieu Poirier To: Leonard Crestez Cc: Tanmay Shah , Bjorn Andersson , Michal Simek , linux-remoteproc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH] remoteproc: zynqmp: Add coredump support Message-ID: References: <07183fd8-a5a1-4cae-b317-d703ef7c1de1@gmail.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <07183fd8-a5a1-4cae-b317-d703ef7c1de1@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240328_075317_189983_BC9B4CB0 X-CRM114-Status: GOOD ( 33.06 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Mar 28, 2024 at 10:17:13AM +0200, Leonard Crestez wrote: > On 3/18/24 18:52, Mathieu Poirier wrote: > > Hi Leonard, > > > > I have queued patches for this driver that will break this patch. Please > > re-submit when v6.9-rc1 is out and rproc-next has been updated, which should be > > around the middle of next week. > > Hello, > > It's been a while - v6.9-rc1 is out and rproc-next has been rebased on top of > it. But the coredump patch still applies? I expected some unrelated > xlnx_r5_remoteproc patches to cause conflicts but there's nothing there. > > It seems to me that the patch can be applied as-is and no resend is required. > Am I missing something? > You're not missing anything. Back when I wrote my initial comment Tanmay had submitted patches to fix the way TCMs are initialized, which conflicted with your patch. There were some last minute modifications to Tanmay's patchset and I ended up not applying it, leading us to where we are today. Tanmay - please review and test this patch. Thanks, Mathieu > -- > Regards, > Leonard > > > On Sat, Mar 16, 2024 at 08:16:42PM +0200, Leonard Crestez wrote: > >> Supporting remoteproc coredump requires the platform-specific driver to > >> register coredump segments to be dumped. Do this by calling > >> rproc_coredump_add_segment for every carveout. > >> > >> Also call rproc_coredump_set_elf_info when then rproc is created. If the > >> ELFCLASS parameter is not provided then coredump fails with an error. > >> Other drivers seem to pass EM_NONE for the machine argument but for me > >> this shows a warning in gdb. Pass EM_ARM because this is an ARM R5. > >> > >> Signed-off-by: Leonard Crestez > >> --- > >> > >> Tests were done by triggering an deliberate crash using remoteproc > >> debugfs: echo 2 > /sys/kernel/debug/remoteproc/remoteproc0/crash > >> > >> This was tested using RPU apps which use RAM for everything so TCM dump > >> was not verified. The freertos-gdb script package showed credible data: > >> > >> https://github.com/espressif/freertos-gdb > >> > >> The R5 cache is not flushed so RAM might be out of date which is > >> actually very bad because information most relevant to determining the > >> cause of a crash is lost. Possible workaround would be to flush caches > >> in some sort of R5 crash handler? I don't think Linux can do anything > >> about this limitation. > >> > >> The generated coredump doesn't contain registers, this seems to be a > >> limitation shared with other rproc coredumps. It's not clear how the apu > >> could access rpu registers on zynqmp, my only idea would be to use the > >> coresight dap but that sounds difficult. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel