Received: by 2002:ac0:aed5:0:0:0:0:0 with SMTP id t21csp5886056imb; Fri, 8 Mar 2019 04:45:01 -0800 (PST) X-Google-Smtp-Source: APXvYqxhamGLcQ/dTD3b27vYL496YVDjKMXEk7bGgnNp5ai4RfWsYBR2CnB2TpuapynyguTa04dt X-Received: by 2002:a17:902:ea85:: with SMTP id cv5mr18105140plb.119.1552049101864; Fri, 08 Mar 2019 04:45:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1552049101; cv=none; d=google.com; s=arc-20160816; b=M4MBJ0vu6Vmcwkwk+VmT8v+JQsD0HWECBO5nmUkYXM9z/s11zTvveUpMMLgvsj56Rf VZO5xPEvU2siA4QQaWzkGfpe5AF/P6Kcs5/gCM7ZoPs25j7yXzMks1kTPW+HATcg60hf 3z73TVgq8PcOHr31mZXrnoFQ0PJ0Dq7bgne40O3+tNLl00v0iSINDXyS+hlrx606olbw X3LzdEpd+UU7dopdJFal/vHfytyX6eM8dw9y1yBinCjxtSILCVdpWJzhshhAa1b5r5Vp vJwLLHXnZsR2MCF6ZjU2oPNWvBHZXrTpq80txlv524OXt9LdBMx/qN+2YIVFiIWQUkoK UrNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=qLnzn2Tse4CfxyiYn6Qj09MwXukENfGfqu3rPuxVE+A=; b=iljoBuDqQ1cNBnCWb7K0ppvxOSSHLLWA+JUiNYnnIWdK3g2epGpcf39YYCAW6phMVn 9GYL31xuqEXw+dk+CssimIjfNRueVX2SI+AhkxEmNnW9F65a7gAPinPka8l2uiogtC5Z anhZEDWV1GpNMsJw3Z+RvQlNT8VVTC4UK5yKieZk9I5iDAWB/7+oBXGGp9Ks7Gtdxhvt OL9GTAEvFejnaWiD1DEExJb7FA/QYP30QUcvmTk8jrQmb1S/iOdfKff9bNXBJTOIoPzv R7zBG03BBgldn1U6I1tVhviza0BPidQ05sqeJVt6mCe32S9jW1EfUdJoTCP8Y7uMltFz MmGg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=u17Z+HVu; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id h8si6376517pgq.35.2019.03.08.04.44.46; Fri, 08 Mar 2019 04:45:01 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=u17Z+HVu; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1726480AbfCHMm4 (ORCPT + 99 others); Fri, 8 Mar 2019 07:42:56 -0500 Received: from mail-ot1-f68.google.com ([209.85.210.68]:36662 "EHLO mail-ot1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726392AbfCHMm4 (ORCPT ); Fri, 8 Mar 2019 07:42:56 -0500 Received: by mail-ot1-f68.google.com with SMTP id v62so17229880otb.3 for ; Fri, 08 Mar 2019 04:42:55 -0800 (PST) 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:content-transfer-encoding; bh=qLnzn2Tse4CfxyiYn6Qj09MwXukENfGfqu3rPuxVE+A=; b=u17Z+HVuhJTuMSMKtC8Agkvm17fGdRUkXl1I4jbLPEZxTPbNynlmzbHhfaG3HVzmmS p6U3Tc3eR2BrbwULTDLb86WSNV8x5ngwyip4CcxtzyGUjTn67gBVrqY6VJ9xde+MEt8i 4D5Ie8y8yXbouL9n8xXBBtzIZosISS5aHQqGNKSRY+CDHHxukZb5DPjmTWqz5HzyvbW4 M1cEKZ/kLwyRF/sjDeKMMJGXog9ponIaLHOb/8ohCIq1xRLbNNUfXOqqjjOw8nD0dbvN hwaj2RQdGa396sqVITHYLxDXCQDOvrC+gAnr+Unp/LRz134SrzmGDh4wHzoeKrU19syC sSRw== 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:content-transfer-encoding; bh=qLnzn2Tse4CfxyiYn6Qj09MwXukENfGfqu3rPuxVE+A=; b=s5Zzpva3js6gfn1nwg8Pf81IsYJvZ6oLF6qyjYGimWym21opA9Rsh7vDJTPw6ebpBt 23DhOicn/kjz2KUerREsL4+GzrcqpZ7S+XYtLmNU7dFoNjwPjvp2oZcYmyf9oRWcvXur tgRUortgZh0GcpptjKlfK0nNPm9BUHUDyMWy8aUAxHfhcNX3BWuX5P+13PbmraqoFj8Y Pi24skGsyaD7TjdRUo7ntcIS05Gbfx8vvwB4xqF5/zyIiT48rVg0Af3tTj9JzXoISaTq 2KHJn79EuDzYr07/XAn1aI2z9Q4HUeF9v6VTnDsYdg+1Bz99fwSnor9dI/6CSfE1rnNo f2XQ== X-Gm-Message-State: APjAAAVcbWLlVZ/Mdyl0JMkvv3fP39+15bcYrGg7xq/X7wa10yBGoAHg LDegDP1/DnGTu+ueyHXObLwJNCRno1fe9AaebK69Vg== X-Received: by 2002:a05:6830:1543:: with SMTP id l3mr11835790otp.84.1552048974888; Fri, 08 Mar 2019 04:42:54 -0800 (PST) MIME-Version: 1.0 References: <1551973336-23048-1-git-send-email-fabien.dessenne@st.com> In-Reply-To: <1551973336-23048-1-git-send-email-fabien.dessenne@st.com> From: Benjamin Gaignard Date: Fri, 8 Mar 2019 13:42:44 +0100 Message-ID: Subject: Re: [PATCH] hwspinlock: stm32: implement the relax() ops To: Fabien Dessenne Cc: Ohad Ben-Cohen , Bjorn Andersson , Maxime Coquelin , Alexandre Torgue , linux-remoteproc@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, Linux ARM , Linux Kernel Mailing List , Benjamin Gaignard Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Le jeu. 7 mars 2019 =C3=A0 16:42, Fabien Dessenne = a =C3=A9crit : > > Implement this optional ops, called by hwspinlock core while spinning on > a lock, between two successive invocations of trylock(). > > Signed-off-by: Fabien Dessenne Reviewed-by: Benjamin Gaignard > --- > drivers/hwspinlock/stm32_hwspinlock.c | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/drivers/hwspinlock/stm32_hwspinlock.c b/drivers/hwspinlock/s= tm32_hwspinlock.c > index 4418392..c8eacf4 100644 > --- a/drivers/hwspinlock/stm32_hwspinlock.c > +++ b/drivers/hwspinlock/stm32_hwspinlock.c > @@ -5,6 +5,7 @@ > */ > > #include > +#include > #include > #include > #include > @@ -42,9 +43,15 @@ static void stm32_hwspinlock_unlock(struct hwspinlock = *lock) > writel(STM32_MUTEX_COREID, lock_addr); > } > > +static void stm32_hwspinlock_relax(struct hwspinlock *lock) > +{ > + ndelay(50); > +} > + > static const struct hwspinlock_ops stm32_hwspinlock_ops =3D { > .trylock =3D stm32_hwspinlock_trylock, > .unlock =3D stm32_hwspinlock_unlock, > + .relax =3D stm32_hwspinlock_relax, > }; > > static int stm32_hwspinlock_probe(struct platform_device *pdev) > -- > 2.7.4 > > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --=20 Benjamin Gaignard Graphic Study Group Linaro.org =E2=94=82 Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog