From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4DE61ECAAD8 for ; Wed, 21 Sep 2022 21:06:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229713AbiIUVGJ (ORCPT ); Wed, 21 Sep 2022 17:06:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35164 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229437AbiIUVGH (ORCPT ); Wed, 21 Sep 2022 17:06:07 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 35DC2A2230; Wed, 21 Sep 2022 14:06:05 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id C8A44B828EC; Wed, 21 Sep 2022 21:06:03 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C545EC433C1; Wed, 21 Sep 2022 21:05:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1663794362; bh=4pEno27AZYa4mJMVJgAgsAXTI/+40ZvutoCLEOhJzGM=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=sDQSjVHV+zbK4QkKWAC0QEE3eleBlrxAN/lUEQ5+rlQRQ8/bSOSzaqbLEQulF+nml 7s+TcuZGAnf/JkUt5g4ywB3NSBlS2B6tt/4DXjig42OddiO9OeK1x0zCdGCU8OM3sO LUQ9IYbV+QND4jdV4/Gkhakzqz4ohno535eWT03xlFMdGj2mj2j0MaqRGwdaCMC63J iCWm/AqP2rr6PVKVVoaq2SL+Cu5FwRhLjEyJ3PEqQMni6BL1zOpx9lLLHXxc4cP2wp Gte9njqBesBn2vyIwu8t7Y4w/WzUIMXbmeMVGLK+XKgXIy5ESVh1xqu/P4GAFlEqjq qCvJXSBwUD7bg== Date: Wed, 21 Sep 2022 22:05:55 +0100 From: Conor Dooley To: Geert Uytterhoeven Cc: Krzysztof Kozlowski , "Lad, Prabhakar" , Rob Herring , Krzysztof Kozlowski , Andre Przywara , Conor Dooley , Samuel Holland , Biju Das , Chris Paterson , Atish Patra , "Lad, Prabhakar" , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , linux-riscv , Linux ARM , Linux-Renesas , Linux Kernel Mailing List , Arnd Bergmann , Olof Johansson Subject: Re: Similar SoCs with different CPUs and interrupt bindings Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Sep 21, 2022 at 12:08:11PM +0200, Geert Uytterhoeven wrote: > Hi Krzysztof, > > > This worked as expected, but couldn't get the arithmetic operation > > > working. Could you please provide an example? > > > > diff --git a/arch/arm64/boot/dts/renesas/r9a07g043.dtsi b/arch/arm64/boot/dts/renesas/r9a07g043.dtsi > > index ff6aab388eb7..0ecca775fa3f 100644 > > --- a/arch/arm64/boot/dts/renesas/r9a07g043.dtsi > > +++ b/arch/arm64/boot/dts/renesas/r9a07g043.dtsi > > @@ -8,6 +8,8 @@ > > #include > > #include > > > > +#define SOC_PERIPHERAL_IRQ_NUMBER(na) (na + 32) > > +#define SOC_PERIPHERAL_IRQ(nr, na) GIC_SPI nr SOC_PERIPHERAL_IRQ_NUMBER(na) > > #define SOC_PERIPHERAL_IRQ(nr, flags) GIC_SPI > SOC_PERIPHERAL_IRQ_NUMBER(nr) flags > > > / { > > compatible = "renesas,r9a07g043"; > > #address-cells = <2>; > > @@ -128,7 +130,7 @@ ssi1: ssi@1004a000 { > > compatible = "renesas,r9a07g043-ssi", > > "renesas,rz-ssi"; > > reg = <0 0x1004a000 0 0x400>; > > - interrupts = , > > + interrupts = , > > > > > > > > Or any other method like that.... > > Oh cool, seems like arithmetic is supported. > No idea what I did wrong last time I tried... Oh sick, it does actually work??? So, am I missing something or is this sort of approach now a no-brainer?