From nobody Sun Feb 8 02:21:36 2026 Received: from mail-wm1-f44.google.com (mail-wm1-f44.google.com [209.85.128.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E02F019C540 for ; Tue, 13 Jan 2026 16:15:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.44 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320918; cv=none; b=A0CayYWk19kClNC+Pyzee832IRCyqkE1ge4XhJqXOxd7IwZPx7mRGS9Z6MFdZ0deQsQToIqGPzrwmIu/aFnXfNqAMQGdTl/ymTIPoePHSBfAJf2LJ601/FpQvl2rLLsZd3j1NpNcDFjK/Y0UHXnsvhbsjN6E3gQpKcYum2BGkPs= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320918; c=relaxed/simple; bh=RA2MpMFiQcW8woGky10vbDaNAxzlqZLD9Qto0cY6qXw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=FP8lnnivVsYrERO13SZDVAOEIY63L2odkeV9FimHa1rOxzmaTFO5zpq2yPClyl/cuDm1TSXFLKQnJXzGR2/aBVPY314RGI2kbtk4srC7KAcKR16RVT118XCtfDDtODm/PI5tm5ytjLEukjc5IYCCACCKmaacqvrs2Z23nuJPm9Q= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=WHVkvVZp; arc=none smtp.client-ip=209.85.128.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="WHVkvVZp" Received: by mail-wm1-f44.google.com with SMTP id 5b1f17b1804b1-47775fb6cb4so42937675e9.0 for ; Tue, 13 Jan 2026 08:15:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1768320913; x=1768925713; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=iFO76MpaV7TKA3kGHuuWwQjUOsm9CcTqHJpQLHw5X70=; b=WHVkvVZp2tFn5fN3VtseiKJ4MUg2bBz3rTLusO4W+lEFKP2Yx1ZXpSxk0l+3Tts4l0 kgrgL4f5xvg8bgqt1ss7OxTbRg0kK2MA2idmBMM9ZWlsmOHJxGoHA/0cLrQXjCF4BPTZ lgJ3LtWMfzrt3z0/2dHULeRYcZEW2cEIAHXahwm6H/maf7DBqXm//hszdUPIlHjU6uHg f5YUetVj3ocJ95zdOMcwbApYj1KwOjx2Fs8DASZ+SS3MSL4PuQT469C5pNh1yuFB2DNM FcbB9Q9Seq79gCJPeCn+IqSo4At3FSu8CeBe6yn9yAXFdB6yLtxyCjY8f6suGJF0sK0B udCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768320913; x=1768925713; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=iFO76MpaV7TKA3kGHuuWwQjUOsm9CcTqHJpQLHw5X70=; b=MzRLB2NbsUdfqEU2d/SLgwZQZhyeKXc2hXBCqEXA6vwJvhe5tMEMHH7NpaGGBJYS+E e9wD5DaOqM3jIGBry+lprdKXthK9zBSrqbbUIgWSZcJlVzBgOD5drjR+q1XBJ/m50lap NZjMNMxeSy66LFlLfnNbyTUUmv1hoXuyN7EzNQVc21Iv677anWvg/SYe6VRd9Hn6fn3W gdDVvfiOxnLjfrg9DnnRqPWcFZOvxxb4YC88AXbX2WTNxBeCGGIyJepYGSolE7YYUY7d gIeoCF1Uy9LnGkg09D2Ll+ZedkjTp9OAA+Rf9CGhzM7CG1XOjIBwEt2Q/vgjG8nEFalQ QC2g== X-Gm-Message-State: AOJu0YzlDjwaCsxTpzps7Do95zPWKGfvVfj0SCF5kT7mafary4IJt/2T EYZpQoY2+7Zx0dTKZ8+neWokNXSyOnrtZ3LmLSqNA/ZO3aTakvPW4Tr/1nJEZg== X-Gm-Gg: AY/fxX4T+FVCJAkthmyAtXsg9OdyAVjpgR9c48rIgg3exaDdhTiqRYseA0p4z0BgJAc nYmx9cbB7cxZqio/mYE7e0aOyjDkx1iWCFJzjIBTKZ6pjuZFITwaW6wnGCiERT3VuCCs7pHEuJG 8x6kiY8H2hXuPeg8XduKzQaj1IjfoWGkxApaNeE9517nZGg3AioCws5cs17uancinHtcWQWpqU6 eKllinOwHlkGsWAXWX9irWzDRMp6mlAGBIRR6HvmyTzODCOvBfGKXI9aS5mrrlNHh4iByMxxBjt qanVwGscpOauURJsxVt3B7ZRZP6vg3EVdCVLKtGWo03677+SOG7XpSoEzVH2LR003v11awS6OBt 4vh9KT17/ypgp2w/efRV/thVqcIsukA6Ua+h5E6bTTqaypiJRHJoq5dyvJ0f541IdybvrAPcaEP RQDF3pr0mbmiyInFS9ihCKwu9SWqtueGTtBVXCZMiz1YLaUfdzkyKZDjukUbZ/M4Ne X-Google-Smtp-Source: AGHT+IHTmM9+1s27vLw2S1CrS8QJkz3b9Itz6K3HmIo/KuWYYIxo4nw1Xc0bBi5bp063eE8Hi+T2eQ== X-Received: by 2002:a05:600c:890e:b0:479:3a88:de5d with SMTP id 5b1f17b1804b1-47d8f284042mr148197935e9.36.1768320912845; Tue, 13 Jan 2026 08:15:12 -0800 (PST) Received: from localhost (brnt-04-b2-v4wan-170138-cust2432.vm7.cable.virginm.net. [94.175.9.129]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47d7f4184e1sm403936465e9.4.2026.01.13.08.15.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Jan 2026 08:15:10 -0800 (PST) From: Stafford Horne To: LKML Cc: Linux OpenRISC , devicetree , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stafford Horne , Linus Walleij , Geert Uytterhoeven , Bartosz Golaszewski , linux-gpio@vger.kernel.org Subject: [PATCH v4 1/6] dt-bindings: gpio-mmio: Add opencores GPIO Date: Tue, 13 Jan 2026 16:11:34 +0000 Message-ID: <20260113161152.3688309-2-shorne@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260113161152.3688309-1-shorne@gmail.com> References: <20260113161152.3688309-1-shorne@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Add a device tree binding for the opencores GPIO controller. On FPGA Development boards with GPIOs the OpenRISC architecture uses the opencores gpio verilog rtl which is compatible with the MMIO GPIO driver. Link: https://opencores.org/projects/gpio Signed-off-by: Stafford Horne Reviewed-by: Linus Walleij Reviewed-by: Geert Uytterhoeven --- Since v3: - Removed example. - Re-order this patch to be before adding compatible string to driver as p= er device tree binding patch rules. - Add Reviewed-by's. Since v2: - Fixup (replace) patch to simply add opencores,gpio and add an example. (It was incorrect to specifying opencores,gpio with brcm,bcm6345-gpio as opencores,gpio is not the same hardware, its 8-bit vs 32-bit) Since v1: - Fix schema to actually match the example. Documentation/devicetree/bindings/gpio/gpio-mmio.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/gpio/gpio-mmio.yaml b/Docume= ntation/devicetree/bindings/gpio/gpio-mmio.yaml index ee5d5d25ae82..a8823ca65e78 100644 --- a/Documentation/devicetree/bindings/gpio/gpio-mmio.yaml +++ b/Documentation/devicetree/bindings/gpio/gpio-mmio.yaml @@ -23,6 +23,7 @@ properties: - ni,169445-nand-gpio - wd,mbl-gpio # Western Digital MyBook Live memory-mapped GPIO contr= oller - intel,ixp4xx-expansion-bus-mmio-gpio + - opencores,gpio =20 big-endian: true =20 --=20 2.51.0 From nobody Sun Feb 8 02:21:36 2026 Received: from mail-wm1-f48.google.com (mail-wm1-f48.google.com [209.85.128.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B0F632C859 for ; Tue, 13 Jan 2026 16:15:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.48 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320921; cv=none; b=KyiQSC4pu0CZkAsEMN8uYlaEKXA7bd/okWS+6l6yFGPnTlOdH9acALVgpTsxTr8ufwNruBzeP02HuwZ9GiOJLRd0qnkHkJJHvfjm9mulXyEH4vw1e6rj3DcgtMvZ5v9nLyQhtku2t17HTNiu/X4m8yiwCr3n8x9sKmjF+tj+ga0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320921; c=relaxed/simple; bh=FnV3NQEZpSrckq7ZRbBQNezPa9LjdzizI84I9YL8+Ts=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=JTF/HenwAbqlgSK2NfKc/G+xYJgYF+gxTv5rNiqi8bFp8SUW088wVxKXuNWShNl/0Lhvx2l3Lqyj43g06KbjcOdo2yQBQ8DUt5Cws015u/J0e0YDjTu0w8/1KFT5k5kS735F4hj6OPpjgIxjBgYdRP+M+uTFXiErO1t2/518/FI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=ZeWg//FZ; arc=none smtp.client-ip=209.85.128.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="ZeWg//FZ" Received: by mail-wm1-f48.google.com with SMTP id 5b1f17b1804b1-47d5e021a53so57849235e9.3 for ; Tue, 13 Jan 2026 08:15:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1768320916; x=1768925716; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=6KrS+lv5lwDbRvbVFcdtMBkDtiHuhxyAyg1FHmuvd6Q=; b=ZeWg//FZIeQ5P5Q/HgM8xuUr9VaP0c++F2pn/qTYyZ6xPCAXlejHI6LudXakkiE1r/ MWYPj/WBWKSnCDox77Wn06wfe+ds3IrFzaaYPDfNR+pNK08xZ58DBnuwtmYUhYRQ+Afs KCaE3xNX14mGn1AGIH3taswtS4MLJK2vE5sDAp6w0yZx7ZQywQg6SbnBRqsqQYb+odSd SxWVaHbnT9cSBVkaebPQaezhKrTzhCZo+32rtyFTOK6hNXrsMwVbjQhiZwPhJeswxxDV ASk21IRmEnWXtkSuGhhZiVX8F/F4x4ewQgXLnsoTRx++XakJ2WS8Fsrsy67A8hewUyMM uH6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768320916; x=1768925716; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=6KrS+lv5lwDbRvbVFcdtMBkDtiHuhxyAyg1FHmuvd6Q=; b=MpbJtkOmP3Kc+ODWWK780WeZPu9lqzT4TlqfIYbD8dALBrisVMyGZjcmjW0FhL8pEX L6A/BpjrS4OVW61KH63qTjCoby8wroGoFLKv0XPtOBFLxSb2rD7BkZft2BPDRs/HJVcA /ef8dhDtgZt4pCjsPjvvulJlo7NsHcMZemp7h1rpESDSiMBYwFDJF9l/ypk//lSWr0uG 3VnHp3h9Ebkm8TkI0I4BKsmfVXOANNg4KIvuyoSK8aDiljDJE+tJFliVeJ4F5qXWjH8a EPfEm109wUepx1lfJ1iwE7+fQVFgMnjenPn8wbVYkMPl66+Fxpuwt6TAj5jR8XOfvoV8 AyCQ== X-Gm-Message-State: AOJu0Ywx9eQBsF4RexKH8zymbaY8ElRXVcTVolwqs1Q5vdyJz7AEklb+ 036IUSU92LgxhtVY03fIei5UP+CQVC63vQgXRm+PEs/o6wnEpdsViIn3foTnSg== X-Gm-Gg: AY/fxX4R/Nd/eqPttv/lqUzrPyhH4OdpRZm0S77KOhYS7MTI9QiM8W8a5bWQgYqHvkc phxrAAf4UAwgSK9iRemYdS3oTq/LIQw3Ik8wcg96OBjbf0XxUiW3Eki4umaz5q+e4VX3C1lP5Cd 09mnCyP+ckqXhNdhBFaDJX4yLZi7awoCN20Q2WgAKMDwvpJH4ImBYyX1FmUV5xDVUNY8buXG3p7 kJHFoWXd7zdWSIEU/cdqlCfX+gm1V7QQ+yaW0WYE2k5T01DnebhGBBNli9TJ1dZ89sSUNUN2Rgi NOFcUaUf3OJ/2DAamFAC6QrHELgfL0V6u2QXkbH4iuupeNwSQJJKShLGj/xSsnQLOolftnH3r70 bU5kR2uSFQiDVfyvDssLPSsEP/XhTkJfLHMbOz6yobyJ+tITlhPYkh9oJlmeb3+Mg9Fn9/rWelS joAP9k4wFUhfAPbfLK3Q3LTlnR4x7URN/thJ2bhrSEnv1R6G4zn8CA9zkOKj8B767P X-Google-Smtp-Source: AGHT+IFY7anv3CNwWIMho0+cvlpNv8144HIzUKvGLCKenedti8elP6yPkg0qEPScLVQhzPLK3UPXeg== X-Received: by 2002:a05:600c:83c9:b0:47b:e2a9:2bd9 with SMTP id 5b1f17b1804b1-47d84b3b719mr285114485e9.31.1768320915920; Tue, 13 Jan 2026 08:15:15 -0800 (PST) Received: from localhost (brnt-04-b2-v4wan-170138-cust2432.vm7.cable.virginm.net. [94.175.9.129]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-432bd0dacd1sm44182976f8f.4.2026.01.13.08.15.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Jan 2026 08:15:13 -0800 (PST) From: Stafford Horne To: LKML Cc: Linux OpenRISC , devicetree , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stafford Horne , Linus Walleij , Geert Uytterhoeven , Bartosz Golaszewski , linux-gpio@vger.kernel.org Subject: [PATCH v4 2/6] gpio: mmio: Add compatible for opencores GPIO Date: Tue, 13 Jan 2026 16:11:35 +0000 Message-ID: <20260113161152.3688309-3-shorne@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260113161152.3688309-1-shorne@gmail.com> References: <20260113161152.3688309-1-shorne@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" On FPGA Development boards with GPIOs the OpenRISC architecture uses the opencores gpio verilog rtl. This is compatible with the gpio-mmio. Add the compatible string to allow probing this driver from the devicetree. Link: https://opencores.org/projects/gpio Signed-off-by: Stafford Horne Reviewed-by: Linus Walleij Reviewed-by: Geert Uytterhoeven --- Since v3: - Order this patch after the binding patch. - Add Reviewed-by's. Since v2: - New patch drivers/gpio/gpio-mmio.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpio/gpio-mmio.c b/drivers/gpio/gpio-mmio.c index 5daf962b0323..edbcaad57d00 100644 --- a/drivers/gpio/gpio-mmio.c +++ b/drivers/gpio/gpio-mmio.c @@ -724,6 +724,7 @@ static const struct of_device_id gpio_mmio_of_match[] = =3D { { .compatible =3D "wd,mbl-gpio" }, { .compatible =3D "ni,169445-nand-gpio" }, { .compatible =3D "intel,ixp4xx-expansion-bus-mmio-gpio" }, + { .compatible =3D "opencores,gpio" }, { } }; MODULE_DEVICE_TABLE(of, gpio_mmio_of_match); --=20 2.51.0 From nobody Sun Feb 8 02:21:36 2026 Received: from mail-wm1-f50.google.com (mail-wm1-f50.google.com [209.85.128.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 14BE4199EAD for ; Tue, 13 Jan 2026 16:15:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.50 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320925; cv=none; b=exfzPeHLoAITh0Hd8C1aJTQtzWzvxrp5w7yhSRhbBQ1HXxs3ca5O8EFqh/Ai9bNbCOezJbKZR5s7+tLbGvje8YLevZLgdWuI1eBaCPGXMBXtTPX6YfE7tqaLKMvfcpNz3b1U5a5u7UrF6NJ3Bb/YS7wuwEWN07miS1a+2k0TT/s= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320925; c=relaxed/simple; bh=X+1J5PrXk/eYAdcNrlogIy51e8BwUbac79/oxhidec0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=fKc19r8SdF7839PLeH75VIqtV6G83Yf4/nvv40POWiZVbJMyRaLdem97pnbEMr3si/1J7pICHP/M8/tf5Xewdss3PybbF2Sx2JEe9+iIF/8ziws1RL3o8Nv5Ca4d1p0CXnN1EqNxnTJM9q75pxSgiqVX6hcfROOqs9nduORaFZU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=YeRtFyou; arc=none smtp.client-ip=209.85.128.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="YeRtFyou" Received: by mail-wm1-f50.google.com with SMTP id 5b1f17b1804b1-4779cb0a33fso83490375e9.0 for ; Tue, 13 Jan 2026 08:15:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1768320921; x=1768925721; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=1s6pH8NPA0ipZmaojy8syPtuylZJ77gPmpuGh7ODFgg=; b=YeRtFyouUfzqg+g+cWScjYYYRIu5XUEGiDz45UjiE8t0guZzN9rwpxZc16yq/r2RTE tJqq+dxdbeurtLW8I0Reioz4dsStNV9zqGpDneIF15dYp7fot7cwSR0a4DlbvpiTQ4W+ rLVAyplUnxX135/Ze3wOMjRq7ek5IT6RrZGyphrJNvs4YCHAhhsg7ZZoSVEC41AG7Wr+ Iacx+kfoEktUkVDwkcdCA2xszq4Df2JQ/hNn/zF+kCDs2BBBHu4zu6eW4Ucp25ZFSTVO VbrAGEnEWWp0NQ3ASrVTdz331B5GTz22aPRs8XrJCVRAHyAPwUoJd/UsPednN5z6KVXg 3WPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768320921; x=1768925721; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=1s6pH8NPA0ipZmaojy8syPtuylZJ77gPmpuGh7ODFgg=; b=uyBF5NC+Q5xXSflOXyh/gGwtR3VfrIJBVmsP5Y9jBbJKGv+X4caT0L5DktLxjUqMB+ JtHXyhmQek5JQspBOah9bze8CpsQ2SK+Kc9Wzlj12R6eYLfgLWcHr41ccbLFWmGl6hM5 DjoRojWqwpNiQtImk6i3FIuuAys4oemVGl6Zgp8Y9OARQvWQeaSf9aMd402VFBpf73qC GYA0cTQDDsigv0cFRGSgXSH1drFy3WXa5OATWRRLfOnLJW1hG4mioMwomhX2KwNq9M5D oTFpn1kmNxnzww28lONIVrcoJFUHlksi9khLo4lSJh7T2hvhAmsmKq2PGAabTWyWwyoT Qu0g== X-Gm-Message-State: AOJu0YwlqS3WNK/j0UW2O+BKi/txVW06jjPHRL1NsQDNLAYlH6ipfDo1 EhktbdVxe4uu70n+CqMy75T1F2fuiagw2Bmw0mhebaAVQZVfv1gWqqYWcLwqnw== X-Gm-Gg: AY/fxX6OszD4x+PZkyUraiJbypC4W7jiP3n4KGaZ0fyPgjGXTAs9aJ07yuQeKCNqjbs DU8ahF4llC3tqoNw4/utHobcHOonGg7a9KOUsZ4dPHRKE/XlxUvE8cJv2o/rfjytfrh5DgQUACz +KO6dlUloy0pZDYJuShS+sEmQFq00MSzsMxEStzKElKEVoLbTavBBfe49avkCajW4DpU/z6J78H i/F2yL+cbGb/52LwwauCwMGqXJ1NOUIuPKJ08LfdIGnguQERR1SIOoMcUSYXJjLHAyhHHmAuoO0 sDYgRXx9UNrgzxVAR3TLrwlXReItXUfcw/+VCHQEvBp5UenByKw/LwvkNSXCafGtuZWSq6Am9DU NC2Ifioxt4AjPbMBEjjhuw3+YwO4MTT8BS9JsNHq9pvSIYoGGgQzCrrBExYcmIg4jlxXPaHdw7Z pGPieUc7t7xJbDgtC5Hy5/uTPTpk7YjKADBKfSN65s/VObbzdqay8/hoMrYSb4tp5M X-Google-Smtp-Source: AGHT+IEBkqIo09065N0bi2TrrVj4eRHKloky1enyrZHc+sXMIs3OMC5p/IWN5EPOuPpgYYKp0+XRsg== X-Received: by 2002:a05:600c:6303:b0:47e:d943:ec08 with SMTP id 5b1f17b1804b1-47ed943eedcmr36590545e9.28.1768320920880; Tue, 13 Jan 2026 08:15:20 -0800 (PST) Received: from localhost (brnt-04-b2-v4wan-170138-cust2432.vm7.cable.virginm.net. [94.175.9.129]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47ee28116d3sm2084275e9.12.2026.01.13.08.15.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Jan 2026 08:15:19 -0800 (PST) From: Stafford Horne To: LKML Cc: Linux OpenRISC , devicetree , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stafford Horne , Jonas Bonn , Stefan Kristiansson Subject: [PATCH v4 3/6] openrisc: dts: Add de0 nano config and devicetree Date: Tue, 13 Jan 2026 16:11:36 +0000 Message-ID: <20260113161152.3688309-4-shorne@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260113161152.3688309-1-shorne@gmail.com> References: <20260113161152.3688309-1-shorne@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The de0 nano from Terasic is an FPGA board that we use in the OpenRISC community to test OpenRISC configurations. Add a base configuration for the board that runs an OpenRISC CPU at 50Mhz with 32MB ram, UART for console and some GPIOs for LEDs and switches. There is an older version of this floating around that defines all of the hardware on the board including SPI's, flash devices, sram, ADCs etc. Eventually it would be good to get the full version upstream but for now I think a minimal board is good to start with. Link: https://openrisc.io/tutorials/de0_nano/ Link: https://github.com/olofk/de0_nano Signed-off-by: Stafford Horne --- Since v3: - No changes. Since v2: - Move leds block up to the top. - Remove unneeded "status" from gpio0. - Removed earlycon from de0-nano.dts. arch/openrisc/boot/dts/de0-nano-common.dtsi | 42 +++++++++++ arch/openrisc/boot/dts/de0-nano.dts | 54 ++++++++++++++ arch/openrisc/configs/de0_nano_defconfig | 79 +++++++++++++++++++++ 3 files changed, 175 insertions(+) create mode 100644 arch/openrisc/boot/dts/de0-nano-common.dtsi create mode 100644 arch/openrisc/boot/dts/de0-nano.dts create mode 100644 arch/openrisc/configs/de0_nano_defconfig diff --git a/arch/openrisc/boot/dts/de0-nano-common.dtsi b/arch/openrisc/bo= ot/dts/de0-nano-common.dtsi new file mode 100644 index 000000000000..02e329e28e33 --- /dev/null +++ b/arch/openrisc/boot/dts/de0-nano-common.dtsi @@ -0,0 +1,42 @@ +// SPDX-License-Identifier: GPL-2.0 + +#include +#include + +/ { + leds0: leds { + compatible =3D "gpio-leds"; + + led-heartbeat { + gpios =3D <&gpio0 0 GPIO_ACTIVE_HIGH>; + color =3D ; + function =3D LED_FUNCTION_HEARTBEAT; + linux,default-trigger =3D "heartbeat"; + label =3D "heartbeat"; + }; + }; + + memory@0 { + device_type =3D "memory"; + reg =3D <0x00000000 0x02000000>; + }; + + /* 8 Green LEDs */ + gpio0: gpio@91000000 { + compatible =3D "opencores,gpio"; + reg =3D <0x91000000 0x1>, <0x91000001 0x1>; + reg-names =3D "dat", "dirout"; + gpio-controller; + #gpio-cells =3D <2>; + }; + + /* 4 DIP Switches */ + gpio1: gpio@92000000 { + compatible =3D "opencores,gpio"; + reg =3D <0x92000000 0x1>, <0x92000001 0x1>; + reg-names =3D "dat", "dirout"; + gpio-controller; + #gpio-cells =3D <2>; + status =3D "disabled"; + }; +}; diff --git a/arch/openrisc/boot/dts/de0-nano.dts b/arch/openrisc/boot/dts/d= e0-nano.dts new file mode 100644 index 000000000000..b5b854e7e8b4 --- /dev/null +++ b/arch/openrisc/boot/dts/de0-nano.dts @@ -0,0 +1,54 @@ +// SPDX-License-Identifier: GPL-2.0 + +/dts-v1/; + +#include "de0-nano-common.dtsi" + +/ { + model =3D "Terasic DE0 Nano"; + compatible =3D "opencores,or1ksim"; + #address-cells =3D <1>; + #size-cells =3D <1>; + interrupt-parent =3D <&pic>; + + aliases { + uart0 =3D &serial0; + }; + + chosen { + stdout-path =3D "uart0:115200"; + }; + + cpus { + #address-cells =3D <1>; + #size-cells =3D <0>; + + cpu@0 { + compatible =3D "opencores,or1200-rtlsvn481"; + reg =3D <0>; + clock-frequency =3D <50000000>; + }; + }; + + /* + * OR1K PIC is built into CPU and accessed via special purpose + * registers. It is not addressable and, hence, has no 'reg' + * property. + */ + pic: pic { + compatible =3D "opencores,or1k-pic"; + #interrupt-cells =3D <1>; + interrupt-controller; + }; + + serial0: serial@90000000 { + compatible =3D "opencores,uart16550-rtlsvn105", "ns16550a"; + reg =3D <0x90000000 0x100>; + interrupts =3D <2>; + clock-frequency =3D <50000000>; + }; +}; + +&gpio1 { + status =3D "okay"; +}; diff --git a/arch/openrisc/configs/de0_nano_defconfig b/arch/openrisc/confi= gs/de0_nano_defconfig new file mode 100644 index 000000000000..bc63905f9cd8 --- /dev/null +++ b/arch/openrisc/configs/de0_nano_defconfig @@ -0,0 +1,79 @@ +CONFIG_SYSVIPC=3Dy +CONFIG_NO_HZ=3Dy +CONFIG_LOG_BUF_SHIFT=3D14 +CONFIG_BLK_DEV_INITRD=3Dy +# CONFIG_RD_GZIP is not set +# CONFIG_RD_LZMA is not set +# CONFIG_RD_LZO is not set +# CONFIG_RD_LZ4 is not set +# CONFIG_RD_ZSTD is not set +CONFIG_EXPERT=3Dy +# CONFIG_EPOLL is not set +# CONFIG_TIMERFD is not set +# CONFIG_EVENTFD is not set +# CONFIG_AIO is not set +CONFIG_BUILTIN_DTB_NAME=3D"de0-nano" +# CONFIG_FPU is not set +CONFIG_HZ_100=3Dy +# CONFIG_BLOCK is not set +CONFIG_SLUB_TINY=3Dy +# CONFIG_COMPAT_BRK is not set +# CONFIG_VM_EVENT_COUNTERS is not set +CONFIG_NET=3Dy +CONFIG_UNIX=3Dy +CONFIG_UNIX_DIAG=3Dy +CONFIG_INET=3Dy +CONFIG_IP_MULTICAST=3Dy +CONFIG_INET_UDP_DIAG=3Dy +CONFIG_INET_RAW_DIAG=3Dy +CONFIG_INET_DIAG_DESTROY=3Dy +# CONFIG_IPV6 is not set +CONFIG_DEVTMPFS=3Dy +CONFIG_DEVTMPFS_MOUNT=3Dy +# CONFIG_PREVENT_FIRMWARE_BUILD is not set +# CONFIG_FW_LOADER is not set +# CONFIG_INPUT is not set +# CONFIG_SERIO is not set +# CONFIG_VT is not set +# CONFIG_LEGACY_PTYS is not set +CONFIG_SERIAL_8250=3Dy +CONFIG_SERIAL_8250_CONSOLE=3Dy +CONFIG_SERIAL_OF_PLATFORM=3Dy +# CONFIG_HW_RANDOM is not set +CONFIG_PPS=3Dy +CONFIG_GPIO_SYSFS=3Dy +# CONFIG_GPIO_SYSFS_LEGACY is not set +CONFIG_GPIO_GENERIC_PLATFORM=3Dy +# CONFIG_HWMON is not set +# CONFIG_USB_SUPPORT is not set +CONFIG_NEW_LEDS=3Dy +CONFIG_LEDS_CLASS=3Dy +CONFIG_LEDS_GPIO=3Dy +CONFIG_LEDS_TRIGGERS=3Dy +CONFIG_LEDS_TRIGGER_TIMER=3Dy +CONFIG_LEDS_TRIGGER_ONESHOT=3Dy +CONFIG_LEDS_TRIGGER_HEARTBEAT=3Dy +CONFIG_LEDS_TRIGGER_CPU=3Dy +CONFIG_LEDS_TRIGGER_ACTIVITY=3Dy +CONFIG_LEDS_TRIGGER_GPIO=3Dy +CONFIG_LEDS_TRIGGER_DEFAULT_ON=3Dy +CONFIG_LEDS_TRIGGER_TRANSIENT=3Dy +CONFIG_LEDS_TRIGGER_PANIC=3Dy +CONFIG_LEDS_TRIGGER_NETDEV=3Dy +CONFIG_LEDS_TRIGGER_PATTERN=3Dy +CONFIG_LEDS_TRIGGER_TTY=3Dy +# CONFIG_VIRTIO_MENU is not set +# CONFIG_VHOST_MENU is not set +# CONFIG_DNOTIFY is not set +CONFIG_TMPFS=3Dy +# CONFIG_XZ_DEC_X86 is not set +# CONFIG_XZ_DEC_POWERPC is not set +# CONFIG_XZ_DEC_ARM is not set +# CONFIG_XZ_DEC_ARMTHUMB is not set +# CONFIG_XZ_DEC_ARM64 is not set +# CONFIG_XZ_DEC_SPARC is not set +# CONFIG_XZ_DEC_RISCV is not set +CONFIG_PRINTK_TIME=3Dy +# CONFIG_DEBUG_MISC is not set +# CONFIG_FTRACE is not set +# CONFIG_RUNTIME_TESTING_MENU is not set --=20 2.51.0 From nobody Sun Feb 8 02:21:36 2026 Received: from mail-wm1-f43.google.com (mail-wm1-f43.google.com [209.85.128.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9BD872C859 for ; Tue, 13 Jan 2026 16:15:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.43 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320932; cv=none; b=uT22/ZXYPnjMOfq81ZTX9Y7KffpC/KeUjeKXcCmxihHLGnYkg9lRZvFtWXonLN8d9dZpOCW+1/n0IpCFmHlmh2Q5z0H7H0+ANEbaMWBaBijct7cGdQ6Ix1kt7MXfl/lXKVQGyXYUGCUBJ4fjXoSZwo8kYQtghs1hzREnyEdSs8g= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320932; c=relaxed/simple; bh=Upo/KeJ1tydzhEX3FEnB2Lq6CdSMUiNT1LlycW0K1NM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=FFbR2TxznC3pHCq8t2mfe0dUaploiYvC+lICsxo+Vr7bglGT8Q+QmWYyIJU51p6Ws6Nr3w022L9u8LEPHAzZfrY2+UOQy7U99I+pHxKYZG0UyuI/P+2fyv9PgG4/y3XErSWmG/2IP7sEZWKy5p19rN9KbgNHgqhKm2xWWhgvg5g= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=fQ//JyQy; arc=none smtp.client-ip=209.85.128.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="fQ//JyQy" Received: by mail-wm1-f43.google.com with SMTP id 5b1f17b1804b1-477bf34f5f5so62471075e9.0 for ; Tue, 13 Jan 2026 08:15:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1768320925; x=1768925725; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=VFXHMGeoomdbZOLp3ce3D0yDHo0q4hSajO4R4fHl4CQ=; b=fQ//JyQyUIHGRfPyqTagnrhK/DKLTuhvB07e7n05qtUhSzDKIsDLJJqLyPQS3XxaAQ qWWs2UrAW5Zh+YuLeGXt07YkZPOpqI+u8kDM9rB8W62ksUS+38pm734rbMdeapRJSdKz GlXxy6LIP/bSpBEG1ZgrHJ6ZieusMZ94+5i9YiUtHWvynwa/j2Zx8VpLvmB4bL7RoMSU zcRcKqhouU1wji5mtg+ybcZl60KHAUqFhXHMTfcFAP7EkdGcc5svElF7dEaDOq5+Tr4k j0ZXG+16SyNSe0gD8v7CuXf37UjdRmatcVonJLGnzmy7uxSUMpNYa/+CYOI5jZws/mME aWGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768320925; x=1768925725; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=VFXHMGeoomdbZOLp3ce3D0yDHo0q4hSajO4R4fHl4CQ=; b=OdwSn8sCrhbL0nf7ysmdGWT6cXT7E7zcAiDgT1GHJfDFwva56PQmLP0lcWzhyYuwxL V+AySroLAIHfMsJt/T+vkLgstb+8U9urGaJL0qTGZ8z5cFMbFxfyUvClGLxPY03JzBl2 1M1Oe0E9x1dJq5cyNdOJ/5re2TIkbKgCr2DyhGUfAflWb/a9WWkrI0nETZVCT4iYo0Bc 02++h4uJlKMi4rlzl6ICKofYNJgxcmSroyF9EW+oUIKSNgmPELszfrGClY7nZ0f0eWUx bP1zPeV5yUc4h3aoTMZnh1IDu0u0VapQdZFFVOyCRRz8bdpdJvfIgk38N29TsQKPoFfx ZLCg== X-Gm-Message-State: AOJu0YzoOrIXzZmS8QknH+wB4o6a1kJUki8a31x7sA8YhblJfqANPgUS CxYRPk3oNjY6W0LRiGFaM5+LT8dh9kEXL+ML5q2nVJ96yq4etXuCmmQac1Va+A== X-Gm-Gg: AY/fxX4Wzohw3lFV2XyKGluKXM4fAkpPwRluMhm/4vJEYFTu0GD939KJr/+STGiQ5r2 VLaK19FuLaXvknq2O9JoT8zZPbRz6yuNvoiIt9DkSGpH++AT3FZItqQE7lwnlEpDaG1YF0AqfdS WYADfRGsoXiwajetcXdoSI89U9b/cktWM+MriXha6TrOzl8AboPorE9g9sDZFr97/6qy+YghKyY 7Pq/Gj0RZdriqkCCkjXuzeWt19RlaYpUG0eoQmkyg/y29yHY8khR4ZB6YfosKxmiTRZOWW2fQwN Gtmn4iYyEzdqDHxB8aSu8ZVAjAzGtZ1DYZfwXnUyaj7LsdNorM+NAxyzASSizQ2DWktFcjR9OGQ iZkzI6WXLVX9AZCUpxPCP2aCGB2oe/C0kXvZ4SYCvTKaa5DWxwrBAf3I9kCEj5ai3MazOO3RS3F tZ9iLm1cDUHVQEj2SFUtuG1DZSlVhDKUppAYHAtiKvAAdd2IW1EdNNrR3xCKLIyTEU X-Google-Smtp-Source: AGHT+IFNlvwrKp+KJG2284DCa8NpoGDbY3vjhJ6xtVEGbHn019G4ljpezxVBqkiUcpZVaYK+N7/Z1A== X-Received: by 2002:a05:600c:1393:b0:477:55ce:f3bc with SMTP id 5b1f17b1804b1-47d84b3bad4mr246429825e9.19.1768320924653; Tue, 13 Jan 2026 08:15:24 -0800 (PST) Received: from localhost (brnt-04-b2-v4wan-170138-cust2432.vm7.cable.virginm.net. [94.175.9.129]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47d7f4184e1sm403945455e9.4.2026.01.13.08.15.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Jan 2026 08:15:23 -0800 (PST) From: Stafford Horne To: LKML Cc: Linux OpenRISC , devicetree , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stafford Horne , Jonas Bonn , Stefan Kristiansson , Thomas Gleixner Subject: [PATCH v4 4/6] openrisc: Fix IPIs on simple multicore systems Date: Tue, 13 Jan 2026 16:11:37 +0000 Message-ID: <20260113161152.3688309-5-shorne@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260113161152.3688309-1-shorne@gmail.com> References: <20260113161152.3688309-1-shorne@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Commit c05671846451 ("openrisc: sleep instead of spin on secondary wait") fixed OpenRISC SMP Linux for QEMU. However, stability was never achieved on FPGA development boards. This is because the above patch has a step to unmask IPIs on non-boot cpu's but on hardware without power management, IPIs remain masked. This meant that IPI's were never actually working on the simple SMP systems we run on development boards. The systems booted but stability was very suspect. Add the ability to unmask IPI's on the non-boot cores. This is done by making the OMPIC IRQs proper percpu IRQs. We can then use the enabled_percpu_irq() to unmask IRQ on the non-boot cpus. Update the or1k PIC driver to use a flow handler that can switch between percpu and the configured level or edge flow handlers at runtime. This mechanism is inspired by that done in the J-Core AIC driver. Signed-off-by: Stafford Horne Acked-by: Thomas Gleixner --- arch/openrisc/include/asm/smp.h | 3 ++- arch/openrisc/kernel/smp.c | 22 +++++++++++++++++++++- drivers/irqchip/irq-ompic.c | 15 +++++++++++---- drivers/irqchip/irq-or1k-pic.c | 27 ++++++++++++++++++++++++++- 4 files changed, 60 insertions(+), 7 deletions(-) diff --git a/arch/openrisc/include/asm/smp.h b/arch/openrisc/include/asm/sm= p.h index e21d2f12b5b6..007296f160ef 100644 --- a/arch/openrisc/include/asm/smp.h +++ b/arch/openrisc/include/asm/smp.h @@ -20,7 +20,8 @@ extern void smp_init_cpus(void); extern void arch_send_call_function_single_ipi(int cpu); extern void arch_send_call_function_ipi_mask(const struct cpumask *mask); =20 -extern void set_smp_cross_call(void (*)(const struct cpumask *, unsigned i= nt)); +extern void set_smp_cross_call(void (*)(const struct cpumask *, unsigned i= nt), + unsigned int irq); extern void handle_IPI(unsigned int ipi_msg); =20 #endif /* __ASM_OPENRISC_SMP_H */ diff --git a/arch/openrisc/kernel/smp.c b/arch/openrisc/kernel/smp.c index 86da4bc5ee0b..040ca201b692 100644 --- a/arch/openrisc/kernel/smp.c +++ b/arch/openrisc/kernel/smp.c @@ -13,6 +13,7 @@ =20 #include #include +#include #include #include #include @@ -25,6 +26,7 @@ =20 asmlinkage __init void secondary_start_kernel(void); =20 +static unsigned int ipi_irq __ro_after_init; static void (*smp_cross_call)(const struct cpumask *, unsigned int); =20 unsigned long secondary_release =3D -1; @@ -39,6 +41,14 @@ enum ipi_msg_type { =20 static DEFINE_SPINLOCK(boot_lock); =20 +static void or1k_ipi_enable(void) +{ + if (WARN_ON_ONCE(!ipi_irq)) + return; + + enable_percpu_irq(ipi_irq, 0); +} + static void boot_secondary(unsigned int cpu, struct task_struct *idle) { /* @@ -136,6 +146,7 @@ asmlinkage __init void secondary_start_kernel(void) complete(&cpu_running); =20 synchronise_count_slave(cpu); + or1k_ipi_enable(); set_cpu_online(cpu, true); =20 local_irq_enable(); @@ -195,9 +206,18 @@ void smp_send_stop(void) smp_call_function(stop_this_cpu, NULL, 0); } =20 -void __init set_smp_cross_call(void (*fn)(const struct cpumask *, unsigned= int)) +void __init set_smp_cross_call(void (*fn)(const struct cpumask *, unsigned= int), + unsigned int irq) { + if (WARN_ON(ipi_irq)) + return; + smp_cross_call =3D fn; + + ipi_irq =3D irq; + + /* Enabled IPIs for boot CPU immediately */ + or1k_ipi_enable(); } =20 void arch_send_call_function_single_ipi(int cpu) diff --git a/drivers/irqchip/irq-ompic.c b/drivers/irqchip/irq-ompic.c index e66ef4373b1e..f0e0b435bb1d 100644 --- a/drivers/irqchip/irq-ompic.c +++ b/drivers/irqchip/irq-ompic.c @@ -84,6 +84,8 @@ DEFINE_PER_CPU(unsigned long, ops); =20 static void __iomem *ompic_base; =20 +static DEFINE_PER_CPU_READ_MOSTLY(int, ipi_dummy_dev); + static inline u32 ompic_readreg(void __iomem *base, loff_t offset) { return ioread32be(base + offset); @@ -183,12 +185,17 @@ static int __init ompic_of_init(struct device_node *n= ode, goto out_unmap; } =20 - ret =3D request_irq(irq, ompic_ipi_handler, IRQF_PERCPU, - "ompic_ipi", NULL); - if (ret) + irq_set_percpu_devid(irq); + ret =3D request_percpu_irq(irq, ompic_ipi_handler, "ompic_ipi", + &ipi_dummy_dev); + + if (ret) { + pr_err("ompic: failed to request irq %d, error: %d", + irq, ret); goto out_irq_disp; + } =20 - set_smp_cross_call(ompic_raise_softirq); + set_smp_cross_call(ompic_raise_softirq, irq); =20 return 0; =20 diff --git a/drivers/irqchip/irq-or1k-pic.c b/drivers/irqchip/irq-or1k-pic.c index 48126067c54b..73dc99c71d40 100644 --- a/drivers/irqchip/irq-or1k-pic.c +++ b/drivers/irqchip/irq-or1k-pic.c @@ -118,11 +118,36 @@ static void or1k_pic_handle_irq(struct pt_regs *regs) generic_handle_domain_irq(root_domain, irq); } =20 +/* + * The OR1K PIC is a cpu-local interrupt controller and does not distingui= sh or + * use distinct irq number ranges for per-cpu event interrupts (IPI). Since + * information to determine whether a particular irq number should be trea= ted as + * per-cpu is not available at mapping time, we use a wrapper handler func= tion + * which chooses the right handler at runtime based on whether IRQF_PERCPU= was + * used when requesting the irq. Borrowed from J-Core AIC. + */ +static void or1k_irq_flow_handler(struct irq_desc *desc) +{ +#ifdef CONFIG_SMP + struct irq_data *data =3D irq_desc_get_irq_data(desc); + struct or1k_pic_dev *pic =3D data->domain->host_data; + + if (irqd_is_per_cpu(data)) + handle_percpu_devid_irq(desc); + else + pic->handle(desc); +#endif +} + static int or1k_map(struct irq_domain *d, unsigned int irq, irq_hw_number_= t hw) { struct or1k_pic_dev *pic =3D d->host_data; =20 - irq_set_chip_and_handler(irq, &pic->chip, pic->handle); + if (IS_ENABLED(CONFIG_SMP)) + irq_set_chip_and_handler(irq, &pic->chip, or1k_irq_flow_handler); + else + irq_set_chip_and_handler(irq, &pic->chip, pic->handle); + irq_set_status_flags(irq, pic->flags); =20 return 0; --=20 2.51.0 From nobody Sun Feb 8 02:21:36 2026 Received: from mail-wm1-f52.google.com (mail-wm1-f52.google.com [209.85.128.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 180F023C51D for ; Tue, 13 Jan 2026 16:15:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.52 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320939; cv=none; b=q0CetXyHg08vxK8PTCIWFQ7eK1AJEV+7i1u/NXpDt/GSjlrG51NMQ87c99CC77/NvMRO4EplkBkpAQg4BZ6pU7G9EzSAOz8DefDEfuxE+P8XCga8juAbEm0D6AgGDO6jSosli+Q88yvaTi+D0Jtr7ggLLZYJiWwO1BNhamCSBd0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320939; c=relaxed/simple; bh=s41epkAbLG9smlbYYXWvYNaWVozGaFQ8TXpu/2hzAWw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=P2jMdLn7BwEoLErRONPVptZoD3pziHu4EO4vKo0qUBAh/aTEc5zJsWHkwcwN3c6V5onz24qZFjeqJGF/djthMUknWsKGEqrJoTGN/p5eW5ovtylsuET+qtyFtCcFOKjK56TFJ2js958m58HSIppIT5Uhk85yokkduo0GAdxq9lc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=CUaveW4v; arc=none smtp.client-ip=209.85.128.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="CUaveW4v" Received: by mail-wm1-f52.google.com with SMTP id 5b1f17b1804b1-47d1d8a49f5so49480625e9.3 for ; Tue, 13 Jan 2026 08:15:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1768320931; x=1768925731; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=3u+3JeZcHRgFBFE83J1Rhnm4t9otRBPxkyt04fpaFbg=; b=CUaveW4vjBWPZTsKNsUL4+nytLX093sNsOcwq1Ah0PaDdfmQ02F39GQ38D5mUlyYmZ cbrSiB7kcJnXm2WSfE845xTC+x3ZOxw7hkj7JUxyQs73ql699jvHoM7GanCmyVodZlqj 3/V0NfDdpGx7vfvPc7AaHvJ+r3YwxkX6O8Cc4gnCigd/Jvmh6YarJlFhXB5JNAecvUbt BViCrP/5IvewpOi6wxOWwhznHVT3gq4HVN3wJptKBJKcTL1FR9hOedweHDjKvdWi6M18 ZiFFXX7vW15LY9lzrIzpe4IcvwT0XdaSf3xq9qkkPE/hnwPNTgTFGZRhgu2GHMYLO5gI 2mdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768320931; x=1768925731; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=3u+3JeZcHRgFBFE83J1Rhnm4t9otRBPxkyt04fpaFbg=; b=tvcPedOMABdk9qNvWhYmfS1505c5daPHOepH9QRb1738Wh9LOt4W9B9aiWIcJzgRWI X357F9tWWKRPztrGDTbLICYUzznfJ0yoWqexl017V79RmkCjmCRBgDWW+nNoI4DE0Vyb WuQz3Yl3W5reivsribkshM7pk92jVuDP4SxmaqNXndBWXftlqQln869nD8k6UZl0cygN YSzLAsX1vX6ZgR2HzIX6SxfVzhN992xpGUvLusNcPnNi9t5+CwAth2unodvaW9X4m4O7 bK6FyzlLBQVZc8psnxkJgsoFv2r5/wEAVMb+yMcoOj2prtaIGSatbBpoMzD8N8EvNQa+ BYjg== X-Gm-Message-State: AOJu0YziMCfid80GRgH36gilFCHrVy1996bLOXmhGryJwMchRAQ+AmRc QLjyvRveTncCfnuWT35aqrJt7BtHnUm6W5XqRGPGFsdpfRy+jQ7tFyE+0O8n1A== X-Gm-Gg: AY/fxX5vrDtgEMG5wsoq/DYG2lyHzBkcJNNmas1OnLYS7SGz6gFyIOjKpRETxGdmLKY GKHoyaqgwjtVvyUo4TE/4MQEmJYeIsUNuSBYnHHHU2K4NBeXvd2aIKo/SkO4lIAyBRAq/IWMkFM ZiM6KFwLs3BVBuqHypl5sHpsHCqD2PWv2BcUlrwxID46nVqAXTeZX+UHehVfZsXiQozHVyE4czA 9AD7Cp85jvSFs0kc9051GdYubFo9N/+YXfOulKDOOrAUWndWgUn5CUjhQqz+UDuDMQ9yfhp116/ eHTqKf2hx0AVsem9TtFVForFJugD/sccw5tv5aPAKFWIv44Bvg5K6/6FuRYVyspb5DHpO0PZayg 5R1Bdn9oUlwZO7PFHKJIuBxSkMNh3r9jG2PvQ96D62be+Mbe1X2fqDUE/GELQI3+5PmLnb6Z2S1 WhL+j/LYDDHnbCyvJums45ovGYy+E0411jnGaPNavqGMmcqEeQZjV2BrJzSIjPt9Qi X-Google-Smtp-Source: AGHT+IGhLvJfxVLRGqghrhgN1dMGCIANA0QJw3+JAhwPNyMjUoAIPGjWB7rlYfend9xQbfhK4N/+2w== X-Received: by 2002:a05:600c:4fd0:b0:477:7925:f7fb with SMTP id 5b1f17b1804b1-47d84b200d1mr257784645e9.10.1768320930358; Tue, 13 Jan 2026 08:15:30 -0800 (PST) Received: from localhost (brnt-04-b2-v4wan-170138-cust2432.vm7.cable.virginm.net. [94.175.9.129]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47ee27cf06bsm1066485e9.4.2026.01.13.08.15.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Jan 2026 08:15:27 -0800 (PST) From: Stafford Horne To: LKML Cc: Linux OpenRISC , devicetree , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stafford Horne , Jonas Bonn , Stefan Kristiansson , Masahiro Yamada Subject: [PATCH v4 5/6] openrisc: dts: Split simple smp dts to dts and dtsi Date: Tue, 13 Jan 2026 16:11:38 +0000 Message-ID: <20260113161152.3688309-6-shorne@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260113161152.3688309-1-shorne@gmail.com> References: <20260113161152.3688309-1-shorne@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Split out the common memory, CPU and PIC definitions of the simple SMP system to a DTSI file which we will later use for our De0 Nano multicore board device tree. We also take this opportunity to swich underscores to dashes as that seems to be the more common convention for DTS files. Signed-off-by: Stafford Horne --- Since v3: - No changes. Since v2: - Sort blocks alphabetically. arch/openrisc/boot/dts/simple-smp.dts | 25 +++++++++++++++++++ .../dts/{simple_smp.dts =3D> simple-smp.dtsi} | 11 ++++---- arch/openrisc/configs/simple_smp_defconfig | 2 +- 3 files changed, 31 insertions(+), 7 deletions(-) create mode 100644 arch/openrisc/boot/dts/simple-smp.dts rename arch/openrisc/boot/dts/{simple_smp.dts =3D> simple-smp.dtsi} (90%) diff --git a/arch/openrisc/boot/dts/simple-smp.dts b/arch/openrisc/boot/dts= /simple-smp.dts new file mode 100644 index 000000000000..01cf219e6aac --- /dev/null +++ b/arch/openrisc/boot/dts/simple-smp.dts @@ -0,0 +1,25 @@ +// SPDX-License-Identifier: GPL-2.0 + +/dts-v1/; + +#include "simple-smp.dtsi" + +/ { + model =3D "Simple SMP Board"; +}; + +&cpu0 { + clock-frequency =3D <20000000>; +}; + +&cpu1 { + clock-frequency =3D <20000000>; +}; + +&enet0 { + status =3D "okay"; +}; + +&serial0 { + clock-frequency =3D <20000000>; +}; diff --git a/arch/openrisc/boot/dts/simple_smp.dts b/arch/openrisc/boot/dts= /simple-smp.dtsi similarity index 90% rename from arch/openrisc/boot/dts/simple_smp.dts rename to arch/openrisc/boot/dts/simple-smp.dtsi index 71af0e117bfe..42d6eda33b71 100644 --- a/arch/openrisc/boot/dts/simple_smp.dts +++ b/arch/openrisc/boot/dts/simple-smp.dtsi @@ -1,4 +1,3 @@ -/dts-v1/; / { compatible =3D "opencores,or1ksim"; #address-cells =3D <1>; @@ -22,15 +21,15 @@ memory@0 { cpus { #address-cells =3D <1>; #size-cells =3D <0>; - cpu@0 { + + cpu0: cpu@0 { compatible =3D "opencores,or1200-rtlsvn481"; reg =3D <0>; - clock-frequency =3D <20000000>; }; - cpu@1 { + + cpu1: cpu@1 { compatible =3D "opencores,or1200-rtlsvn481"; reg =3D <1>; - clock-frequency =3D <20000000>; }; }; =20 @@ -57,7 +56,6 @@ serial0: serial@90000000 { compatible =3D "opencores,uart16550-rtlsvn105", "ns16550a"; reg =3D <0x90000000 0x100>; interrupts =3D <2>; - clock-frequency =3D <20000000>; }; =20 enet0: ethoc@92000000 { @@ -65,5 +63,6 @@ enet0: ethoc@92000000 { reg =3D <0x92000000 0x800>; interrupts =3D <4>; big-endian; + status =3D "disabled"; }; }; diff --git a/arch/openrisc/configs/simple_smp_defconfig b/arch/openrisc/con= figs/simple_smp_defconfig index 6008e824d31c..db77c795225e 100644 --- a/arch/openrisc/configs/simple_smp_defconfig +++ b/arch/openrisc/configs/simple_smp_defconfig @@ -20,7 +20,7 @@ CONFIG_SLUB=3Dy CONFIG_SLUB_TINY=3Dy CONFIG_MODULES=3Dy # CONFIG_BLOCK is not set -CONFIG_BUILTIN_DTB_NAME=3D"simple_smp" +CONFIG_BUILTIN_DTB_NAME=3D"simple-smp" CONFIG_SMP=3Dy CONFIG_HZ_100=3Dy CONFIG_OPENRISC_HAVE_SHADOW_GPRS=3Dy --=20 2.51.0 From nobody Sun Feb 8 02:21:36 2026 Received: from mail-wm1-f45.google.com (mail-wm1-f45.google.com [209.85.128.45]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4E458256C6D for ; Tue, 13 Jan 2026 16:15:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.45 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320941; cv=none; b=rRXV4Ooub1ExBSANmdpkxgab94kJf7AjvbBR89OslaohvCfWPzlWid9Go5HV35h1u8NNuvD+U83q1pPXFYwiJbNziAIuU80hWGxNLrUsrWpvS4kixYmt4us8YY3YUod7jsX+LERvzfkoIeVqakRerWsysrT2pCSQFf0breBbA+E= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768320941; c=relaxed/simple; bh=un/mmc47M7TzaiskJcRDfyxuLNhftyXJQ1e6SZgvuK4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=NfW9BBIaYPjOUHyUl0UjOOt9ndaBQtqxeDR+0sroOnYBGQXgu/KDp8TWYUiq3V5MFbBjQizQ4M1Hh9fHmn73MYCQCa+xDsZyMKKP8eO4WF0TVukk/Z0EZHkIdoelpD9qSPip7w3va+OB80MTplZzOtX8q7DgasJ+nvLzbiVSIxE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=NafGZAfK; arc=none smtp.client-ip=209.85.128.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="NafGZAfK" Received: by mail-wm1-f45.google.com with SMTP id 5b1f17b1804b1-47eddddcdcfso3219195e9.1 for ; Tue, 13 Jan 2026 08:15:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1768320937; x=1768925737; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=3suL/FJnULndAdzhv6eYWlf/ToXJG1zAeBlGIDXgmts=; b=NafGZAfKVuA2KsTg26aJLVmgGp07nKC+VLjLMiZiwExvTW53tJpt6oy9z5+XLueJMS VPTeLQ/bKUPYmg5BW0dKd87BLG+DHQmmypb/FBDVrto4ntDn1szAEuYSFtfHBXE7yEVD gbBkT3TxQtuXl+IPqaTQ1t0LaHkYU6GCrfxZuM6QWY/HxYmcXDjkHJZaNw4oh6qQ3Y12 DYY3dXznLcCP1oUah2PbouKCpW/xqmYuViyynTLgAb+RyrXxaW4lon5+w720aD3XbBkY kLf54e9h7kdgABav+cC/QPb73WmUpu/0yalJK5I5Ts3o1M3aGh+hBYGx5y/paM5mZ6Fa bCZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768320937; x=1768925737; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=3suL/FJnULndAdzhv6eYWlf/ToXJG1zAeBlGIDXgmts=; b=NXgv4IueccqzL9fgHrRb3QAUkQ2elFgM2TQAs9RP7J1L36XLRFF8S9V012tkebq5Fn rDXSwCKXXC9VbVViIly9GIXzQdQZhG4JQWl6HSSm9D+qL6FWCn35ntx/QSGUvjH+U41a XHQeS/QZQyhpVgFBto1igP3isyYQ51bnX5RQDnmSR7gFTTgCgPAdmSnw+VyI4s3fWGZy NZVQqSnpOzNRWkf2woTk+x8fWUZ+yoaOar/igzVT6u815yps6HyM/6Oa2A7I3FeY0PyZ +h+wJmhMX42X49Iokl9WJWwXcmxfXByku+hu2JcG4pJ8RV8OBXjtWvVvrykeEdV+/Kdt WlOA== X-Gm-Message-State: AOJu0YwwPe+3yE/pDKBXXhEuGxxM2GsPc6Qmf32sID2azIAUwuYL1GlM 0v169fH8AVnWtqGS9O7XNW39ZZWL5Qd0MltvOgkRNK4blDM+eG7NA6e/mKDrNg== X-Gm-Gg: AY/fxX66okNKemOTsR5KNE9MOqEFz/5QHwNkyuY/e87IoNqh4cC/Y+dsMxJSPwAgC4m PSMrMRqFokOhocM0DqmGnEU20VmdmTqhAlH4ktGZ1rWy5N6WCjmoOKW3iG+58/fHSPjfzeIh5xe slZEplvgbl2a4cPeI6P/8WeBHcnAFk7UjYPZOyAVDuauwM1UdKp8QPltGKLsZCZ+4lTLIZruP8n 38tDAIk3+BvRXxgjMfbB96JQrU3O2Ecq1KqLUDxpRCyZkk/e27Nyg/KS97B5dGlqBjD6SZxgAzr mshEa2l9BAVoouEOftti9cY+Nnv/XWo7o9y1kDQn5QJb7gDr+5wvwtjacv5QBNK6ujcluVrqR32 g9npsRhEv3cOwQUTgsy6yl8wwF1COOeKhNn9RmfVN1DG9bIcrPb29GxPIl9OP1zoo+86iav9Acj biUiQVeBdW9HaiIgTDPeY8fwohQIgr52KJ6WiZlSj7SDpg+QUtWPi5gRLt6dukg3dZNeBzT635z Jc= X-Google-Smtp-Source: AGHT+IEUmUYkeDP+S1h3o6VFVFRiGbNpyWnRfokREMXteE+Q59STqyI+MVlOpmbRPK5R/Plvb3OZlw== X-Received: by 2002:a05:600c:3b15:b0:475:dd89:acb with SMTP id 5b1f17b1804b1-47d84b3472amr250733125e9.22.1768320936453; Tue, 13 Jan 2026 08:15:36 -0800 (PST) Received: from localhost (brnt-04-b2-v4wan-170138-cust2432.vm7.cable.virginm.net. [94.175.9.129]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-47edfd5cfd5sm20913665e9.8.2026.01.13.08.15.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Jan 2026 08:15:35 -0800 (PST) From: Stafford Horne To: LKML Cc: Linux OpenRISC , devicetree , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stafford Horne , Jonas Bonn , Stefan Kristiansson Subject: [PATCH v4 6/6] openrisc: dts: Add de0 nano multicore config and devicetree Date: Tue, 13 Jan 2026 16:11:39 +0000 Message-ID: <20260113161152.3688309-7-shorne@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20260113161152.3688309-1-shorne@gmail.com> References: <20260113161152.3688309-1-shorne@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Add a multicore configuration for the Terasic de0 nano FPGA development board. This SoC runs 2 OpenRISC CPUs at 50Mhz with 32MB ram, UART for console and GPIOs for LEDs. This FPGA SoC is based on the simple-smp reference board and brings in devices from the de0 nano common DTSI file. A default config is added that brings together the device tree and driver setup. Link: https://github.com/stffrdhrn/de0_nano-multicore Signed-off-by: Stafford Horne --- arch/openrisc/boot/dts/de0-nano-multicore.dts | 25 +++++ .../configs/de0_nano_multicore_defconfig | 92 +++++++++++++++++++ 2 files changed, 117 insertions(+) create mode 100644 arch/openrisc/boot/dts/de0-nano-multicore.dts create mode 100644 arch/openrisc/configs/de0_nano_multicore_defconfig diff --git a/arch/openrisc/boot/dts/de0-nano-multicore.dts b/arch/openrisc/= boot/dts/de0-nano-multicore.dts new file mode 100644 index 000000000000..b6cf286afaa4 --- /dev/null +++ b/arch/openrisc/boot/dts/de0-nano-multicore.dts @@ -0,0 +1,25 @@ +// SPDX-License-Identifier: GPL-2.0 + +#include +#include + +/dts-v1/; + +#include "simple-smp.dtsi" +#include "de0-nano-common.dtsi" + +/ { + model =3D "Terasic DE0 Nano - Multicore"; +}; + +&cpu0 { + clock-frequency =3D <50000000>; +}; + +&cpu1 { + clock-frequency =3D <50000000>; +}; + +&serial0 { + clock-frequency =3D <50000000>; +}; diff --git a/arch/openrisc/configs/de0_nano_multicore_defconfig b/arch/open= risc/configs/de0_nano_multicore_defconfig new file mode 100644 index 000000000000..d33b1226e09c --- /dev/null +++ b/arch/openrisc/configs/de0_nano_multicore_defconfig @@ -0,0 +1,92 @@ +CONFIG_LOCALVERSION=3D"-de0nano-smp" +CONFIG_SYSVIPC=3Dy +CONFIG_POSIX_MQUEUE=3Dy +CONFIG_NO_HZ=3Dy +CONFIG_LOG_BUF_SHIFT=3D14 +CONFIG_BLK_DEV_INITRD=3Dy +# CONFIG_RD_GZIP is not set +# CONFIG_RD_BZIP2 is not set +# CONFIG_RD_LZMA is not set +# CONFIG_RD_XZ is not set +# CONFIG_RD_LZO is not set +# CONFIG_RD_LZ4 is not set +CONFIG_EXPERT=3Dy +# CONFIG_EPOLL is not set +# CONFIG_TIMERFD is not set +# CONFIG_EVENTFD is not set +# CONFIG_AIO is not set +CONFIG_KALLSYMS_ALL=3Dy +CONFIG_DCACHE_WRITETHROUGH=3Dy +CONFIG_BUILTIN_DTB_NAME=3D"de0-nano-multicore" +CONFIG_OPENRISC_HAVE_INST_CMOV=3Dy +CONFIG_SMP=3Dy +CONFIG_HZ_100=3Dy +CONFIG_JUMP_LABEL=3Dy +# CONFIG_BLOCK is not set +CONFIG_SLUB_TINY=3Dy +# CONFIG_COMPAT_BRK is not set +# CONFIG_VM_EVENT_COUNTERS is not set +CONFIG_NET=3Dy +CONFIG_PACKET=3Dy +CONFIG_UNIX=3Dy +CONFIG_UNIX_DIAG=3Dy +CONFIG_INET=3Dy +CONFIG_IP_MULTICAST=3Dy +CONFIG_TCP_CONG_ADVANCED=3Dy +# CONFIG_TCP_CONG_BIC is not set +# CONFIG_TCP_CONG_CUBIC is not set +# CONFIG_TCP_CONG_WESTWOOD is not set +# CONFIG_TCP_CONG_HTCP is not set +# CONFIG_IPV6 is not set +# CONFIG_WIRELESS is not set +CONFIG_DEVTMPFS=3Dy +CONFIG_DEVTMPFS_MOUNT=3Dy +# CONFIG_PREVENT_FIRMWARE_BUILD is not set +# CONFIG_FW_LOADER is not set +CONFIG_NETDEVICES=3Dy +CONFIG_ETHOC=3Dy +CONFIG_MICREL_PHY=3Dy +# CONFIG_WLAN is not set +# CONFIG_INPUT is not set +# CONFIG_SERIO is not set +# CONFIG_VT is not set +# CONFIG_LEGACY_PTYS is not set +CONFIG_SERIAL_8250=3Dy +CONFIG_SERIAL_8250_CONSOLE=3Dy +CONFIG_SERIAL_OF_PLATFORM=3Dy +# CONFIG_HW_RANDOM is not set +CONFIG_GPIO_SYSFS=3Dy +# CONFIG_GPIO_CDEV_V1 is not set +CONFIG_GPIO_GENERIC_PLATFORM=3Dy +# CONFIG_HWMON is not set +# CONFIG_USB_SUPPORT is not set +CONFIG_NEW_LEDS=3Dy +CONFIG_LEDS_CLASS=3Dy +CONFIG_LEDS_GPIO=3Dy +CONFIG_LEDS_TRIGGERS=3Dy +CONFIG_LEDS_TRIGGER_TIMER=3Dy +CONFIG_LEDS_TRIGGER_ONESHOT=3Dy +CONFIG_LEDS_TRIGGER_HEARTBEAT=3Dy +CONFIG_LEDS_TRIGGER_CPU=3Dy +CONFIG_LEDS_TRIGGER_ACTIVITY=3Dy +CONFIG_LEDS_TRIGGER_GPIO=3Dy +CONFIG_LEDS_TRIGGER_DEFAULT_ON=3Dy +CONFIG_LEDS_TRIGGER_TRANSIENT=3Dy +CONFIG_LEDS_TRIGGER_PANIC=3Dy +CONFIG_LEDS_TRIGGER_NETDEV=3Dy +CONFIG_LEDS_TRIGGER_PATTERN=3Dy +CONFIG_LEDS_TRIGGER_TTY=3Dy +# CONFIG_DNOTIFY is not set +CONFIG_TMPFS=3Dy +CONFIG_NFS_FS=3Dy +CONFIG_XZ_DEC=3Dy +CONFIG_PRINTK_TIME=3Dy +CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT=3Dy +CONFIG_GDB_SCRIPTS=3Dy +CONFIG_VMLINUX_MAP=3Dy +CONFIG_HARDLOCKUP_DETECTOR=3Dy +CONFIG_WQ_WATCHDOG=3Dy +CONFIG_WQ_CPU_INTENSIVE_REPORT=3Dy +CONFIG_STACKTRACE=3Dy +CONFIG_RCU_CPU_STALL_CPUTIME=3Dy +# CONFIG_RCU_TRACE is not set --=20 2.51.0