lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20201106191743.40457-2-james.quinlan@broadcom.com>
Date:   Fri,  6 Nov 2020 14:17:42 -0500
From:   Jim Quinlan <james.quinlan@...adcom.com>
To:     Philipp Zabel <p.zabel@...gutronix.de>,
        Hans de Goede <hdegoede@...hat.com>,
        Jens Axboe <axboe@...nel.dk>,
        bcm-kernel-feedback-list@...adcom.com, james.quinlan@...adcom.com
Cc:     Florian Fainelli <f.fainelli@...il.com>,
        linux-arm-kernel@...ts.infradead.org (moderated list:BROADCOM BCM7XXX
        ARM ARCHITECTURE), linux-kernel@...r.kernel.org (open list)
Subject: [PATCH v2 1/2] reset: brcmstb rescal: implement {de}assert() instead of reset()

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 <james.quinlan@...adcom.com>
---
 drivers/reset/reset-brcmstb-rescal.c | 13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/drivers/reset/reset-brcmstb-rescal.c b/drivers/reset/reset-brcmstb-rescal.c
index b6f074d6a65f..1f54ae4f91fe 100644
--- a/drivers/reset/reset-brcmstb-rescal.c
+++ b/drivers/reset/reset-brcmstb-rescal.c
@@ -20,8 +20,8 @@ struct brcm_rescal_reset {
 	struct reset_controller_dev rcdev;
 };
 
-static int brcm_rescal_reset_set(struct reset_controller_dev *rcdev,
-				 unsigned long id)
+static int brcm_rescal_reset_deassert(struct reset_controller_dev *rcdev,
+				unsigned long id)
 {
 	struct brcm_rescal_reset *data =
 		container_of(rcdev, struct brcm_rescal_reset, rcdev);
@@ -52,6 +52,12 @@ static int brcm_rescal_reset_set(struct reset_controller_dev *rcdev,
 	return 0;
 }
 
+static int brcm_rescal_reset_assert(struct reset_controller_dev *rcdev,
+			      unsigned long id)
+{
+	return 0;
+}
+
 static int brcm_rescal_reset_xlate(struct reset_controller_dev *rcdev,
 				   const struct of_phandle_args *reset_spec)
 {
@@ -60,7 +66,8 @@ static int brcm_rescal_reset_xlate(struct reset_controller_dev *rcdev,
 }
 
 static const struct reset_control_ops brcm_rescal_reset_ops = {
-	.reset = brcm_rescal_reset_set,
+	.deassert = brcm_rescal_reset_deassert,
+	.assert = brcm_rescal_reset_assert,
 };
 
 static int brcm_rescal_reset_probe(struct platform_device *pdev)
-- 
2.17.1


Download attachment "smime.p7s" of type "application/pkcs7-signature" (4167 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ