From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from fout3-smtp.messagingengine.com (fout3-smtp.messagingengine.com [103.168.172.146]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E4005172BA2 for ; Fri, 5 Apr 2024 19:05:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=103.168.172.146 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712343941; cv=none; b=TGPxOCVXoq8PCU6J46RjYVNg3KXOuuPKwgobVu6dqmk9YU/lJ4WIcJmFnHDPyaAALviX1ZFOGia5fB9q1X4dtE7GwWBBp1x9CIfi94Rzh+VcC0AgG3mq/euTR8DAY75A8H2VYZNM811ec9b/UIhv8f2zHOpnThZCOEs4S12+x1w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712343941; c=relaxed/simple; bh=WO6qQRezMcrpBT4MDFXAlW0aruWvAVSwP7M5jItDXAo=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=J7g7ZChxZfPO2+V6FOLZJSUJKerxRiGk+ab66KwPEUlzqPjvfWa1Oyv+HikFW8QbubuYqEVlxMjHdiE61dk9uB7Nz+kvwAQPLwePI4R5N80DdlTQve9uJH9qWh2kCpjUVw6paK/hjElX+/3w2rOj/f1BWITE0CbS8IGiTGKqfzQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=jannau.net; spf=pass smtp.mailfrom=jannau.net; dkim=pass (2048-bit key) header.d=jannau.net header.i=@jannau.net header.b=F0DondE1; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=sBVAL2Fh; arc=none smtp.client-ip=103.168.172.146 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=jannau.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=jannau.net Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=jannau.net header.i=@jannau.net header.b="F0DondE1"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="sBVAL2Fh" Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailfout.nyi.internal (Postfix) with ESMTP id B5C6E1380073; Fri, 5 Apr 2024 15:05:36 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Fri, 05 Apr 2024 15:05:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jannau.net; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm1; t=1712343936; x=1712430336; bh=j+g3mhmYqs xyXMEcsuyZxmVG1iSCSsV/w7wrzW6e59k=; b=F0DondE1m0DRvPPS4RfK2nGtcu Y5SLO/im6fiICQhdvkisneEfS1bz64D7cBso4eoWtS5litaTH8B4XtZKXDoNNSfe 7l7m0TPyBKrjsAyS7gOfV2Z0suKRgJ6gsiKj4AJdLP8M7gpWK7mMGWpOzGk3Yd3M k7c0Zm5lDy22lZ/Yzb9VmYdCs/k0c5kugqleOicpN9L4mqj8dRpYP/6teccF1ZFG YDFuNhUtE40DYyzxf51f6AccoWzliBSUoq9L+MNolTkBCyyfNDfs986vikYX12jT IyXV2xrzZYxI4FeQAxcUXswK5z87gDEDK7BhrEX2XPOSJFITTGMQdY7cY+8A== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; t=1712343936; x=1712430336; bh=j+g3mhmYqsxyXMEcsuyZxmVG1iSC SsV/w7wrzW6e59k=; b=sBVAL2Fh0xeEvQSKTckRjxIe7oj9S4A99svCyafuZ5Uf DQL4qGELwAVSEgEnZgK24sum0myZDRzM4lLPOG6baqMtZfjmw/ErOq4ezy1Bz+rR cNSsXlnHlgajEM0tBMCljtEo0gU4Yn3hjEGmwPmN4E/b9WEYDeXVmpz4r3wIDARP 19TWqWrbnNj+IBoMSRKDktRKfnuhPoFlG5lIyic5BTKj1KhD8Jl5Vf9TOqd+yhW2 SI+OYZi7ohbh5qFqVvWzYOS9W9Il6Gufl1/FUpwfTCjSFEItTK4xhiEkrR9c4HeK ihx5wGcXODm+ByW1bbgrf0tBpIdzCMHOtB4K9qvqkg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrudegtddgudefhecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpeffhffvvefukfhfgggtuggjsehmtderredttdejnecuhfhrohhmpeflrghn nhgvucfirhhunhgruhcuoehjsehjrghnnhgruhdrnhgvtheqnecuggftrfgrthhtvghrnh epgfekveetieelgeefkefhueelueegvddtuefhudeuffeigeeutdfgiefffefhkeegnecu ffhomhgrihhnpeguvghngidruggvnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrg hmpehmrghilhhfrhhomhepjhgrnhhnvgesjhgrnhhnrghurdhnvght X-ME-Proxy: Feedback-ID: i47b949f6:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 5 Apr 2024 15:05:35 -0400 (EDT) Date: Fri, 5 Apr 2024 21:05:33 +0200 From: Janne Grunau To: Marek Vasut Cc: Bin Meng , Tom Rini , Simon Glass , Joe Hershberger , u-boot@lists.denx.de, asahi@lists.linux.dev, Neal Gompa Subject: Re: [PATCH v4 0/6] USB keyboard improvements for asahi / desktop systems Message-ID: References: <20240404-asahi-keyboards-v4-0-2266033feaff@jannau.net> <356b892a-a681-4ae0-a6c8-ed1b4b5a8717@denx.de> Precedence: bulk X-Mailing-List: asahi@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="qEwtrBI5m2hdEo53" Content-Disposition: inline In-Reply-To: <356b892a-a681-4ae0-a6c8-ed1b4b5a8717@denx.de> --qEwtrBI5m2hdEo53 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline On Fri, Apr 05, 2024 at 04:52:32PM +0200, Marek Vasut wrote: > On 4/4/24 8:25 AM, Janne Grunau via B4 Relay wrote: > > Apple USB Keyboards from 2021 need quirks to be useable. The boot HID > > keyboard protocol is unfortunately not described in the first interface > > descriptor but the second. This needs several changes. The USB keyboard > > driver has to look at all (2) interface descriptors during probing. > > Since I didn't want to rebuild the USB driver probe code the Apple > > keyboards are bound to the keyboard driver via USB vendor and product > > IDs. > > To make the keyboards useable on Apple silicon devices the xhci driver > > needs to initializes rings for the endpoints of the first two interface > > descriptors. If this is causes concerns regarding regressions or memory > > use the USB_MAX_ACTIVE_INTERFACES define could be turned into a CONFIG > > option. > > Even after this changes the keyboards still do not probe successfully > > since they apparently do not behave HID standard compliant. They only > > generate reports on key events. This leads the final check whether the > > keyboard is operational to fail unless the user presses keys during the > > probe. Skip this check for known keyboards. > > Keychron seems to emulate Apple keyboards (some models even "re-use" > > Apple's USB vendor ID) so apply this quirk as well. > > > > Some devices like Yubikeys emulate a keyboard. since u-boot only binds a > > single keyboard block this kind of devices from the USB keyboard driver. > > > > Signed-off-by: Janne Grunau > > I picked the series, but CI indicates build errors, can you have a look ? > > https://source.denx.de/u-boot/custodians/u-boot-usb/-/pipelines/20215 The issue seems to be that the field dev in struct usb_device exists only for DM_USB. That means we can't use dev_dbg. Either take the following fixup patch or I can resend the series. Thanks Janne --qEwtrBI5m2hdEo53 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline; filename="0001-fixup-usb-Add-environment-based-device-ignorelist.patch" >From 57d54303eb2b60e92bd478e4250a9cc63cfc277e Mon Sep 17 00:00:00 2001 From: Janne Grunau Date: Fri, 5 Apr 2024 21:00:44 +0200 Subject: [PATCH 1/1] fixup! usb: Add environment based device ignorelist --- common/usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/usb.c b/common/usb.c index 44db07742e..8bc85c58b2 100644 --- a/common/usb.c +++ b/common/usb.c @@ -1146,7 +1146,7 @@ int usb_select_config(struct usb_device *dev) err = usb_device_is_ignored(dev->descriptor.idVendor, dev->descriptor.idProduct); if (err == -ENODEV) { - dev_dbg(dev->dev, "Ignoring USB device 0x%x:0x%x\n", + debug("Ignoring USB device 0x%x:0x%x\n", dev->descriptor.idVendor, dev->descriptor.idProduct); return err; } else if (err == -EINVAL) { -- 2.44.0 --qEwtrBI5m2hdEo53--