From patchwork Wed Oct 18 15:59:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Li X-Patchwork-Id: 154952 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:612c:2908:b0:403:3b70:6f57 with SMTP id ib8csp4894206vqb; Wed, 18 Oct 2023 09:01:25 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF7tyDGwYXYRsoM3Q91bXyWMGMoRZ5puYAKELPSnLAHdpCzxvUM/EJNqHqsCGr38Wy9MTGM X-Received: by 2002:a92:cd4d:0:b0:350:f353:4017 with SMTP id v13-20020a92cd4d000000b00350f3534017mr5748465ilq.0.1697644885424; Wed, 18 Oct 2023 09:01:25 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1697644885; cv=pass; d=google.com; s=arc-20160816; b=hfD+AdJVqKoycXW/XnxUV2oGcX1klPWdlKc6cqBNvhFkQf4fUWwbWbmTFWF0zYnv5d nWrbd+ztLkDXhmjVXig92DWiffrOlNCJoQKkR3udrctErg1iUVUkaXHwN44te4uY5rF2 Ypv6UdMV+g+I96j2+76QVAz30OVlhHBmGPUdr0BokYlAk1CFao84JmwJ9vC3h9fLHyku nsWHlR0dnqvvT9QX6G3eOZmxKFXmhj5bF4/azn+bV+ENyoNfhBiHRzrTssWHlpmBgBeB OAYqbXMGVq/grRmeSdOEgyr5rLBlVsxFKQ1MJjJ/1JHoV4OH4W6ld1i4jNAscPu5fC22 eLGA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=HRiKdLELnJRJ0nyk972LH2tykiePszc/EPeBiGyUew8=; fh=sDe3TG6/b46JEOvF2xh0f1K4oYWCH8cpxTVfh1/w/G8=; b=PnvRQ09t5BjJyvBWpL2ypS4iPPwN6aSx9REGvCOaZw/O3v28NZfhMoKy9FIcNFr/1V BugJZSKT/3ez9S2epo+Xnr1zBfQSk4uG3KmlO6ZKQGltF+j3kj4Kz39iMtQoLOaTWfh7 pS/uc6yBiCs6c5+TJgWSK5rgNzyEWdtf7eTokr8i+T9WMSAzghVGgJHBkxtqk9COhZw6 BwL2CSHakDXe8dUXNZYpqkeILSjVqBfnskK3cXgo707GB4Jy2EAYjienHt0lgJLgk7hX nWN3uFeQysKEnFcoTJSG2JCf5XtQbraFL2hWZtHwNQCGGUrCEb3mJ6e+FGwS40AbXG6u O5PA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=eFQdEt20; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id a185-20020a6390c2000000b005b834096959si1140926pge.851.2023.10.18.09.01.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Oct 2023 09:01:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=eFQdEt20; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id 4ABA880964DC; Wed, 18 Oct 2023 09:00:45 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344823AbjJRQAN (ORCPT + 23 others); Wed, 18 Oct 2023 12:00:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42036 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232413AbjJRQAC (ORCPT ); Wed, 18 Oct 2023 12:00:02 -0400 Received: from EUR01-HE1-obe.outbound.protection.outlook.com (mail-he1eur01on2047.outbound.protection.outlook.com [40.107.13.47]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DF6B7124 for ; Wed, 18 Oct 2023 08:59:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kDV0hPtOlQJ+7rTJ0Gpm6ns48CC2s4UrF6W+7RRs98UWmqNWRVBCPN5M5zROTMIpB+P8Jej9F9scHoZiJuWCmB6dEUc5xsEyWZ3NsS8cCQ9ImIw2A9Ar2zQ+8b9WvhBalNtbecQSOUZt8SVVa89cjnVZd2wt6Pq9VMpdaRLHQbVz1eZabFC77MVcvum0WviwBcudD4jh6EIY9250tXZQ4rVJmaN2oKi93pVEXKrNnCVlnQeJWWsM1TAm3Kea4uIs87RxRwT7ASxB1h7APa5pGFi87qU5MzTPsW1xlRutMoDn4u2ys/jWZnljVjlfBuyAoHQ1bWWP/vQwqXVQi/kiEQ== 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=HRiKdLELnJRJ0nyk972LH2tykiePszc/EPeBiGyUew8=; b=CiUgteJwKCd3F4RhILwFl1gDX93Q3mr6BOnCg0Yh0O8SdxNvYc3BtB/uk12CYxpI+n8eRFvEl3Got8mdenYhAvMXL8cIG9lW9ZbqZq4Ti+8nZ97NjMPOKoxNDkQnk09YCG9dlLllczvkmg/2x8KqXD+rfZ+ThbJwfMR/ekgdidqVqSp9fxPs+5sPfS60sZK0oDPnU7Fz/FggvZSLtPB+afjtw/L6usdZtAQU83zcNxLKmF8ZSnI/Xupae06ViPPzhR+m5+i0gED3eM7LlmZ4O9PYNt2Ff4fesx5xXyHZky8WLkGT8c5LqhwW9H+Z7Z0d7d8niiPFEhY9TWY8GkVp+Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=HRiKdLELnJRJ0nyk972LH2tykiePszc/EPeBiGyUew8=; b=eFQdEt20fjK6bS9B1YSbLwYZz9NOGOSEkaaaJJnYLLKbIi7Zt7HGN8pmlO85KAi3KjES/QkmKStkRyLdTDCOjwVprLIL/wEBoUsbDNP4GX63MbWt0iMDKDlrlxWBdMaHvwtxJNm2f8pmer9gDYEsQm4jL8skXfE+kZVpCw5uk2o= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AM6PR04MB4838.eurprd04.prod.outlook.com (2603:10a6:20b:4::16) by AM7PR04MB6966.eurprd04.prod.outlook.com (2603:10a6:20b:109::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6907.23; Wed, 18 Oct 2023 15:59:56 +0000 Received: from AM6PR04MB4838.eurprd04.prod.outlook.com ([fe80::1774:e25f:f99:aca2]) by AM6PR04MB4838.eurprd04.prod.outlook.com ([fe80::1774:e25f:f99:aca2%4]) with mapi id 15.20.6907.022; Wed, 18 Oct 2023 15:59:56 +0000 From: Frank Li To: miquel.raynal@bootlin.com Cc: Frank.Li@nxp.com, alexandre.belloni@bootlin.com, conor.culhane@silvaco.com, imx@lists.linux.dev, joe@perches.com, linux-i3c@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 Resent 5/6] i3c: master: svc: fix SDA keep low when polling IBIWON timeout happen Date: Wed, 18 Oct 2023 11:59:25 -0400 Message-Id: <20231018155926.3305476-6-Frank.Li@nxp.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231018155926.3305476-1-Frank.Li@nxp.com> References: <20231018155926.3305476-1-Frank.Li@nxp.com> X-ClientProxiedBy: SJ0PR05CA0210.namprd05.prod.outlook.com (2603:10b6:a03:330::35) To AM6PR04MB4838.eurprd04.prod.outlook.com (2603:10a6:20b:4::16) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM6PR04MB4838:EE_|AM7PR04MB6966:EE_ X-MS-Office365-Filtering-Correlation-Id: be53f2c2-92ae-46d9-09d0-08dbcff345c8 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: EXo3zhscrBsauzK+Q6NamX0iK2PYI6J9S34Qe/JVPL9UuBPA/dCQ+DClA3fy8oUu6Q5ZpH8TAm5qkgFBI/MjThtsFGT9NgQJ4HaiqOukAkpi89myIRxlOVaMwR4OGV/9Cd9vMuIzmwFLxTsOrxN4iKrU+bLD5pCWmaMC9bgOGq7PE7InIJyhYaCrqDBBLU/LidnzlnJL5W40iJH/G08gl0/xxtEvtyh4J3ZN9b/ZdZp/sSdeMa0DeeOf5vUAf1ztUf7MLJ42Z/rZjJAIF4fHg4HmgVq74+setNO4qVwxFWHKn8DXOchRh8L4toAD3pSOgSfj9C/5+q85oxqEmta408hpuqpd1o22FFGr8xxf09trXiE4ySxZAXOiIlAgYfDbr0q1wyoyDGEWL9hehjdyf40XyNz5Ger8A0f8W/vsZE+x7XX0m5B0ad0ejALxwORQskYgInmZXgNHfM92c+e3sCZujYLkUERcKS/49QPmtZJ+oorE2BChRriZbRAJGAwxXvA91159rkZjMmgnq5F8W0LPiHoeXnyuT5lNfq80WOA3zfcatlXGjndci6hIBe5qyJLS6ma2UY+/vKwjJ4AH+07i84oyAItvCaSV38REvNF8E2IiUkQd0aRNEQGYSQvH X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM6PR04MB4838.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(366004)(39860400002)(346002)(376002)(396003)(136003)(230922051799003)(451199024)(64100799003)(1800799009)(186009)(2906002)(4744005)(478600001)(6486002)(6666004)(38100700002)(8936002)(5660300002)(8676002)(66556008)(4326008)(66946007)(316002)(36756003)(66476007)(6916009)(86362001)(41300700001)(6512007)(52116002)(1076003)(6506007)(2616005)(26005)(38350700005)(83380400001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: ydFHcasc5LkaRtZsorlH9V8tXLhyh5C0pkl3Ea4K1d52XeEi40BCZrzkMg3tF0h50ulivUlvvHtm0A/qa4Zi/g43iwMBtSicz8nSpwO7jpTUGo9/jngU8PbBmRZRl6N+cMMBTyLQCNN4ss7sF25vH/BtTYVd82oHGXwN5MKPc+jCwhjvmarQRw9wAtl+KsASbQNJJvukOhdcnfXOSQKVtf7o/epo42MTaM3MdDsQRISnG3bjzprMw7++irxeLUkBCvfXh87m/4NObN6tao3exOc0WirsyrDdIKKqdh12mWicb9iNxkOYlBn4D6LH9WERyruXzw/7NHaul9PKRfVp4S9t+SizNsgPKHKlqMxDfGhPKT5UWQwD7E6aV7MDbWxfmMPuYo9trHAJYVTpogsuIEk9USOn+zIsSx4G6wy0nf08opPyIXXt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OeCA9DhQmkYb913lxSto5fcawqEGlICobyQMUMMcna9FTnR5ZSZdFOU2pvYDMNGhjEU0LJCdYloAs8MFquLCli X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: be53f2c2-92ae-46d9-09d0-08dbcff345c8 X-MS-Exchange-CrossTenant-AuthSource: AM6PR04MB4838.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Oct 2023 15:59:56.1138 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: zDJOlxiKPeawwY6QwaXrSwjINlntWoxxPVSVO7Nyz5rz3QjUEdkFE+4P+ujUoyJIJXj/2Vro+TmN4LRVJ7TANw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM7PR04MB6966 X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Wed, 18 Oct 2023 09:00:45 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1780109683295828949 X-GMAIL-MSGID: 1780109683295828949 If IBIWON timeout happen, SDA line will always keep low because miss emit stop. Call svc_i3c_master_emit_stop() to let i3c bus come back to idle statue when IBIWON timeout happen. Fixes: dd3c52846d59 ("i3c: master: svc: Add Silvaco I3C master driver") Cc: stable@vger.kernel.org Signed-off-by: Frank Li Reviewed-by: Miquel Raynal --- Notes: Change from v1 to v2 - Update commite message drivers/i3c/master/svc-i3c-master.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/i3c/master/svc-i3c-master.c b/drivers/i3c/master/svc-i3c-master.c index b113460f059c3..1a57fdebaa26d 100644 --- a/drivers/i3c/master/svc-i3c-master.c +++ b/drivers/i3c/master/svc-i3c-master.c @@ -404,6 +404,7 @@ static void svc_i3c_master_ibi_work(struct work_struct *work) SVC_I3C_MSTATUS_IBIWON(val), 0, 1000); if (ret) { dev_err(master->dev, "Timeout when polling for IBIWON\n"); + svc_i3c_master_emit_stop(master); goto reenable_ibis; }