Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp1581102ybg; Thu, 4 Jun 2020 13:30:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzUIeDj+k26ymjNA67YlBb8VV/d+Sc/w1jBRHVgq2pvSPkiIX6AXDKffO1MLCE/9jtHYD60 X-Received: by 2002:aa7:d283:: with SMTP id w3mr6142571edq.262.1591302607375; Thu, 04 Jun 2020 13:30:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591302607; cv=none; d=google.com; s=arc-20160816; b=C5GtMA/QljwGku6+UaVuJdJOYObJuCOWcoIY2pMY1OEagCrx/qCtAlXtDlz32So+8L W8lKnlANApAkpqqckxORGDU8X4hpSawBIuHjykxbrgrFkQuebRUkzWyP4i9sIIqwapWh FDawntjRHz/Z0qNO/If0OgzG1Y60uUwwS6Z2azLb2IidppvRDk8lxLnvVR953pHABY6e nBTEt6syc4jYoGwXWziiC+WNqxgdrgMne0gIEniGqzQc11dKDh8DV48trKvMQImZNKS5 J6LKgyRQzf5N+xPlTLMQE/33gSKYL88RiGqab9ESeFgqyUfh6h5WwaFAQ1NzqmN3nf1e xwKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=cIgVS8ggkjhxB0JoJojRceUX9GryrMeDRowoa0T2ICw=; b=V1ER1sNqJzuyF2DHVSz713GpJrT/Ca1kolc4su8FJdjepWSm1Zm29ZO879FhwKlslX uDyDBUXxfsB7K8VSyOD5tEIgowTCRyC6Gm7hTs+LN2Q59lREoWJEg51CMCYzBTdvaE0R KvaqvotjkIek/t8nJBcZODqlNueWsFQiicotoDzbc4AUWw2xDmWqf/JUrl/+Sn5qNsSx f4cY6513mD1hcnT45MqZpbUlmoZ3e2aOJW1yWbC1IEvd1e9Uxy8DyWzaGG1RQ24T7OYt d/CfVIvDsUYJFEz3beU7Bc6fDhztkrHPacIBFhdPZviN4NGpYYgRKURE35vC29lwpoCO XwYA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PmkevgLV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u6si2203093ejn.111.2020.06.04.13.29.43; Thu, 04 Jun 2020 13:30:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PmkevgLV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729853AbgFDU1d (ORCPT + 99 others); Thu, 4 Jun 2020 16:27:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52554 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728752AbgFDU1d (ORCPT ); Thu, 4 Jun 2020 16:27:33 -0400 Received: from mail-io1-xd41.google.com (mail-io1-xd41.google.com [IPv6:2607:f8b0:4864:20::d41]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 97B9CC08C5C2 for ; Thu, 4 Jun 2020 13:27:32 -0700 (PDT) Received: by mail-io1-xd41.google.com with SMTP id s18so7884011ioe.2 for ; Thu, 04 Jun 2020 13:27:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=cIgVS8ggkjhxB0JoJojRceUX9GryrMeDRowoa0T2ICw=; b=PmkevgLVw0MJkySoUuAV4KjwhxjrSugxZVs3t7ZgLbW+hH6bGVCkDpHNCQOp3dzFRn 59sEJdR8Ilwa/jfy9rErHPpp4lr5TDsowJRUdgab+6o7x7X4YDxyTROH1vSRKXXJmRt5 ai86SvPojqS2mw90PUpX1D/anPL9xfbtHr254pasWlf4hLzV/NEJRe200wNIuWFEImhd 0CaTPDx74hKuyopOCTc7cxjpxxTXgc4EYjSbzJglWsHVEhvpSEtlCzf+luwwDgMkcB3+ pemWmzfJeatJQ2XMNd2bjltqSNtD1xqWNThs1yzSikgadfUaVOSXWT/p/94BuM+DSjjT s6Hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=cIgVS8ggkjhxB0JoJojRceUX9GryrMeDRowoa0T2ICw=; b=KonKYO5cJEciLYfIPAxrvaYbYM+NhptzZDgmvVbDQXdf16XIbe4/YfT5JBQXOmJJDX J1/7G7E9iQHaWzjULcPbZEf25p0nKx4+sqIAOf7PZ1qbPvYBuwDOQfil1pdOXgLlMSgY QBZXx91BQJWnp0qB2oDMU4Bjr00B+xo2J1nrL4OZNA3W/qGsqsAj8E8VHDQGcLRQkjwo oROQs5RRZ7ki/f/xC9rgJ3EO38yjVbQiQelMkHQcVkAaeARKaNM2Ry9b82dasyeTSgaM yJVYGZjGOalRaRYOSodWKtMbH/FOdA2aozaJp/VQbplAQe1L9q6/cDKo2m+4FExIAE+6 BuOQ== X-Gm-Message-State: AOAM531uyv3HZrOfBSQ5aoK5LYSEss792eJpJISmq8FRUi83O8L6msQR NHg2ujjS249ornxTPEvHKwiTMmJ2xV8dpyjNKPWGFw== X-Received: by 2002:a05:6602:224a:: with SMTP id o10mr5387683ioo.90.1591302452004; Thu, 04 Jun 2020 13:27:32 -0700 (PDT) MIME-Version: 1.0 References: <20200601175139.22097-1-mathieu.poirier@linaro.org> <0780724c-4fc0-9f98-023e-aa1245b01888@st.com> In-Reply-To: <0780724c-4fc0-9f98-023e-aa1245b01888@st.com> From: Mathieu Poirier Date: Thu, 4 Jun 2020 14:27:21 -0600 Message-ID: Subject: Re: [PATCH v4 0/9] remoteproc: Add support for attaching with rproc To: Arnaud POULIQUEN Cc: "bjorn.andersson@linaro.org" , "ohad@wizery.com" , "linux-remoteproc@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Loic PALLARDY , "s-anna@ti.com" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 4 Jun 2020 at 08:24, Arnaud POULIQUEN wrote: > > Hi Mathieu, > > On 6/1/20 7:51 PM, Mathieu Poirier wrote: > > This fourth iteration implements a solution that is fairly different from > > what was proposed in V3 and earlier versions. Three aspects have been > > revisited: > > > > 1) Only the scenario where the remoteproc core is attaching to the remote > > processor is implemented. Other scenarios where actions need to be > > taken when the remote processor is stopped or crashes will be > > considered in subsequent versions. > > > > 2) The introduction of a new RPROC_DETACHED state to be set by platform > > drivers when needing to attach to an already running remote processor. > > > > 3) New functions are introduced to replicate the functionality provided by > > rproc_fw_boot() and rproc_start(), minus operations related to firmware > > management. > > > > Enhancement to the documentation has been left out intentionally until it > > is agreed to move forward with this implementation. > > Look good to me, i have only a minor concerns about the code duplication > introduced by the point 3) > This is an idea Bjorn and I have decided to try in the hope of making the state machine, and the feature as a whole, easier to understand. It might be one of those rare cases where more code is better. > If you are agree with that, I plan to do a new review on the stm32 series > when you will start the documentation :-) A wise decision... Thanks for taking the time to look at this, Mathieu > > Regards, > Arnaud > > > > > Applies cleanly on rproc-next(7dcef3988eed) and will be rebased on v5.8-rc1 > > when it comes out in two weeks. > > > > Thanks, > > Mathieu > > > > Mathieu Poirier (9): > > remoteproc: Add new RPROC_DETACHED state > > remoteproc: Add new attach() remoteproc operation > > remoteproc: Introducing function rproc_attach() > > remoteproc: Introducing function rproc_actuate() > > remoteproc: Introducing function rproc_validate() > > remoteproc: Refactor function rproc_boot() > > remoteproc: Refactor function rproc_trigger_auto_boot() > > remoteproc: Refactor function rproc_free_vring() > > remoteproc: Properly handle firmware name when attaching > > > > drivers/remoteproc/remoteproc_core.c | 226 +++++++++++++++++++++-- > > drivers/remoteproc/remoteproc_internal.h | 8 + > > drivers/remoteproc/remoteproc_sysfs.c | 17 +- > > include/linux/remoteproc.h | 9 +- > > 4 files changed, 243 insertions(+), 17 deletions(-) > >