From nobody Fri Nov 29 22:47:34 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org ARC-Seal: i=1; a=rsa-sha256; t=1620311857; cv=none; d=zohomail.com; s=zohoarc; b=Lx9TZTL5lLbOAXdeGVQkvLYDeSsysRMWXQkXLWsJIYH1v1KX1DegIz6f/9gutZdL8Xa3bwE14yGyuQWlOf3RtPZfVipPZM+012Ws7riI3AuaIacLgLsSTfg01FWmGirho2DzfzJ5gqXP2WGOU81RJkIa+ucZkx6yJFo8Zl7+mwI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1620311857; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=P2Px6qTYzYZPLLKEWhYYdblWWoWH38DuUmLm5MFC+Lk=; b=MVXR767VOoFIQ1BOJvJLtmsvj/zlJwsGzB2Mmrx0vKoML7qcOvB+2HEUBFPLBsFQtLdB28nDFCDoH4UUS/Df2ggXjbj02GZP/aIy7gC88bS+YLyM0Pbd7s3ylXsltvFs8VM6Bgg8J0npLt2m7t7+piVa7s19UiXZXd6PLvaaU54= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1620311857556653.9344091856552; Thu, 6 May 2021 07:37:37 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.123608.233180 (Exim 4.92) (envelope-from ) id 1lef7z-0000nQ-NG; Thu, 06 May 2021 14:37:23 +0000 Received: by outflank-mailman (output) from mailman id 123608.233180; Thu, 06 May 2021 14:37:23 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1lef7z-0000nJ-KG; Thu, 06 May 2021 14:37:23 +0000 Received: by outflank-mailman (input) for mailman id 123608; Thu, 06 May 2021 14:37:22 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1lef7y-0000n3-2n for xen-devel@lists.xenproject.org; Thu, 06 May 2021 14:37:22 +0000 Received: from vps.thesusis.net (unknown [34.202.238.73]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 83adba90-03e3-426e-bcd9-924df4c61081; Thu, 06 May 2021 14:37:21 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by vps.thesusis.net (Postfix) with ESMTP id 5B79E2F0DC; Thu, 6 May 2021 10:37:21 -0400 (EDT) Received: from vps.thesusis.net ([127.0.0.1]) by localhost (vps.thesusis.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id OyGslXEEArnl; Thu, 6 May 2021 10:37:21 -0400 (EDT) Received: from debian.. (097-068-109-042.biz.spectrum.com [97.68.109.42]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: psusi) by vps.thesusis.net (Postfix) with ESMTPSA id E857B2F0DB; Thu, 6 May 2021 10:37:20 -0400 (EDT) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 83adba90-03e3-426e-bcd9-924df4c61081 From: Phillip Susi To: phill@thesusis.net Cc: xen-devel@lists.xenproject.org, linux-input@vger.kernel.org, dmitry.torokhov@gmail.com Subject: [PATCH] Xen Keyboard: don't advertise every key known to man Date: Thu, 6 May 2021 14:36:54 +0000 Message-Id: <20210506143654.17924-1-phill@thesusis.net> X-Mailer: git-send-email 2.30.2 In-Reply-To: <87o8dw52jc.fsf@vps.thesusis.net> References: <87o8dw52jc.fsf@vps.thesusis.net> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" For reasons I still don't understand, the input subsystem allows input devices to advertise what keys they have, and adds this information to the modalias for the device. The Xen Virtual Keyboard was advertising every known key, which resulted in a modalias string over 2 KiB in length, which caused uevents to fail with -ENOMEM ( when trying to add the modalias to the env ). Remove this advertisement. --- drivers/input/misc/xen-kbdfront.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/drivers/input/misc/xen-kbdfront.c b/drivers/input/misc/xen-kbd= front.c index 4ff5cd2a6d8d..d4bd558afda9 100644 --- a/drivers/input/misc/xen-kbdfront.c +++ b/drivers/input/misc/xen-kbdfront.c @@ -254,11 +254,6 @@ static int xenkbd_probe(struct xenbus_device *dev, kbd->id.product =3D 0xffff; =20 __set_bit(EV_KEY, kbd->evbit); - for (i =3D KEY_ESC; i < KEY_UNKNOWN; i++) - __set_bit(i, kbd->keybit); - for (i =3D KEY_OK; i < KEY_MAX; i++) - __set_bit(i, kbd->keybit); - ret =3D input_register_device(kbd); if (ret) { input_free_device(kbd); --=20 2.30.2