Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp11533573rwl; Tue, 3 Jan 2023 00:13:17 -0800 (PST) X-Google-Smtp-Source: AMrXdXsj2JPhUYYYiBHxQGp+Ki5rTnnwY9ryFe6aa3m5tviA0Ed5i7ChMV27DVYMYuRVV8pnbgic X-Received: by 2002:a17:90b:3597:b0:214:222:6ed3 with SMTP id mm23-20020a17090b359700b0021402226ed3mr47209026pjb.43.1672733597175; Tue, 03 Jan 2023 00:13:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1672733597; cv=none; d=google.com; s=arc-20160816; b=SldzVQkctdi+k7zY4ybz1MU3yni3lfhEw66UGEA6BUoIQUxedgqumqcq8ruh7h2Y5h qlmYzPa9mD22AlAaAkUW9ttzX/1vZDlz37yzyBD8YPr38P/tLxqzcAO53zf3F/AE+jP0 pk4uzZGtO91mr1aiPgVcRf0FJc3Xsyb/UNos9aTFhOs4uBIybUz0Um1KuC0WoAq630XM tAxwBd0LcRZXGwwBghdT8xyh1oG9bX8noTb+2hk/2JPNoZY5jCKY+xM0DK7qdZkO8/Js KPMPa9LNJCh0X54Y2PLDBeyZ1YapEYI/Xv3WKorcaD5ZlEMVd4B2LD9Ui8+I9HmzgpGf r/Fw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=i16ul5qQx/8deIHGynUvDM/misaP5evrLUHqqH7YzmM=; b=wL2NZR6SbKWTy4yeRcf8eW3aVz9xBNrHpGZtz25LkthFvvp0B+tR+G8TwoKcuR1xFt pY4pZ14OVWKWvrEVQ87LKPmVdA8pI8902qoSHzngrIao/joXHYWsf3QBaPwkpaD4ka3k /DL+jJsDnn4K5LQI1NnGjubZ8WzwrFrzguB+vOYcU2LMjd8rCY8gQYa7Ilq1Ry02S7Jp M3RPBcZIXyUMv2E7v1VvjGuccuAw3R9jNghHn1aQfkHpJJygIQ454MWOIkjGM5F0RoWv 8JkXCsJ+5mNYzKiyRAuS4YukyDXQCWZngGuCzh8DFIyGeXkONKBhbyCNMFvJcX/vT8Bm xn1g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=k1KeNQy4; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id nv8-20020a17090b1b4800b002215386c989si34594566pjb.14.2023.01.03.00.13.09; Tue, 03 Jan 2023 00:13:17 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=k1KeNQy4; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229538AbjACHcM (ORCPT + 61 others); Tue, 3 Jan 2023 02:32:12 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51934 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236918AbjACHcI (ORCPT ); Tue, 3 Jan 2023 02:32:08 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 45EB7DEC2; Mon, 2 Jan 2023 23:32:07 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id CE85B611B1; Tue, 3 Jan 2023 07:32:06 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id CD685C433EF; Tue, 3 Jan 2023 07:32:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1672731126; bh=H24tvaVsrQoX2ADT0MUXQLccLC7C362GsTZw5z5q+kE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=k1KeNQy42WiuWE0X+nRN77v/lkFfxwl/YxDyC5GYqHm9PvkfAtxe08eW/z042CMnO DDvNm3x7fWhMTS0Cx05ZO2lB/7u3QPy+yRmMC2d/T+y3pBilqy2aL3ir+H6m8oOOlE TAMsG1AiCR6eiGmrNnli6sfdIFJN23UPwiZHqjmM= Date: Tue, 3 Jan 2023 08:32:03 +0100 From: Greg Kroah-Hartman To: Haotien Hsu Cc: Heikki Krogerus , Sing-Han Chen , Sanket Goswami , Wayne Chang , Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= , Jonathan Hunter , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] ucsi_ccg: Refine the UCSI Interrupt handling Message-ID: References: <20230103024023.235098-1-haotienh@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230103024023.235098-1-haotienh@nvidia.com> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 03, 2023 at 10:40:23AM +0800, Haotien Hsu wrote: > From: Sing-Han Chen > > For the CCGx, when the OPM field in the INTR_REG is cleared, then the > CCI data in the PPM is reset. > > To align with the CCGx UCSI interface guide, this patch updates the > driver to copy CCI and MESSAGE_IN before clearing UCSI interrupt. > When a new command is sent, the driver will clear the old CCI and > MESSAGE_IN copy. > > Finally, clear UCSI_READ_INT before calling complete() to ensure that > the ucsi_ccg_sync_write() would wait for the interrupt handling to > complete. > It prevents the driver from resetting CCI prematurely. > > Signed-off-by: Sing-Han Chen > Signed-off-by: Haotien Hsu > Reported-by: kernel test robot The test robot reported this whole issue? If not, it should not be here. thanks, greg k-h