From nobody Thu Dec 25 06:46:06 2025 Received: from TWMBX02.aspeed.com (mail.aspeedtech.com [211.20.114.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 658854A08 for ; Fri, 19 Jan 2024 05:46:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=211.20.114.72 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705643223; cv=none; b=bx0I6I92Hs0fEG2qaRJu/vTFREuiE/bbfxG4RICgrnmuW/yc1k3ZrX7160BRoor+z+WlutNUsL63Ti5zR2f5m622zfG2trGPceXTmClc8GRpNvOSS0mrtsDDh/x6xKXGD2joUH5CBJDSh+lpGNtbxuATGRZCAJqgczrYVDiudUw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705643223; c=relaxed/simple; bh=vlYQVccxYZ0DiUDfVn1GJR1st0mlyzvE2G+s3xMu0II=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=tQmh14g3Y1SZpk/saDiTGW3B+g9ZVpSR+O9DSQ9I8P9+VR+URccTOrlwahdtUOwBmRFGWVR1/G8nwbEpqMUjVY67heP9utvcE/NqubhCx2/88iBL61Woj6wdJ1dRUz09dRPUunUg3UmdjIRl9t2Ce7flTeIW7Uoao/vk1OA9b8Y= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=aspeedtech.com; spf=pass smtp.mailfrom=aspeedtech.com; arc=none smtp.client-ip=211.20.114.72 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=aspeedtech.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=aspeedtech.com Received: from TWMBX02.aspeed.com (192.168.0.24) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 19 Jan 2024 13:45:49 +0800 Received: from localhost.localdomain (192.168.10.10) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Fri, 19 Jan 2024 13:45:49 +0800 From: Dylan Hung To: , , , , , , , , , CC: Subject: [PATCH] i3c: dw: Disable IBI IRQ depends on hot-join and SIR enabling Date: Fri, 19 Jan 2024 13:45:47 +0800 Message-ID: <20240119054547.983693-1-dylan_hung@aspeedtech.com> X-Mailer: git-send-email 2.25.1 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 Received-SPF: Fail (TWMBX02.aspeed.com: domain of dylan_hung@aspeedtech.com does not designate 192.168.10.10 as permitted sender) receiver=TWMBX02.aspeed.com; client-ip=192.168.10.10; helo=localhost.localdomain; Content-Type: text/plain; charset="utf-8" Disable IBI IRQ signal and status only when hot-join and SIR enabling of all target devices attached to the bus are disabled. Fixes: e389b1d72a62 ("i3c: dw: Add support for in-band interrupts") Signed-off-by: Dylan Hung --- drivers/i3c/master/dw-i3c-master.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/i3c/master/dw-i3c-master.c b/drivers/i3c/master/dw-i3c= -master.c index ef5751e91cc9..276153e10f5a 100644 --- a/drivers/i3c/master/dw-i3c-master.c +++ b/drivers/i3c/master/dw-i3c-master.c @@ -1163,8 +1163,10 @@ static void dw_i3c_master_set_sir_enabled(struct dw_= i3c_master *master, global =3D reg =3D=3D 0xffffffff; reg &=3D ~BIT(idx); } else { - global =3D reg =3D=3D 0; + bool hj_rejected =3D !!(readl(master->regs + DEVICE_CTRL) & DEV_CTRL_HOT= _JOIN_NACK); + reg |=3D BIT(idx); + global =3D (reg =3D=3D 0xffffffff) && hj_rejected; } writel(reg, master->regs + IBI_SIR_REQ_REJECT); =20 --=20 2.25.1