From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mout-p-202.mailbox.org (mout-p-202.mailbox.org [80.241.56.172]) (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 953642F3C19; Wed, 8 Jul 2026 22:31:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=80.241.56.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783549908; cv=none; b=UGdbB+YTVOaR3R49QLcwI57LiPHTgpTtR+8m7LWjLYrKHRyykWGQPGeW/GKXm7J35j/cciS3NZHMnbW8UP2X9FthxcVRlbOpegv/4e87pq9oaynVMUgc2hJ7YDqnFyZsXg16QZyt8InOh+fw9N0S8HKlcS0MSRKcJ4D1DbLYyzg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783549908; c=relaxed/simple; bh=TwPNIap4o9alfoMGrHjKWF4JR0px4d7fD/wJeY6TlV0=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=laC7jUOszs6z0CUsVMIWlwW1kbn3bjhLdvQdTCuWLJbkSV/ScRgJ7YTB5pZwAyTfYSemW/j75Aj3Br0JWqqjc6unEzwiym+8lp1XGMA8edz80XIcNfAVuF+0GAiFWH8hGstxOl8YakmBUvbc3itNppld0T/g3bYZ9dizpHowDas= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=mailbox.org; spf=pass smtp.mailfrom=mailbox.org; dkim=pass (2048-bit key) header.d=mailbox.org header.i=@mailbox.org header.b=k2eHq3Y1; arc=none smtp.client-ip=80.241.56.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=mailbox.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mailbox.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mailbox.org header.i=@mailbox.org header.b="k2eHq3Y1" Received: from smtp202.mailbox.org (smtp202.mailbox.org [10.196.197.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA512) (No client certificate requested) by mout-p-202.mailbox.org (Postfix) with ESMTPS id 4gwXrb2NCfzMlHw; Thu, 09 Jul 2026 00:31:43 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailbox.org; s=mail20150812; t=1783549903; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=153NGcG1DPWuSXRcq4z9zBLGMIc6zuyh1qAdI4RAZiI=; b=k2eHq3Y1gdAukQn2jHL3lPY6q2pTwZmYCQfEiX/3LfjZH+0YnWX76gdlkczjxYYo95aUJz hdonlaaoddJsyIm2RDY9iqEGDfG8vIn73MoJ6JiCcj4+OWYLImLmM2hMgqyvijNB6osGU1 IueO2hsKXV3lNyJbRQSYwig1PQmGB4/bb4MglHtRoyYYmB9bJwAobTCzll46KpA+LWGsbX +XffLbtofMiAckleXsbpoxo/DlAk4PxOo34VE/LTUMF/qI6YeJykz+hItU/NA6SqEEnh1r 0ahc95ox2Uw3F6rvCFp55XsE8SiTiwbrNeDuYS0+Sx32pKv/IGOqmXEoa+RRgg== Message-ID: <9ecabfec-d428-4c64-b398-4e80baaf3752@mailbox.org> Date: Thu, 9 Jul 2026 00:31:40 +0200 Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Subject: Re: [PATCH 2/2] gpio: rcar: Add R-Car X5H (R8A78000) support To: Geert Uytterhoeven Cc: Bartosz Golaszewski , Conor Dooley , Krzysztof Kozlowski , Linus Walleij , Rob Herring , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-gpio@vger.kernel.org References: <20260704151521.211335-1-marek.vasut+renesas@mailbox.org> <20260704151521.211335-2-marek.vasut+renesas@mailbox.org> Content-Language: en-US From: Marek Vasut In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-MBO-RS-ID: 272722f82881645b40f X-MBO-RS-META: 1mwb6twn3dfq1me165a49ir9q7udb4g3 On 7/7/26 8:52 AM, Geert Uytterhoeven wrote: Hello Geert, >> On 7/6/26 11:19 AM, Bartosz Golaszewski wrote: >>>> +static inline int gpio_rcar_remap_offset(struct gpio_rcar_priv *p, int *offs) >>>> +{ >> >> I am hoping to get some input on this remap function. > > I haven't looked at your patch in detail yet, but the remap function > was the first thing that struck my eyes. This might impact performance > of bit-banging and of the sloppy logic analyzer. Regarding the performance impact -- yes, this will impact performance. Both the remap function and register table look up will, but at least the remap function is small and (subset of it) ends up inlined, the indirect look up table is bigger and unlikely to be inlined. That is why I opted for this over a table look up. > Have you looked at the code generated by the compiler? I did, but there is a lot of inlining going on. > Perhaps it would be better to use a table, like sci_port_params.regs[] > in the sh-sci driver, and riic_of_data.regs in the riic driver? Please see above. [...] -- Best regards, Marek Vasut