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 C82F1C54791 for ; Wed, 13 Mar 2024 16:25:50 +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=EBaW4w4G17JxN5QCZyFLX5U4jf+4LoJi/L/llgHJwYA=; b=W3zxo+zjbaI1DD 6m9HTh5lTrFQ8BRqQfYHCW1W3/m60V/iWMxBP+HGOwZycFDPQt9BMmzkvxowMqJqaGXdAnl191Nfo SlwsLCyayfGBuVrXN9n0gShQED2fzHzKXP2/kNvvdE09TCBBpmIdpKWf/iN8crkhadEX4FHVPNbOv ySijxNaYDh0Vowew7H+l9v8EeVckScerYJhNS0Z+Dq4ShHe/Qfh1aJi/amnGzmTu9stpFXujT6zm0 MZrYwhWGW/DIpk0ROmVKr3LVc3JtP7F1j63w0MlZRlOFo9j3lMr0BZbJP607eeF1+IXto7yuZGfMS BxcsyDIfXGe0CjDaVhTQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rkRQB-0000000AlPY-0hvs; Wed, 13 Mar 2024 16:25:39 +0000 Received: from mail-pf1-x42e.google.com ([2607:f8b0:4864:20::42e]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rkRQ8-0000000AlP0-3hqN for linux-arm-kernel@lists.infradead.org; Wed, 13 Mar 2024 16:25:38 +0000 Received: by mail-pf1-x42e.google.com with SMTP id d2e1a72fcca58-6e6b54a28ebso75439b3a.2 for ; Wed, 13 Mar 2024 09:25:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1710347136; x=1710951936; 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=fYxzXCVmzr66awhRoPiulHCLdn6odFpvWPqlxUZTg40=; b=wBRF5f0SKXWqS/8byFKZbpBej9FIgEh+98xOWkBu6T4k/mO3i3RNBWMvcxjWNc/c7Z nJup8mz7oZfumyiOJBD/CigiMbmJVMHoiDnRwAfgEfgR9huJICOUjyz/iNqEWJD81mc3 EU2qhQi1II+dXQBdaXD26dx8eK/rU/xWLyxTyR8Wky7/KMSfPNusrryrLrcFx5kQkJPP 60XGMTLbUplj8Ld6p+SnqqKSVlh4PhNGTp9UbU0HnvI2groupxxDZMySxyWtSLgswWnm 8dr/uXYQZZL6Zg5uScA5S6kcLeWiNPH840mMOTY2x69CxsfSkBbI3dmMXkkhh5wuJ7uL UT8w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710347136; x=1710951936; 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=fYxzXCVmzr66awhRoPiulHCLdn6odFpvWPqlxUZTg40=; b=LhAd1HAoshHCLXlVdtvlYPjS0AqGu2zM3k7eefWhGlFhX96qNGATmH9SlwevGAow/9 GymrPvACaJgm12Tn9A+XZQIZXlhFxLhFBhrL5bcTlTuX3w7yznnI2ExkPtyJ+Lad0l8o NJ07LNYoE0VBapfVvy+VkXx0cltGLWH9RFBpx3Q9wjVqesanF3eWsKuqHaXxB49WvxQ8 HaRMtnDQqZbufTTqAWckyIwhkluC9ebMlLIENXVpyRWFxVUvPGmhEdF0NlvBT4KmVaEp 0xP1Vb0XQMFua1wfe2uKndY8yKtGwQQttXRtpnXVlDv+lFRrvEgbVygu2mluzzHezNLR W6Zg== X-Forwarded-Encrypted: i=1; AJvYcCVbKzWetJtDI6MC2yaN0Sb5/+IMqVvAIxtJhQ0vN7YH63WOOQ/Tul+MRjXCNKDQZt0fbcp5jf87HJARy59Xuy+EzU1fnXyTmuVctSgAztjX/OaNohY= X-Gm-Message-State: AOJu0Yx74zeq7p/6zVHM6m9NxrVU0jDLlHF95m1+pV/+nfChey/Mcpyo x9BS2cgKtX2s3Lwc+2XUQ1v/aTeHIwm5G0BnkP7/Gwh2iIhWRFKuieigK1PvXdI= X-Google-Smtp-Source: AGHT+IGDDlbUcL/kmPgUIK2ocQ/+NVZ5EpvDYRvXae3NfxQmNd58fUdW3Xb6ch21rxY5N5eLOQx7sQ== X-Received: by 2002:a05:6a20:3956:b0:1a3:2fe9:ad74 with SMTP id r22-20020a056a20395600b001a32fe9ad74mr3319252pzg.44.1710347135680; Wed, 13 Mar 2024 09:25:35 -0700 (PDT) Received: from p14s ([2604:3d09:148c:c800:10b1:40f7:3529:d4f2]) by smtp.gmail.com with ESMTPSA id cl12-20020a056a02098c00b005e438fe702dsm6934633pgb.65.2024.03.13.09.25.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Mar 2024 09:25:35 -0700 (PDT) Date: Wed, 13 Mar 2024 10:25:32 -0600 From: Mathieu Poirier To: Abdellatif El Khlifi Cc: Bjorn Andersson , Rob Herring , Liviu Dudau , Sudeep Holla , Lorenzo Pieralisi , Krzysztof Kozlowski , Conor Dooley , Drew.Reed@arm.com, Adam.Johnston@arm.com, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-remoteproc@vger.kernel.org Subject: Re: [PATCH 1/3] remoteproc: Add Arm remoteproc driver Message-ID: References: <20240301164227.339208-1-abdellatif.elkhlifi@arm.com> <20240301164227.339208-2-abdellatif.elkhlifi@arm.com> <20240307194026.GA355455@e130802.arm.com> <20240311114442.GA82865@e130802.arm.com> <20240312173252.GA38992@e130802.arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20240312173252.GA38992@e130802.arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240313_092536_949664_F1169287 X-CRM114-Status: GOOD ( 41.89 ) 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 Tue, Mar 12, 2024 at 05:32:52PM +0000, Abdellatif El Khlifi wrote: > Hi Mathieu, > > On Tue, Mar 12, 2024 at 10:29:52AM -0600, Mathieu Poirier wrote: > > > This is an initial patchset for allowing to turn on and off the remote processor. > > > The FW is already loaded before the Corstone-1000 SoC is powered on and this > > > is done through the FPGA board bootloader in case of the FPGA target. Or by the Corstone-1000 FVP model > > > (emulator). > > > > > >From the above I take it that booting with a preloaded firmware is a > > scenario that needs to be supported and not just a temporary stage. > > The current status of the Corstone-1000 SoC requires that there is > a preloaded firmware for the external core. Preloading is done externally > either through the FPGA bootloader or the emulator (FVP) before powering > on the SoC. > Ok > Corstone-1000 will be upgraded in a way that the A core running Linux is able > to share memory with the remote core and also being able to access the remote > core memory so Linux can copy the firmware to. This HW changes are still > This is why this patchset is relying on a preloaded firmware. And it's the step 1 > of adding remoteproc support for Corstone. > Ok, so there is a HW problem where A core and M core can't see each other's memory, preventing the A core from copying the firmware image to the proper location. When the HW is fixed, will there be a need to support scenarios where the firmware image has been preloaded into memory? > When the HW is ready, we will be able to avoid preloading the firmware > and the user can do the following: > > 1) Use a default firmware filename stated in the DT (firmware-name property), > that's the one remoteproc subsystem will use initially, load the firmware file > and start the remote core. > > 2) Then, the user can choose to use another firmware file: > > echo stop >/sys/class/remoteproc/remoteproc0/state > echo -n new_firmware.elf > /sys/class/remoteproc/remoteproc0/firmware > echo start >/sys/class/remoteproc/remoteproc0/state > > > > The plan for the driver is as follows: > > > > > > Step 1: provide a foundation driver capable of turning the core on/off > > > > > > Step 2: provide mailbox support for comms > > > > > > Step 3: provide FW reload capability > > > > > What happens when a user wants to boot the remote processor with the > > firmware provided on the file system rather than the one preloaded > > into memory? > > We will support this scenario when the HW is upgraded and copying the firmware > to the remote core memory becomes possible. > > > Furthermore, how do we account for scenarios where the > > remote processor goes from running a firmware image on the file system > > to the firmware image loaded by an external entity? Is this a valid > > scenario? > > No, this scenario won't apply when we get the HW upgrade. No need for an > external entity anymore. The firmware(s) will all be files in the linux filesystem. > > > > Steps 2 & 3 are waiting for a HW update so the Cortex-A35 (running Linux) can share memory with > > > the remote core. > > > > > > I'm happy to provide more explanation in the commit log to reflect this status. > > > > > > Is it OK that we go with step 1 as a foundation please ? > > > > > > > First let's clarify all the scenarios that need to be supported. From > > there I will advise on how to proceed and what modifications to the > > subsystem's core should be made, if need be. > > Thanks, I hope the answers above provide the information needed. > > Cheers > Abdellatif _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel