From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F3BD437B032 for ; Fri, 31 Jul 2026 07:09:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785481780; cv=none; b=LB5S/GURTPLrEnV5MjbbKcFClzg42xCyTUc6a6C7un+iHlDtgnpbg6piMO2IXGk4PS6Z+s0nbFMCz8M99UrD816nRjdEWCgL7ncE+Rbhz9SLJMPK6L9SAxgObyM/KeqdOmA1irAXCC0/ktmhdnXKRBa2m8/FiZKNVrPTbCzLtUk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785481780; c=relaxed/simple; bh=yykASRB4YeTJFJ0dpDT9tzP0rhSrgrf2/Sov8HU9tks=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=iJqnrJdkOGEMhkE8ZCjNNe9J3ZyqS9/cyqb/V74dcLHiqGgryVkM3EDxYIS8+EBwdq1Whv4chzo/zKjGN5LDfJRRKckvqsd5sEYwHkV5t0zZPCqnlPiN3DwKQTT/xj7ZjeLYRRVt9cakBngLq53BRh0KIQ5nqISBb4yL/s/x5dI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=QHHBG5S6; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="QHHBG5S6" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E55D01F000E9; Fri, 31 Jul 2026 07:09:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1785481772; bh=rhw+Tc7eilLPGsXJEbmsKbbF/WcLk9AsnAtacOY+EQo=; h=Date:Subject:To:Cc:References:From:In-Reply-To; b=QHHBG5S6rLHEYM7zRgqzwdR7pkmHK/54agx4Bx43Wj0kmy8cAZmDrxho4pGu13FdB cYVNqaUJ3B+FUCMS/dD880/EYiR9l1BxYOJcAFjeEgQbxQGYGhWSO4oMCgATxvWwfq hd+x3mjDgfL6SF2JK8quTLJseMTYbpVgKptcaFGZ84vBrF6Z5pEK/1xJKCSErB4WA1 lZPiJEyT+lOB1ic5Sf/cTNL2KG8+X5wV0TQaQLDi9hZ6rYRCtSZl+axAe0Q8G+BWyF eY2N5sC4Ri8JeVpDe11DbU8miOidFSr93lOCcoNHNmZwLTKtK9aaOpxBTorwu2TxZA Ki7VPuj0Ic6EA== Message-ID: <1024f0e7-b9b5-4f5d-b0f5-5e7f08c51cbe@kernel.org> Date: Fri, 31 Jul 2026 09:09:29 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] powerpc/ps3: Use cpu_relax() in ps3_create_spu() To: Thorsten Blum , Geoff Levand , Madhavan Srinivasan , Michael Ellerman , Nicholas Piggin Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org References: <20260720231153.116827-2-thorsten.blum@linux.dev> Content-Language: fr-FR From: "Christophe Leroy (CS GROUP)" In-Reply-To: <20260720231153.116827-2-thorsten.blum@linux.dev> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Le 21/07/2026 à 01:11, Thorsten Blum a écrit : > Use cpu_relax() to wait for the execution status SPE_EX_STATE_EXECUTED. > Drop the comments while at it. > > Signed-off-by: Thorsten Blum Reviewed-by: Christophe Leroy (CS GROUP) > --- > arch/powerpc/platforms/ps3/spu.c | 10 ++++------ > 1 file changed, 4 insertions(+), 6 deletions(-) > > diff --git a/arch/powerpc/platforms/ps3/spu.c b/arch/powerpc/platforms/ps3/spu.c > index e4e0b45e1b9d..8545c72385de 100644 > --- a/arch/powerpc/platforms/ps3/spu.c > +++ b/arch/powerpc/platforms/ps3/spu.c > @@ -13,6 +13,7 @@ > #include > #include > #include > +#include > > #include > #include > @@ -363,12 +364,9 @@ static int __init ps3_create_spu(struct spu *spu, void *data) > if (result) > goto fail_enable; > > - /* Make sure the spu is in SPE_EX_STATE_EXECUTED. */ > - > - /* need something better here!!! */ > - while (in_be64(&spu_pdata(spu)->shadow->spe_execution_status) > - != SPE_EX_STATE_EXECUTED) > - (void)0; > + while (in_be64(&spu_pdata(spu)->shadow->spe_execution_status) != > + SPE_EX_STATE_EXECUTED) > + cpu_relax(); > > return result; >