From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9F0B03AE1A4; Mon, 16 Mar 2026 15:55:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773676535; cv=none; b=AStifAU0MWqb5OvU0uVkAL/ZQN1N/kBECncsybY8xgXg/zIcWv2dN03D8pJtInOf76f5uzGDndxhC+pLAlU6syrIDxxOfJrJX1oQ3qtM07oQZCdMjXvyfR+f1GM9s3Ak/Xxze5r2J9gozD0tnq7AtQbB62FBzpZAZw0DCz7FZQY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773676535; c=relaxed/simple; bh=IKgHntMPZOD67qALA6xcCjRWRPp1ZRXVfx/Qy0ZdoUc=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=VrJTKWIwv6zqDNgxKTwwWU+QzeVzfJ3Qg7ymhQXUL65zMf/v9w2UsKMFhNyu5VMgkB0tFj0GJpiPNObXuCIKmO0cm9HMDVGhzhQaZVDVZHB2lFWk14qiz/8IMm6Y0aNSDq1AhAnF0bEC+m7ZiQGsatXwPpPCqQMHbxRTetgvq2g= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 64AF114BF; Mon, 16 Mar 2026 08:55:25 -0700 (PDT) Received: from pluto (usa-sjc-mx-foss1.foss.arm.com [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 65FE23F778; Mon, 16 Mar 2026 08:55:30 -0700 (PDT) Date: Mon, 16 Mar 2026 15:55:27 +0000 From: Cristian Marussi To: Geert Uytterhoeven Cc: Sudeep Holla , Cristian Marussi , arm-scmi@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-renesas-soc@vger.kernel.org Subject: Re: [PATCH] firmware: arm_scmi: Support loop control in quirk code snippets Message-ID: References: <51de914cddef8fa86c2e7dd5397e5df759c45464.1773675224.git.geert+renesas@glider.be> Precedence: bulk X-Mailing-List: arm-scmi@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <51de914cddef8fa86c2e7dd5397e5df759c45464.1773675224.git.geert+renesas@glider.be> On Mon, Mar 16, 2026 at 04:34:40PM +0100, Geert Uytterhoeven wrote: > Each SCMI firmware quirk contains a code snippet, which handles the > quirk, and has full access to the surrounding context. When this > context is (part of) a loop body, the code snippet may want to use loop > control statements like "break" and "continue". Unfortunately the > SCMI_QUIRK() macro implementation contains a dummy loop, taking > precedence over any outer loops. Hence quirk code cannot use loop > control statements, but has to resort to polluting the surrounding > context with a label, and use goto. Hi Geert, I was just now writing the quirk for the Renesas issue and realized this limitation :P Do you want me to pick this up with the quirk template for Renesas issue that I am writing and post all in V3, or you have already the quirk too ? Thanks, Cristian