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 X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 91C69C2D0A3 for ; Mon, 9 Nov 2020 17:25:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4A88C20897 for ; Mon, 9 Nov 2020 17:25:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731692AbgKIRZq convert rfc822-to-8bit (ORCPT ); Mon, 9 Nov 2020 12:25:46 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34068 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731502AbgKIRZp (ORCPT ); Mon, 9 Nov 2020 12:25:45 -0500 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B3882C0613CF for ; Mon, 9 Nov 2020 09:25:45 -0800 (PST) Received: from lupine.hi.pengutronix.de ([2001:67c:670:100:3ad5:47ff:feaf:1a17] helo=lupine) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kcAvF-0007PG-FW; Mon, 09 Nov 2020 18:25:41 +0100 Received: from pza by lupine with local (Exim 4.92) (envelope-from ) id 1kcAvE-0008DX-H5; Mon, 09 Nov 2020 18:25:40 +0100 Message-ID: <2ee2fb9170e127d583e19062a791f3b1767d44fc.camel@pengutronix.de> Subject: Re: [PATCH v2 1/2] reset: brcmstb rescal: implement {de}assert() instead of reset() From: Philipp Zabel To: Jim Quinlan , Amjad Ouled-Ameur Cc: Hans de Goede , Jens Axboe , "maintainer:BROADCOM BCM7XXX ARM ARCHITECTURE" , Florian Fainelli , "moderated list:BROADCOM BCM7XXX ARM ARCHITECTURE" , open list Date: Mon, 09 Nov 2020 18:25:40 +0100 In-Reply-To: References: <20201106191743.40457-1-james.quinlan@broadcom.com> <20201106191743.40457-2-james.quinlan@broadcom.com> <64aa1f860bf60ddac7a2015c87896c8a7b13b161.camel@pengutronix.de> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT User-Agent: Evolution 3.30.5-1.1 MIME-Version: 1.0 X-SA-Exim-Connect-IP: 2001:67c:670:100:3ad5:47ff:feaf:1a17 X-SA-Exim-Mail-From: p.zabel@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2020-11-09 at 11:21 -0500, Jim Quinlan wrote: > On Mon, Nov 9, 2020 at 5:05 AM Philipp Zabel wrote: > > Hi Jim, > > > > On Fri, 2020-11-06 at 14:17 -0500, Jim Quinlan wrote: > > > Before, only control_reset() was implemented. However, the reset core only > > > invokes control_reset() once in its lifetime. Because we need it to invoke > > > control_reset() again after resume out of S2 or S3, we have switched to > > > putting the reset functionality into the control_deassert() method and > > > having an empty control_assert() method. > > > > > > Signed-off-by: Jim Quinlan > > > > You are switching to the wrong abstraction to work around a deficiency > > of the reset controller framework. Instead, it would be better to allow > > to "reactivate" shared pulsed resets so they can be triggered again. > > True. > > > > Could you please have a look at [1], which tries to implement this with > > a new API call, and check if this can fix your problem? If so, it would > > be great if you could coordinate with Amjad to see this fixed in the > > core. > > > > [1] https://lore.kernel.org/lkml/20201001132758.12280-1-aouledameur@baylibre.com/ > > Yes, this would work for our usage. Amjad please let me know if I can > help here. The only "nit" I have is that I favor the name 'unreset' > over 'resettable' but truly I don't care one way or the other. Both unreset and resettable are adjectives, maybe it would be better to have an imperative verb like the other API functions. I would have liked reset_control_trigger/rearm as a pair, but I can't find anything I like that fits with the somewhat unfortunate reset_control_reset name in my mind. In that sense, I don't have a preference one way or the other either. regards Philipp