Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1125762rbb; Sun, 25 Feb 2024 22:05:06 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVV6tquj+rtgZZzB9SdVLpQ2jme/58/bnGVpZGgJkQMcbxFmZU1pfBFOvWIynEmpKFMBThgm4zAWn41Rc9fv6sxQkv5Efez5uAz/DLh5A== X-Google-Smtp-Source: AGHT+IFGhFzvmm6U6yO+LyNT0j/qdOLhjXCSFtcdEjtmn4QdvVfJ33T40Jt25Ry59hdDQSkAVFYz X-Received: by 2002:a05:6808:169e:b0:3c1:50f6:9f93 with SMTP id bb30-20020a056808169e00b003c150f69f93mr7282638oib.11.1708927506384; Sun, 25 Feb 2024 22:05:06 -0800 (PST) Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id ca23-20020a056a02069700b005dc4a68d52esi3333232pgb.878.2024.02.25.22.05.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 25 Feb 2024 22:05:06 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-80577-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; arc=fail (signature failed); spf=pass (google.com: domain of linux-kernel+bounces-80577-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80577-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 178CA28128A for ; Mon, 26 Feb 2024 06:05:06 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D27C01BC31; Mon, 26 Feb 2024 06:05:01 +0000 (UTC) Received: from CHN02-SH0-obe.outbound.protection.partner.outlook.cn (mail-sh0chn02on2131.outbound.protection.partner.outlook.cn [139.219.146.131]) (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 10BAF1BDCE; Mon, 26 Feb 2024 06:04:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=139.219.146.131 ARC-Seal:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708927501; cv=fail; b=NjGTDwQhE4Sa680Y/qUOAfpyAQx11Fs3a183eDsV/jQTBd8kUNKibPG5CXK4iqAr5sAEo52SfvLx0Q28uvn399XQWUUVDkvtgKVjsiGe3t/tzHMM4+AFeVyS8rAA3n8X8ffkQ02b88hQ2rBUKWWt3jTr07AllWV+1wuazYd7WAQ= ARC-Message-Signature:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708927501; c=relaxed/simple; bh=ijAC6DtRyHCS+TxvTSHdNenGPycAQt4/0/Eejk5ldi4=; h=From:To:Cc:Subject:Date:Message-Id:Content-Type:MIME-Version; b=CEZUvyQCuqnuqTRtE+C7M7i6sTG97gockanMmRNhcOBggdMR4RWZYZo7vpVAay1iWe2RqjKIt5Wniy7NJ2dsIl7xXZVsZ7kxAVw82v3fHk59RSyDc971ayASHtmWxA20a8jIDRWXXAC4ZhQTIUZAxziakHUAEwcIpYSIK1pOT2E= ARC-Authentication-Results:i=2; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=starfivetech.com; spf=pass smtp.mailfrom=starfivetech.com; arc=fail smtp.client-ip=139.219.146.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=starfivetech.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=starfivetech.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AfEFJ5Y5leTBHTAgrbdaK8Uc0uLN4h+v/RvRCjOF1jKvWhdi0ks/MihqGhUlukDhqwmAclFSNopOYwdMMgvttoTzNRi1i+mqPNBQChVAxLc0uBT5OJSbJejZflJP11n8Zs6k69SOIG87+fBX9BWmiuwdltqHtSMC6N0xuwSAn/TC6sVwgUE/161D78ASnZI6Ewj4Kgd4wEj39mc2D8lnM7Rw+5NFSp8HZJ3sy8lc1JoQv2DGp58zYpOS6ajGTzcn+ALJLyGq9UzvW2bSZ42IiCF19nC5VBA5rF6tM/UKZ2O8QdNqVcIpalbPdtObk3nblMuHWrp0kg0Q6NhM1VKpgQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=X0wqzL9KCuENp2vmnM/R/u/DQnxZW72DkvivK6K5EGs=; b=h6C9vhNCdPeG7JZtvUcL1QJ/xirAkCgGyW7rLcurRkgJWo+62rFcCBZQJ8iXznN9D/KphlgFLnoIvOwpF4l526FuE0xezW5KCuJbv/ovKSJO3Ql80E3sX88tV5sfGG33wpRf1iE+eIee1qEdQaVB2pVD1Ad5+uVAYPY6ynveUR+GRVTV/tsIMhAwDbkVzl4St6ncHjINZvS+0VPJou2yXkQDw2jzHela3LsNNjTYXbF7ThF6hP7WGf+U3juM0hbusN6n5urpSn3dBNEpUYjM9LiG6guclKaHePuDdMkguX797uaHxWGIG5v8xxrPoO0KiIWiwJGwDit9+UMyTjzxXA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=starfivetech.com; dmarc=pass action=none header.from=starfivetech.com; dkim=pass header.d=starfivetech.com; arc=none Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=starfivetech.com; Received: from SHXPR01MB0671.CHNPR01.prod.partner.outlook.cn (2406:e500:c311:25::10) by SHXPR01MB0671.CHNPR01.prod.partner.outlook.cn (2406:e500:c311:25::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7249.42; Mon, 26 Feb 2024 05:50:33 +0000 Received: from SHXPR01MB0671.CHNPR01.prod.partner.outlook.cn ([fe80::b0af:4c9d:2058:a344]) by SHXPR01MB0671.CHNPR01.prod.partner.outlook.cn ([fe80::b0af:4c9d:2058:a344%6]) with mapi id 15.20.7249.041; Mon, 26 Feb 2024 05:50:33 +0000 From: Changhuang Liang To: Thomas Gleixner , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Philipp Zabel Cc: Ley Foon Tan , Jack Zhu , Changhuang Liang , linux-kernel@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v4 0/2] Add JH8100 external interrupt controller support Date: Sun, 25 Feb 2024 21:50:23 -0800 Message-Id: <20240226055025.1669223-1-changhuang.liang@starfivetech.com> X-Mailer: git-send-email 2.25.1 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SH0PR01CA0006.CHNPR01.prod.partner.outlook.cn (2406:e500:c311:5::18) To SHXPR01MB0671.CHNPR01.prod.partner.outlook.cn (2406:e500:c311:25::10) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SHXPR01MB0671:EE_ X-MS-Office365-Filtering-Correlation-Id: 48ef64b8-860e-46b6-be76-08dc368ed8c9 X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: VqyhRCosvruoweP3zFvRPg9TAGDGNEo6VOQcqjR+aDI13Uhqe37vhjv0zyswP5Q6z4YnZ2xiyQuTGpbDtlX+eEK4FcaKIhIM/nVSxt3yZwMsfyMm10VCNfA8b+/m1bbyMKBduzhI5K7Zjd4mxjlTVr7I8i5EkPADiXa3wedD4ghkgvzUyRksFYsCxk6DymN8wq2MMhJRcaD86SQYG9nvDTgcdPi2HwgQW3uT+gwW9IhrdZIxScublFjLlwsGujM7cmRLGXDIir6rC+rrvIEg20ShIW0OtW9OMA6zNB3xAu9zz4bjJbxmb5v9I48qHG3mlNXbpEODBBlpcvThUzEWVf+7JzYWBtnb8CITaCF0+/vOJXwLmmit8sK9lv0LQ5jSAephhmL5L1nYiRq+IUC98PdLwSuRmXvziHoemJQLZzcje4aHTx8YbVygrLjUST8goman75V75Kwe8nxd0TvdVA5SbnDqBOJMSabtiZxExGYJLxEK37Pa5IQAKFozgbp/ZngVg7/o3LdSPui3WXJGqalMZahbZ48d1uu9lpvsv+jVfUvps2tQc2j/6CniMt52U4I2TQMJxe2CdI4tFb/sG6z7dbKOsJe9BV39E5DTL3Xh1RfMJE1mnOXZSZo0Z8e5 X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SHXPR01MB0671.CHNPR01.prod.partner.outlook.cn;PTR:;CAT:NONE;SFS:(13230031)(230273577357003)(38350700005);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?hLFhtELmrjhysrm6MEbw6TbCQljYvrRni4aGwnWszT6UJAqX0lrTa79X5oUJ?= =?us-ascii?Q?kd4lYvXx3UZBUHWRnVdEhr37aT6rc861OKKgl2OwWxHrctUnsnFW2nOANjfy?= =?us-ascii?Q?pNmMjZndVAsJPdYQSLWCLs1MRmTjCkTZGJ/WW+Al4n653gS9GRFQRLFijOv+?= =?us-ascii?Q?bOsyJZlaGo3+4LO7pNY1p+jnL1itTgjdAE6xwDgxnsXybHCoDZ2cXFYWgQoa?= =?us-ascii?Q?LlPlOmvQHG1ZV8cU3SEJrh7iWdTtBYjImtySk8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us-ascii?Q?GHTyr60GJKxIHsoVVHusUVt1Nit7y2SkrerXK1Wci+r13tlituw7kEIT0LwN?= =?us-ascii?Q?19Iw3hvh8peO1WPE/TFM50yLdx1ulUiWKx7VDrUvIC2ZWYR7ZS2gjt1CsWav?= =?us-ascii?Q?yalTMhy7jPS3Y9oTZzGcTEKFBHmmjEPI4Ag3WwVdG6zLZDuNWPrHgMaEnIW5?= =?us-ascii?Q?QZoFVk8XpbwtwUhc/TRoXU+BcRXSCJssJ4ptYAbXB1tvGnUmVcCEmOa5Wuvr?= =?us-ascii?Q?U4nLIb0ysdT8KVpaxtJZ1gXNcRbXGGI/vq5O2N5uir92RWRx7IHmCwUSglk+?= =?us-ascii?Q?zll1Q4Lce2ZD8gCZDYnHZlp0Q4jOZuyyExzNyKgAYZsvj3qvMiamDMFnqy9M?= =?us-ascii?Q?1CZqjYnx8hJZ3WxnFKKfnA/k3pkN4GBcxB2/n36Tl2ByeIVunNlwBZgrx4RW?= =?us-ascii?Q?XZTCiam2KliIWoTNOzK4vqVJSFESZ2/13hjV+XDOJSfq/PK5VNm9BKoBfVc9?= =?us-ascii?Q?VeW44YJuxXnGwzslunMgPcI=3D?= X-OriginatorOrg: starfivetech.com X-MS-Exchange-CrossTenant-Network-Message-Id: 48ef64b8-860e-46b6-be76-08dc368ed8c9 X-MS-Exchange-CrossTenant-AuthSource: SHXPR01MB0671.CHNPR01.prod.partner.outlook.cn X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Feb 2024 05:50:33.1452 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 06fe3fa3-1221-43d3-861b-5a4ee687a85c X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: hHod81AiHUng3QpyIxHUTSi2wxtBsgpBWu1OBFmg2JwNAS4qzvRlc9N09G8cSODC3iXLw9vTBnJQygaJq+SgFrEIS6oV6cubnyzSoWO94EuZASddnryeLal6fnHzTOpA X-MS-Exchange-Transport-CrossTenantHeadersStamped: SHXPR01MB0671 This patchset adds external interrupt controller driver for the StarFive JH81000 SoC. It can be used to handle high-level input interrupt signals. It also send the output interrupt signal to RISC-V PLIC. changes since v3: - Replaced "raw_spin_lock_irqsave" with "raw_spin_lock" - Replaced "raw_spin_unlock_irqsave" with "raw_spin_unlock" - Replaced "clear_bit" with "__clear_bit" v3: https://lore.kernel.org/all/20240221022647.5297-1-changhuang.liang@starfivetech.com/ changes since v2: - Rebased on tag v6.8-rc4. - Added raw_spinlock_t - Added irq_domain_remove free domain - Updated struct declarations and initializers - Updated variable declarations - Dropped store clk in struct starfive_irq_chip - Replaced "starfive_intc_mod" with "starfive_intc_bit_set&starfive_intc_bit_clear" - Replaced "struct irq_domain *root_domain" with "struct irq_domain *domain" - Added reset_control_assert&clk_disable_unprepare helper functions to error recover v2: https://lore.kernel.org/all/20240130055843.216342-1-changhuang.liang@starfivetech.com/ changes since v1: - Rebased on tag v6.8-rc1. - Dropped store reset_contorl. - Replaced "of_reset_control_get_by_index" with of_reset_control_get_exclusive - Printed the error code via %pe v1: https://lore.kernel.org/all/20240111023201.6187-1-changhuang.liang@starfivetech.com/ Changhuang Liang (2): dt-bindings: interrupt-controller: Add starfive,jh8100-intc irqchip: Add StarFive external interrupt controller .../starfive,jh8100-intc.yaml | 61 ++++++ MAINTAINERS | 6 + drivers/irqchip/Kconfig | 11 + drivers/irqchip/Makefile | 1 + drivers/irqchip/irq-starfive-jh8100-intc.c | 207 ++++++++++++++++++ 5 files changed, 286 insertions(+) create mode 100644 Documentation/devicetree/bindings/interrupt-controller/starfive,jh8100-intc.yaml create mode 100644 drivers/irqchip/irq-starfive-jh8100-intc.c -- 2.25.1