Received: by 2002:a05:7412:3784:b0:e2:908c:2ebd with SMTP id jk4csp1746865rdb; Mon, 2 Oct 2023 22:28:57 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH/I7HZNloI4GqLAsDH+Fn7CjI+50LFSXCH3VR9gSKscc1BdqE6CVAcI7wTJZCcwEq1Tr7g X-Received: by 2002:a17:902:7445:b0:1c3:2df4:8791 with SMTP id e5-20020a170902744500b001c32df48791mr12447299plt.27.1696310936937; Mon, 02 Oct 2023 22:28:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696310936; cv=none; d=google.com; s=arc-20160816; b=GMYiH97B7dfQtkTsEEoZllgfhrK4qnCP2yM4gFcZlYiRt5vVAq3d+8GUAMBxJnzcOJ Y/f7Km/NG9qQTaMUBMkA+Gm75yAUnmSIb8MlQeB8oHyeLOTLerPBT1ybxwPzy+3feotd 9FV5sv6L5JREmKMwCjLnB0WkozINg8OiaYOUGQ44hG8O7FfMz4eo37XXEmTX9hGCKvCF 85D8sPOuX9JDnyu4UdvaP05xM+ZN939TD7swtg5GbXpSczoqQbduQd+3ewAGD/sAsXHZ eQfPSg2l1/khWfaeW2YjxriZnHdMpZ+u6ePpsd/8YZ3FyKrwuoLnQIA2HFPyWqAuBCaE VkCQ== 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=Rr5bNnF/FWxB7Qk6GjZdbkA6qx7sct4vgiXqIc7Lwa4=; fh=4FTxD8y/AkqrxGSds7He/tgcu1K8JroTMbxcGH2DVaw=; b=0oEOHZNXiZKj7SiiY7RlQiYT960Y/m33wH+iPhURbuBlsY2IbK7AapjCkCFzUE1UZq jhuRi/8YNFdGUfkPvdDGQTdl9ZMudXt71uzx/iZbGtNPshKrQMy7/2b/qO/MdxrG4loU VZ7MZOaJrpgpp04AyhVuD9uw/YDWDSqGaJr1DVjFfUBQ4GdLBuqxSDCB17czc+dXyNZ/ 9+8C2UvP+9PbptHLJrdOL4n5XzyVkGlBnQvQbzul4niBZ9SYWaVKUKP4GvPS9sU193ES 332hvOFK6HL8BUor69UeknqO3pYKGRPjL7X8GoNWB0OHjNYjkea1lYV7i+DCQDztlb1m 5gOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=h6Ckbp4+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 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 lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id n6-20020a170902d2c600b001c62b9d56f8si634067plc.606.2023.10.02.22.28.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Oct 2023 22:28:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=h6Ckbp4+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 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 lipwig.vger.email (Postfix) with ESMTP id 549D380254F4; Mon, 2 Oct 2023 22:28:53 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230216AbjJCF2q (ORCPT + 99 others); Tue, 3 Oct 2023 01:28:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39392 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230140AbjJCF2p (ORCPT ); Tue, 3 Oct 2023 01:28:45 -0400 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.93]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 75BC1AD; Mon, 2 Oct 2023 22:28:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1696310922; x=1727846922; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=203ognjAhnNOsI/vtF++RU0GEWWjqcYC0JjAaxaiY6w=; b=h6Ckbp4+b4DuqWQ73vsscdp2lhi3eEUSQdnIUg8K1Ao4nHs5L3YbFDph 6wJG5TxtjLmm/j5L089na3fCKJ410NB73wkfyPtAr8qjSaWKhw6Y3SR+y NfN9KRsg0nB09vIa+knrVXA8tXKcpYWwBUjoiYFp/C3IQGMSZ3V01lIeU ODkddcAiIorrRVKXEjjmjLboiv1P+ccjHcHv6Pi3Ze67EI+TTiP+Fy781 1uJBXJqZAIuBsZDbCnSecgsf0VILEKDZFz6EmcG8m4D5ewhMc6n9xuLsX 5l4UDJXofIICGlC2wPngK8nLx/1wbTZRj9URhMkJsmieXYrYMtdR9L0w3 A==; X-IronPort-AV: E=McAfee;i="6600,9927,10851"; a="380072528" X-IronPort-AV: E=Sophos;i="6.03,196,1694761200"; d="scan'208";a="380072528" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Oct 2023 22:28:41 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10851"; a="821110122" X-IronPort-AV: E=Sophos;i="6.03,196,1694761200"; d="scan'208";a="821110122" Received: from kuha.fi.intel.com ([10.237.72.185]) by fmsmga004.fm.intel.com with SMTP; 02 Oct 2023 22:28:38 -0700 Received: by kuha.fi.intel.com (sSMTP sendmail emulation); Tue, 03 Oct 2023 08:28:37 +0300 Date: Tue, 3 Oct 2023 08:28:37 +0300 From: Heikki Krogerus To: Abdel Alkuor Cc: krzysztof.kozlowski+dt@linaro.org, bryan.odonoghue@linaro.org, gregkh@linuxfoundation.org, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, ryan.eleceng@gmail.com, robh+dt@kernel.org, conor+dt@kernel.org, devicetree@vger.kernel.org, Abdel Alkuor Subject: Re: [PATCH v9 03/14] USB: typec: tps6598x: Add patch mode to tps6598x Message-ID: References: <20231001081134.37101-1-alkuor@gmail.com> <20231001081134.37101-4-alkuor@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231001081134.37101-4-alkuor@gmail.com> 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 lipwig.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 (lipwig.vger.email [0.0.0.0]); Mon, 02 Oct 2023 22:28:53 -0700 (PDT) On Sun, Oct 01, 2023 at 04:11:23AM -0400, Abdel Alkuor wrote: > From: Abdel Alkuor > > TPS25750 has a patch mode indicating the device requires > a configuration to get the device into operational mode > > Signed-off-by: Abdel Alkuor Reviewed-by: Heikki Krogerus > --- > Changes in v9: > - No changes > Changes in v8: > - Revert mode check return > Changes in v7: > - Add driver name to commit subject > Changes in v6: > - Return current mode and check it directly > Changes in v5: > - Incorporating tps25750 into tps6598x driver > > drivers/usb/typec/tipd/core.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/drivers/usb/typec/tipd/core.c b/drivers/usb/typec/tipd/core.c > index 32420c61660d..c5bbf03cb74a 100644 > --- a/drivers/usb/typec/tipd/core.c > +++ b/drivers/usb/typec/tipd/core.c > @@ -68,6 +68,7 @@ enum { > TPS_MODE_BOOT, > TPS_MODE_BIST, > TPS_MODE_DISC, > + TPS_MODE_PTCH, > }; > > static const char *const modes[] = { > @@ -75,6 +76,7 @@ static const char *const modes[] = { > [TPS_MODE_BOOT] = "BOOT", > [TPS_MODE_BIST] = "BIST", > [TPS_MODE_DISC] = "DISC", > + [TPS_MODE_PTCH] = "PTCH", > }; > > /* Unrecognized commands will be replaced with "!CMD" */ > @@ -595,6 +597,7 @@ static int tps6598x_check_mode(struct tps6598x *tps) > > switch (match_string(modes, ARRAY_SIZE(modes), mode)) { > case TPS_MODE_APP: > + case TPS_MODE_PTCH: > return 0; > case TPS_MODE_BOOT: > dev_warn(tps->dev, "dead-battery condition\n"); > -- > 2.34.1 -- heikki