Received: by 2002:a05:7412:3784:b0:e2:908c:2ebd with SMTP id jk4csp1824227rdb; Tue, 3 Oct 2023 01:58:19 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGsbWupcWflTBc8qX5PKnmPaO4snmpvPUTlNm5TwOhonBmcwvmzTKmDu/62/BQyXZLYrtc0 X-Received: by 2002:a67:fbcd:0:b0:452:707c:3f73 with SMTP id o13-20020a67fbcd000000b00452707c3f73mr12243911vsr.3.1696323498805; Tue, 03 Oct 2023 01:58:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696323498; cv=none; d=google.com; s=arc-20160816; b=YWk1wYQYdPOCWKyJO1COaxTtM0LqNVR8qB0qwGyNw8peW24VxYTpevgOJP5Pqk7/NB u8oz4zMNbUbKyK+ZDaAJfTQ0fOqIfVH4cekGxWNr5YWF9BlyRpBuWTtdiaih0IAorVP6 4xCPt36uvUexy6eFFupaDGvToGHJvONdWjVCaS8Xp33nuRAl/ZnMqlEk7ZJ99qOHZeDE Ne/Kqvb/IHwLZVExOhep7LXyGg9s2FpSAeDDWmZ9A1m1GbRuMAQmMoSIm5Zhkf1qwP83 sk4tRg4r6ga/UiaNMwi7VfAJGmDaOyclvTJEtnoevFXseG5gA1aQIdhEJKM99Wp3hRTo 3+ug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:organization:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=VmfnHRl4N+lqHa48DMnON6ycyJZpPrMvGoYYDafmuLM=; fh=MZGrl9Cf6y1245ujv2W6CdWOZqw+zWXyXMPuAca6M7k=; b=JA8m3rHuPYbjyDkvUnwNL+1V8qNeqpHjqXllf58DWryPRRSQMF8+i/hqFQCM65eJ5n USYOkuGLbc96yT9V5uwtRA22Z3oui2VZWvlCbSiLXiYBEq6jNzI1ipVMATaM4lRr46W2 dCdGSKxZ/3DOurvZdpk+3O06COFRYr/s6Te7c8YGOvfYNWJBZLnYGiUQBXgxuj9KVdhB Y94H3r6HXnuzLT7eSFnCWZtmjf6cIzel5nEFxrFyLBj5BOsq/sF0azXQNR72jcFENI63 VM3eAaiK8W0mG5xh/MiGa3P5EZPtcQ/3EluVtZzNuUl+UMfRv7nHS2PNbSD4K3vYPSQv 0eew== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=OuvXAuNK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id x11-20020a63fe4b000000b00578af609d05si997228pgj.244.2023.10.03.01.58.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Oct 2023 01:58:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=OuvXAuNK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id A86AB80FCE3A; Tue, 3 Oct 2023 01:58:16 -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 S239541AbjJCI6K (ORCPT + 99 others); Tue, 3 Oct 2023 04:58:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55788 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239537AbjJCI6J (ORCPT ); Tue, 3 Oct 2023 04:58:09 -0400 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.151]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E5EB5AF; Tue, 3 Oct 2023 01:58:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1696323484; x=1727859484; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=dLKfzWcsf70/Y3M11dv8yZFYzYdOU1fQSbZAMIbOyV8=; b=OuvXAuNKOdhvhOlITC6nQBXykoXnSMNvii/xn96FwpEbg1MRmFXfdLOE lmGxGuqcLBbgvc0qGHfx5/a0a/bBcgfgObVCoNjr9FxapaFzvUhB7btWa vZxeeltGGn5uocfs8soGie8Qr7Gts4E49zAMEpW6B1GEYGS+SfP7JBcdJ dudB1zbju7RzN+1oe4MZn8glyRNczD5zmgVFzX9gHWitkZoNNuViINN/A DVT4J7rVu5O6nwQC1u3rADDHKhLFMVl1yX7NWtvaGLgoOJ3CrcjLLn0oC dYWJr4n1X7MTUJCzlYF1Ii2L1FTVA6qIe5METOdltRc28qro5carzAVCx g==; X-IronPort-AV: E=McAfee;i="6600,9927,10851"; a="363094905" X-IronPort-AV: E=Sophos;i="6.03,196,1694761200"; d="scan'208";a="363094905" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Oct 2023 01:58:04 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10851"; a="700631613" X-IronPort-AV: E=Sophos;i="6.03,196,1694761200"; d="scan'208";a="700631613" Received: from smile.fi.intel.com ([10.237.72.54]) by orsmga003.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Oct 2023 01:58:01 -0700 Received: from andy by smile.fi.intel.com with local (Exim 4.97-RC1) (envelope-from ) id 1qnbE6-00000002RHo-2Hqw; Tue, 03 Oct 2023 11:57:58 +0300 Date: Tue, 3 Oct 2023 11:57:58 +0300 From: Andy Shevchenko To: Tam Nguyen Cc: linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org, patches@amperecomputing.com, jarkko.nikula@linux.intel.com, mika.westerberg@linux.intel.com, jsd@semihalf.com, chuong@os.amperecomputing.com, darren@os.amperecomputing.com, stable@vger.kernel.org Subject: Re: [PATCH v1] i2c: designware: Disable TX_EMPTY irq while waiting for block length byte Message-ID: References: <20230929035356.6435-1-tamnguyenchi@os.amperecomputing.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230929035356.6435-1-tamnguyenchi@os.amperecomputing.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,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]); Tue, 03 Oct 2023 01:58:16 -0700 (PDT) On Fri, Sep 29, 2023 at 10:53:56AM +0700, Tam Nguyen wrote: > During SMBus block data read process, we have seen high interrupt rate > because of TX_EMPTY irq status while waiting for block length byte (the > first data byte after the address phase). The interrupt handler does not > do anything because the internal state is kept as STATUS_WRITE_IN_PROGRESS. > Hence, we should disable TX_EMPTY irq until I2C DW receives first data IRQ DesignWare > byte from I2C device, then re-enable it. > > It takes 0.789 ms for host to receive data length from slave. > Without the patch, i2c_dw_isr is called 99 times by TX_EMPTY interrupt. i2c_dw_isr() > And it is none after applying the patch. > Cc: stable@vger.kernel.org > Signed-off-by: Chuong Tran Who is this guy? Do you need Co-developed-by tag? > Signed-off-by: Tam Nguyen Other than that, agree with Serge's points. -- With Best Regards, Andy Shevchenko