Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp51417pxt; Wed, 4 Aug 2021 15:30:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxyxqFztarbvx6K05UHCca/9O1rrtemwU9tm58qnL3/IttzgJSBPWFWPh0VBvLiF92gSOGf X-Received: by 2002:a17:906:a0ce:: with SMTP id bh14mr1317498ejb.434.1628116245507; Wed, 04 Aug 2021 15:30:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628116245; cv=none; d=google.com; s=arc-20160816; b=VPGU9rxGm26wM3dUlX8ZEE3Yd0swerK0/qEOeAjeW13GWlFxidMH44Iuohyn9BhFKk as29PZpoSNMV2Ti9OrXjpTtiX1cnaQ4kSxB1if6tsVbLeHnBDI1hlKgH1a963CXdKSLd /kELNWl54E3IUQw8JrSTNFmNk2CcDtptKhb3QyBSFzpN+JQnbl7SSxwhu0FzH7B+6vvm PWhMH5yts/cNIgE7CfGbFzd6mQ0WI5OkoL/A2A4WzM+aWSZZJo4S/xq6ocdefVfU1Y20 NecwFREBJ9BI6XOUXCriy8Z+oxmJlWbMkjlXd/A7QC4uJM8c7tDzHZsQSL3V4TFl0zcs +znQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=bRgs0NPKh4Mw3gD6S/OL3j4+WTypBMMGrOvKDK40lo0=; b=ZnV76ILjNwWtDIZqZD7b3w131zdHIGSiXA1YnjkOOtfA10uwLOx8/eqhJMFCz4r5Up 87Rm+X28vTtKJht8bdJSNyOpTsrM6wUAo923CKw7SnhRm4LeJhXV7BSJDl6V85cyhQbm xACW1UM/ixWzwYahRWZqT1nRY16zHYx9xDwL+ERrYhkLgOSbibk8xqbzEkY3EIShxHzP fifSuVM9fx+LJJ37titg5x89Pz7t4oF/p01r6E47QdSJ02rASgF71fS6hEP60H04bjlB HA4pD6ncjSfQquyqNKxrNzdMhxAedKCCQBNBSwrqQ1u0XhHF4Rb3KfuR15CiD4bgSo4X 6w/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=DbK0lw1B; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u92si3506178edc.287.2021.08.04.15.30.22; Wed, 04 Aug 2021 15:30:45 -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=@googlemail.com header.s=20161025 header.b=DbK0lw1B; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240096AbhHDVEX (ORCPT + 99 others); Wed, 4 Aug 2021 17:04:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32800 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240082AbhHDVEX (ORCPT ); Wed, 4 Aug 2021 17:04:23 -0400 Received: from mail-lf1-x136.google.com (mail-lf1-x136.google.com [IPv6:2a00:1450:4864:20::136]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 203FDC0613D5; Wed, 4 Aug 2021 14:04:10 -0700 (PDT) Received: by mail-lf1-x136.google.com with SMTP id f42so6734003lfv.7; Wed, 04 Aug 2021 14:04:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=bRgs0NPKh4Mw3gD6S/OL3j4+WTypBMMGrOvKDK40lo0=; b=DbK0lw1BL42tvqX/clZcnrxev3xx9WcpJBvlbzNzaBPpeLoZ/66un1phJ20lQtU7mp 3ovVprD8QmuPl5Ah3Z08GKO+RIJoHWc44HDT5iF3n812zdjNKCpywqzK1dYgOkeetMnZ aYlQSuwI2I3MXm8L+NuqZ7fYD8mQXyN83hsk0+4XMNtDPw7JelN0ENd9taOeknSMXtKY TfYQuFxzYrTd4+2qVKRQHmdRGOhCWliGByO9S8IUrk/OaQMnLJtZci9HA8rTyLfHDyPM nU6gl32lzkb5v0PXtk42himNI538Ad4HYhgm7Rw/UNe7a9986mYTW+jAGt52HCdCnTBV qupA== 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=bRgs0NPKh4Mw3gD6S/OL3j4+WTypBMMGrOvKDK40lo0=; b=LvUuXI5oYrf3jZ4jSRLZ5DMR1QIFfDpv8qVEK4y0gWsUt/37Q0/YLpkLJL8k/UUmfq ZZJL9rYo358gUjYAZkmVPqAMcgB6bAQ0LLEXb2+en9se6eV3IcIwYlAPRVQc8ygykts7 1DGOq5aAvrbdX5BIRRDv/WrCnCw9+SV4QN5Z7ziztnsxaYGkOSp4HkgbUvgCGbPYzzGK DEffYe2xOG5KsmwwsvTpWXuxbMCOrbSmxBCckIJKIAZEKffK1s0JsuJHiMb6AMYDbvfX szAqEiMTNIww0txNfd23xl++bqFMTqDPD7Ie73CIvHM6wpaitNjNcotH430qxz+gwvJ6 MDwg== X-Gm-Message-State: AOAM532proK+WBvru59n32UoLpxnMHs314/PLxvsre6gXgIR1QNHvWXo rrsPV4npR+su8cueaWYTZLvCrxesAOmZinLWw/s= X-Received: by 2002:a19:c202:: with SMTP id l2mr812180lfc.276.1628111048404; Wed, 04 Aug 2021 14:04:08 -0700 (PDT) MIME-Version: 1.0 References: <20210717234859.351911-1-martin.blumenstingl@googlemail.com> <20210717234859.351911-3-martin.blumenstingl@googlemail.com> <20210728175823.GA2766167@p14s> In-Reply-To: <20210728175823.GA2766167@p14s> From: Martin Blumenstingl Date: Wed, 4 Aug 2021 23:03:57 +0200 Message-ID: Subject: Re: [PATCH v3 2/2] remoteproc: meson-mx-ao-arc: Add a driver for the AO ARC remote procesor To: Mathieu Poirier Cc: linux-remoteproc@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, bjorn.andersson@linaro.org, ohad@wizery.com Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Mathieu, thanks for taking the time to look into this! (I will address any of your comments that I am not mentioning in this email anymore. Thanks a lot for the suggestions!) On Wed, Jul 28, 2021 at 7:58 PM Mathieu Poirier wrote: [...] > > + writel(FIELD_PREP(AO_REMAP_REG0_REMAP_AHB_SRAM_BITS_17_14_FOR_ARM_CPU, > > + priv->sram_pa >> 14), > Indentation problem The idea here is to align priv->sram_pa with AO_REMAP_REG0... which are both arguments to FIELD_PREP Maybe using something like this will make that easier to read: tmp = FIELD_PREP(AO_REMAP_REG0_REMAP_AHB_SRAM_BITS_17_14_FOR_ARM_CPU, priv->sram_pa >> 14); writel(tmp, priv->remap_base + AO_REMAP_REG0); What do you think: leave it as is or use a separate variable? [...] > > + usleep_range(10, 100); > > I've seen this kind of mysterious timeouts in other patchset based vendor trees. > You likely don't know why it is needed so I won't ask. unfortunately this is also the case here [...] > > + priv->arc_reset = devm_reset_control_get_exclusive(dev, NULL); > > + if (IS_ERR(priv->arc_reset)) { > > Function __reset_control_get() in __devm_reset_control_get() can return NULL so > this should be IS_ERR_OR_NULL(). The logic in there is: return optional ? NULL : ERR_PTR(-...); I am requesting a mandatory reset line here, so reset core will never return NULL See also [0] For this reason I am not planning to change this [...] > This driver is squeaky clean. With the above: > > Reviewed-by: Mathieu Poirier awesome, thank you! Best regards, Martin [0] https://elixir.bootlin.com/linux/v5.14-rc4/source/include/linux/reset.h#L227