Received: by 2002:a25:ef43:0:0:0:0:0 with SMTP id w3csp353484ybm; Thu, 28 May 2020 04:38:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxzfqUzy/bwVY0wkdaxYiq9Jt1WnoU8KhTyrSe4oZyDB6EAUPkLvPPUeXguFfiMgN8xjNB+ X-Received: by 2002:a17:906:f8f:: with SMTP id q15mr2665806ejj.389.1590665927771; Thu, 28 May 2020 04:38:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590665927; cv=none; d=google.com; s=arc-20160816; b=CO7huwoWpg40XXP4H/FsScyFMLrceSil5Nnd1TLDtJQJX1xsZ66m2MPMvU0N89aitD kx4UpkaznGc5dJXMLzaWcegt2IeVA5efv4bnXBDmBsawFdFFswWF9ZiOfWAtfQeIfujN 6EIlrTbPxsd1qlyaNeF+aszAW7m81IQMfZYuWg/EmLSmF/PoagKPupCBSQeQNyIhL0lH uQl3jocXHaMEPPESIAJJbea4BLFtb6xHi8PmuNQAEx/GaIzdATPJdJ8hufAB5dUbplD2 gwHU9MUrSjJDVcgtr7K41+hFIcIenIM4G/cv7izVHnTSu5+XGkWkglvvfNRhXmK5cLj1 klrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=fad3eBoL47RObuH9V/3Rnk6J6MR5mdA+fugdf/ETXNc=; b=IPLDKpBQWNC+zJAdhZQZOKGTrs5cjrrBJ0gi4yQSGRtDwaYg4lKW7E8ZhM5lcvDnw2 lxndCGPH0quu6CXiynuZ+ejn0hLjd3ufBP3JWF/2xuai9JnOgQfWRu+y4GqJbZdTLjR/ MAusKU4PMuy0lJLzysHn+YDxrcD3jU9iQ6zG3l3j4uAtii7/sBMDC1kmn8epRwqu2Lu1 xksCqrdOuSwt4uSzouRFUkYdTKiifLwfYUEwrFr015ZCPSLmCilDyJNHjjqhU01AjRbs 6mVBAaXsOh0RLMYajqRNUTgB+sQm4RMTSzgUCwkA+VRz2zjxiq1VOrMD1FFTp575Q9Kq 22Tw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=YhKv3XDU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f8si3874838edk.160.2020.05.28.04.38.24; Thu, 28 May 2020 04:38:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=YhKv3XDU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388433AbgE1LgY (ORCPT + 99 others); Thu, 28 May 2020 07:36:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43274 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388326AbgE1LgX (ORCPT ); Thu, 28 May 2020 07:36:23 -0400 Received: from mail-pf1-x444.google.com (mail-pf1-x444.google.com [IPv6:2607:f8b0:4864:20::444]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C4248C05BD1E for ; Thu, 28 May 2020 04:36:23 -0700 (PDT) Received: by mail-pf1-x444.google.com with SMTP id 131so5050106pfv.13 for ; Thu, 28 May 2020 04:36:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=fad3eBoL47RObuH9V/3Rnk6J6MR5mdA+fugdf/ETXNc=; b=YhKv3XDUoqOrGa+J+dM4F35V/jbDpzsQw+fhjNAemqGieG8O6zJalxdN0GFNZxUr1s p+dYtlkPDBinp1enyDSAHAGl+4mNcrnmSRsVlUbWihTk5Z/hS0X11nMDxGPYMuScPy7M qBmsvxhz7tl/zMI0nkZ4u9+WKpG4pJydU7z5s= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=fad3eBoL47RObuH9V/3Rnk6J6MR5mdA+fugdf/ETXNc=; b=jsyUc0OxdKvvkQgU30YHXPPDYP2C3VFxY0fwbrTD6CUm+8OhiuVpwzuR3hJiX1RTsA KEZcAhGZqAlPMCzT8nvC+aSkhoepL0dlE2l1pxrwC47j5KycAfT06ewvhwIAiRexDCPd 2vw8qyHi7uvqTqx2GS0bOcCxvH0y3sdNsFlMtP4V0YbDqTMQuJz2zCNzOI7voND4Ut2r RFea4n+9SgYlMfGBITFofeu01cIuay8JLKUqKeZ92oXAw7QFoJCUdXb8b3ySk2NG2/L8 aH6fFggyDKnkjPduyOg+Pqwaz7vK8AOUz18YGcsSv6fEKeeD6GRn3bNUGe9oue0i/Va2 Gpbg== X-Gm-Message-State: AOAM530RvZOUZHrADibaZ5xLccVMhwb2ke+ttlqMirXD70PwdmZcCW9b 1gxDAv7DHGlcj57GnBusGQanugIaWuk= X-Received: by 2002:a63:d102:: with SMTP id k2mr2530181pgg.178.1590665782413; Thu, 28 May 2020 04:36:22 -0700 (PDT) Received: from pmalani2.mtv.corp.google.com ([2620:15c:202:201:476b:691:abc3:38db]) by smtp.gmail.com with ESMTPSA id g7sm4519961pjs.48.2020.05.28.04.36.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 May 2020 04:36:21 -0700 (PDT) From: Prashant Malani To: linux-kernel@vger.kernel.org Cc: heikki.krogerus@linux.intel.com, Prashant Malani , Benson Leung , Enric Balletbo i Serra , Fabien Lahoudere , Guenter Roeck , Gwendal Grignou , Lee Jones , Tzung-Bi Shih Subject: [PATCH 0/4] platform/chrome: typec: Add mux support Date: Thu, 28 May 2020 04:36:01 -0700 Message-Id: <20200528113607.120841-1-pmalani@chromium.org> X-Mailer: git-send-email 2.27.0.rc0.183.gde8f92d652-goog MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This series adds mux control support for USB and DP alternate modes on devices using the cros-ec-typec driver with Type C switch handles provided by firmware bindings. The first patch imports some recent updates to the EC_CMD_USB_PD_MUX_INFO bit fields from the Chrome EC code base[1], while the rest add the aforementioned functionality. This series depends on the following patch : https://lkml.org/lkml/2020/5/19/1219 [1] : https://chromium.googlesource.com/chromiumos/platform/ec/+/refs/heads/master/include/ec_commands.h Prashant Malani (4): platform/chrome: cros_ec: Update mux state bits platform/chrome: typec: Register PD CTRL cmd v2 platform/chrome: typec: Add USB mux control platform/chrome: typec: Support DP alt mode drivers/platform/chrome/cros_ec_typec.c | 190 ++++++++++++++++-- .../linux/platform_data/cros_ec_commands.h | 14 +- 2 files changed, 187 insertions(+), 17 deletions(-) -- 2.27.0.rc0.183.gde8f92d652-goog