Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp687354iog; Fri, 24 Jun 2022 11:45:08 -0700 (PDT) X-Google-Smtp-Source: AGRyM1t0LKn5ZmCMNskpQlhjNA4Jt1TXW8pPILv7P5LDiAm18PjhITL9b3vvDrxIMeEh59VjXtXC X-Received: by 2002:a63:4f09:0:b0:3fd:3479:7624 with SMTP id d9-20020a634f09000000b003fd34797624mr201520pgb.425.1656096308153; Fri, 24 Jun 2022 11:45:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656096308; cv=none; d=google.com; s=arc-20160816; b=FlDjFGs2MswON/cc2j6MQMZcpQxJS2uYSi/SjERnBzuICno7Fzxf6gg8u0IYMBCg9m i7Np8/wW/b/UuJfG5IPDBITJl5cLchax7AYSoznGfhq0b3q/7R8wQYZCuSnIBOmBTylc blMgLfriIXvsA50pl+OURS3wZ6gNorvo5jBeMNPAAeQJ1JIQyQtm+IpIzHQHHhlIZb3s grSUY6RzlwUFDwLWhG9VfU0Y2FTBGd1w3MIrMTq1WG7a8Yswn3dFEme7qIp78Dej97xd 8n+bEu9nwoAF/bh+IvOmcw7IZhPOviI//VpjE2NkZoxgYhEsc33plPOGVrvAXjO/E7xz QtXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=Wk5pMy7Zd97VX3BKR5VEk1jaORfYL6tDVYZN+cZYFto=; b=RkDYyU5xJvhrJE4CQJ6XqxYH3rpN+DnAOizPrXmxiS74Jqenc+mfF+MoXmXr67A+Mo u6JQSYuJ9UbCjMh0E4rs2u3UYqwbZLuJV9jcOPS4ZtG8axc24W8+ThO70xcpk+fp1PPc 29ulCMSlzo4zEgduqQkpdYK9jRy+HyxASdh+6zBNVMdYd5pVRU1DilOmWbirMBxAt0V6 JmrfeF9M+//Xa06JVpWUaQIrysQ9CNMs1L3BdA9CrCaULqHtSQ3KiNMEsERBUTQy7Pk3 EfFLQkNTJfyiQOeqiaBt/l0IvA1UdC5P43SEVwdKuH2LuhaYxK81s6oFywDYK1kj2H1d Zz0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=RRMHywXN; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u7-20020a170902e80700b0016a4a57a285si4802451plg.95.2022.06.24.11.44.54; Fri, 24 Jun 2022 11:45:08 -0700 (PDT) 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=@gmail.com header.s=20210112 header.b=RRMHywXN; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231708AbiFXShR (ORCPT + 99 others); Fri, 24 Jun 2022 14:37:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35910 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231569AbiFXShI (ORCPT ); Fri, 24 Jun 2022 14:37:08 -0400 Received: from mail-ej1-x62e.google.com (mail-ej1-x62e.google.com [IPv6:2a00:1450:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1295B8126C; Fri, 24 Jun 2022 11:37:08 -0700 (PDT) Received: by mail-ej1-x62e.google.com with SMTP id ge10so6385469ejb.7; Fri, 24 Jun 2022 11:37:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Wk5pMy7Zd97VX3BKR5VEk1jaORfYL6tDVYZN+cZYFto=; b=RRMHywXN0k5cnqLRZ1tqLahM6ZdigXE5VNCurGhJPbwCK6VI0UaIwBPmznefCYqhUI GkTxDznIPnPaZq5Wf8w9ESY2dzStS/Kk/Gor9ZgXBYskw+YXz2KLDkWRvV9boTegcIFx gsm2maO/0TEmcjAlaRTBdJ201yVUMOovz0OlAJ8H5kwfo90kG7+FRlM6scCWk/EqGefI IwlC+aSQGOcOGXGh5T2BPNK6sMkgrrzCwMgiiQbIv+lzY0gWR2cM4gG3NM9wKg4yxQ/t K3jQTnI41UfKyefGLXg9vZmC8Bzo/Wjd8N0qdFrosEE4ZjXd2IrGrQrA/bPDVfyThXFI eIHA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Wk5pMy7Zd97VX3BKR5VEk1jaORfYL6tDVYZN+cZYFto=; b=m7dZK4TNgHP0dOpU0XVE9OhwH5TCqSLp4Jq34i2lfEex6lXolpJoXMktMrYCq/7qFT jqLLxR4KQorRv8KTCKJWR/dqI2C2o0qJEeG+0HhpKyLEg6tgL/8peHkEPGqFQiFTVYw9 Jrb4C+a141qil631NxkqO27LguuR4q2h0cCcvilpbMSMV4U4nFfeokbZgezjWq6CvpE6 V7+ChjoDnVLlZXBW1qFNUZa3IVbfWOHRZoxyREAlLxvvdDqLYW0v/IhZr0i3DDcs2O6V bsGmeA5jmmnfof7lbn5YH9oJ1h8BX2hvAbF1TFsbJ72MDA7pzMSr16xnYrWdWgikMMWp YqTg== X-Gm-Message-State: AJIora/ipMq0I0kALdNX/lOpsc3vrREgeiXLs7h9/44RliZcfWVm3/3s NkhWEcC5wCar10QuMwnbqxg= X-Received: by 2002:a17:907:6d0c:b0:726:32e5:1736 with SMTP id sa12-20020a1709076d0c00b0072632e51736mr370371ejc.596.1656095827578; Fri, 24 Jun 2022 11:37:07 -0700 (PDT) Received: from xws.localdomain ([37.120.217.162]) by smtp.gmail.com with ESMTPSA id jw12-20020a170906e94c00b00722e8827c53sm1493822ejb.208.2022.06.24.11.37.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 Jun 2022 11:37:07 -0700 (PDT) From: Maximilian Luz To: Hans de Goede Cc: Mark Gross , platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, Maximilian Luz Subject: [PATCH 4/4] platform/surface: aggregator_registry: Add support for tablet mode switch on Surface Laptop Studio Date: Fri, 24 Jun 2022 20:36:42 +0200 Message-Id: <20220624183642.910893-5-luzmaximilian@gmail.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220624183642.910893-1-luzmaximilian@gmail.com> References: <20220624183642.910893-1-luzmaximilian@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 Add a POS subsystem tablet-mode switch device for the Surface Laptop Studio. The respective driver for this device provides SW_TABLET_MODE input events for user-space based on the posture of the screen. Signed-off-by: Maximilian Luz --- drivers/platform/surface/surface_aggregator_registry.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/platform/surface/surface_aggregator_registry.c b/drivers/platform/surface/surface_aggregator_registry.c index 8f249df673a4..f1c5905f1c16 100644 --- a/drivers/platform/surface/surface_aggregator_registry.c +++ b/drivers/platform/surface/surface_aggregator_registry.c @@ -191,6 +191,12 @@ static const struct software_node ssam_node_hid_kip_iid5 = { .parent = &ssam_node_hub_kip, }; +/* Tablet-mode switch via POS subsystem. */ +static const struct software_node ssam_node_pos_tablet_switch = { + .name = "ssam:01:26:01:00:01", + .parent = &ssam_node_root, +}; + /* * Devices for 5th- and 6th-generations models: * - Surface Book 2, @@ -237,6 +243,7 @@ static const struct software_node *ssam_node_group_sls[] = { &ssam_node_bat_ac, &ssam_node_bat_main, &ssam_node_tmp_pprof, + &ssam_node_pos_tablet_switch, &ssam_node_hid_tid1_keyboard, &ssam_node_hid_tid1_penstash, &ssam_node_hid_tid1_touchpad, -- 2.36.1