Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1570931rbb; Mon, 26 Feb 2024 13:54:59 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXvO3plyAK24/GRUpnmaQnlkgSFmnONYgGRAI2WsaOMHgFdoTfPdhNofhqpmAP00is8Gn/eaOEfQlric9HHNVQ3dgImd77YmspynrTwoQ== X-Google-Smtp-Source: AGHT+IGuXjO8h203Del7D88/eR07TEFuA72y9wQgLuNS2UFbuUDeqacuTq8RIKZNzTwvUtYrtuna X-Received: by 2002:a17:902:d4c9:b0:1dc:84a1:b0e5 with SMTP id o9-20020a170902d4c900b001dc84a1b0e5mr8890063plg.59.1708984498910; Mon, 26 Feb 2024 13:54:58 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708984498; cv=pass; d=google.com; s=arc-20160816; b=Omu3VsSMuIXWnhVvKCgeHVLTiU2uUa2rrc7ZG5CzuZD0rT5w5OHV+V+/9ksSmSpsQR L6t8wDx1Qshol5nYyE08xewQ9YP1NGT+7+lIFQ/laL+YLQ03326nf4Wunn4IYuK5bD0M 3e1S50ylDKIKFXRpgisOs/VZ7sv5ee6+W5RUeauMOvagfQi1ysLrBLUjvnPV7BTdSbM4 cN7Exk6E2GkbiE75gP9CypQMFZpuKmJU8HKnvEO5omcO7RoH6TWn8p2si0kqSy5OXDDM dg8qVdeEiotdpXfGtS1nwthcQ5skOHZAu/7+d+zo+2L/RAsOxPTw+3arEn1U61N9YNQ0 pT3g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=LvqziGEBSPprOdiqXW0BtoohOCzdBYizN85hWV54RjA=; fh=4IGhvTHHnZghHrDBwc+RljKh7DHYalKegUCJ0hBQDDg=; b=xprb+zGcjiU9pm7U3zHvR7uUcW0AdvmiDlV9fjt54Zqk4BHjBo4Qh0xfHFHiCEuwW2 E02DBVYqA2HGLARJ+gVlLGs0To4+/aFUEwqyboEKzINXxvZtmPGT27npGhabIv5Zojqs //MTjv7aSEHNCVhPPOmVXdB2XrdSlQIx3CL864du2pryRtNsljOE0Pwu5pkAYgKz/J4k pyFPA8Ai9boJQAoBYc5I2nTwUUAee4FMuQTboQh3/z8RxzhxTzGevzAYzuyJmHbZeCS3 5m8sZ8HW9W0eyoeoGv07KWH90NdEnpEpfUBmXi9ovxVakNFo928c2kIrfk5DhLyhTOO+ HnPA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kali.org header.s=google header.b=lJMdXiM3; arc=pass (i=1 spf=pass spfdomain=kali.org dkim=pass dkdomain=kali.org dmarc=pass fromdomain=kali.org); spf=pass (google.com: domain of linux-kernel+bounces-82370-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-82370-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kali.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id lk4-20020a17090308c400b001d720af9a66si234443plb.366.2024.02.26.13.54.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Feb 2024 13:54:58 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-82370-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kali.org header.s=google header.b=lJMdXiM3; arc=pass (i=1 spf=pass spfdomain=kali.org dkim=pass dkdomain=kali.org dmarc=pass fromdomain=kali.org); spf=pass (google.com: domain of linux-kernel+bounces-82370-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-82370-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kali.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 42FC9B215EA for ; Mon, 26 Feb 2024 21:49:26 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E2354131E23; Mon, 26 Feb 2024 21:49:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kali.org header.i=@kali.org header.b="lJMdXiM3" Received: from mail-ed1-f44.google.com (mail-ed1-f44.google.com [209.85.208.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 032AD12F388 for ; Mon, 26 Feb 2024 21:49:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.44 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708984158; cv=none; b=pne6S8QHUtLSJlUvZxtOOQgPRoHYvo0Q9n0TfN5Qo5O9z3CW6MsuwuO4Nk2OsnJyjAZ0R+BFx0ADIkKvDaAfCvayI1AAyjmLvk64jtKYHXktcACar1VYwP6U+/dJ1bvtO9sUfEvGjuiW2N/ohlZVZoXa+/XohnQpfffKWzk4cag= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708984158; c=relaxed/simple; bh=LvqziGEBSPprOdiqXW0BtoohOCzdBYizN85hWV54RjA=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=kkdF29eON/p0VDEhYiWSb6lrcEyAPr0ia4KHl1iz7/1mgLVP033pJmVVmYUxZ4DOgQacIjdGpof2kEUhQw5UB3SS61bgK3El1PIxiAgsszrn7+JJtzePlKKEmG7aFWEZBrdLIzrbWiABSw+NBI9Xipv0XNFnZjs84eiV1SY6nhQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=kali.org; spf=pass smtp.mailfrom=kali.org; dkim=pass (2048-bit key) header.d=kali.org header.i=@kali.org header.b=lJMdXiM3; arc=none smtp.client-ip=209.85.208.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=kali.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=kali.org Received: by mail-ed1-f44.google.com with SMTP id 4fb4d7f45d1cf-5649c25369aso4514880a12.2 for ; Mon, 26 Feb 2024 13:49:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kali.org; s=google; t=1708984155; x=1709588955; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=LvqziGEBSPprOdiqXW0BtoohOCzdBYizN85hWV54RjA=; b=lJMdXiM3pFIGXxyJXO09hsjYaQT3Tk8Zeib5LagsRPE1WK48i3G8cAikb07WU/R33n uGZFdZQs/z9k+hkFqymGs9m+KqgAThKmV3wHx/NSZCjJq8BbywsZJkvu7HOAWprVWuoc 6npRdOPKvZYP44gUTPdwjYn69uKBCKbDL1SspX50YCE5Gf5AYGjnORlN3r+4Gnb5/zwA quaL4O7i0p7h7xAOUzCjSw3j0yi1KDS3lHCtiYVam/RPwHln7R/vGcG4LzmjpJoc/0ms 9GCyI4awjaEDyW7x6SrqLGRLkQVVD+u/R+RJwa9pfrMmNoZRcdpsfmfEkub+oxrhuEZb FBSg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708984155; x=1709588955; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LvqziGEBSPprOdiqXW0BtoohOCzdBYizN85hWV54RjA=; b=CO9Pc2uyUEoTzuLS8D+GcVRs+tNuTnU63DwqNGxKw0ghTRsdnTpheM85e5NyIje4tY 3fheDcExsgj2t0jHCoBUW9+m3y9wWkBo3oCXDxhr83kVCWMs1bWFvy/ojOATz9c0kJP/ zgkAXSYhvP95vplAS1H4OIIELYWOz70g7EJoXqJ19e9r9qzW8OMNF0BG8F2cq69Wj6Td 38KMqZPNiU2RPbMMzD2WynwtMf6V3/b22CjjDLHCok2TIvDADnDvmz8wVBCHDyYqu0wq boxQZSnr8WE54A3qWoPIvFz9YMyfYeP6xvHLOt2siSDsbBWuf6A9pzneGQb7o76d2pK/ 2aOQ== X-Forwarded-Encrypted: i=1; AJvYcCX1upHtbV0Ts1VJLLGCIVSsKpNgLxr3Vknz4x0rUsfuGN9TvuqCsaAmJV7SQ8YjKE1dfnAZwvUTnGjrQOAH9wd64gj3pK0vjIVLiIQh X-Gm-Message-State: AOJu0YzmGUj98Odr2gDmTihS5/q4CLBa6lMHOdGqIbKon6EVWC1KhTR5 ePO3pUFf+A/cekRopONnQA2KcmVnyh76F8IsTQRTyTxkQUMQdQFIT+ZFF53aJrZD3jf07jOlflD vPGqYb8Ki5pejYoowkqoD8UPX5+Xghv6CIHLwvg== X-Received: by 2002:aa7:c609:0:b0:565:9e16:60da with SMTP id h9-20020aa7c609000000b005659e1660damr4977584edq.30.1708984154965; Mon, 26 Feb 2024 13:49:14 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240202141109.1.I24277520ac754ea538c9b14578edc94e1df11b48@changeid> <87sf1u58k0.fsf@intel.com> <87frxskef7.fsf@minerva.mail-host-address-is-not-set> In-Reply-To: From: Steev Klimaszewski Date: Mon, 26 Feb 2024 15:49:03 -0600 Message-ID: Subject: Re: [PATCH] drm/dp: Don't attempt AUX transfers when eDP panels are not powered To: Doug Anderson Cc: Javier Martinez Canillas , neil.armstrong@linaro.org, Jani Nikula , Maxime Ripard , Thomas Zimmermann , Maarten Lankhorst , Hsin-Yi Wang , dri-devel@lists.freedesktop.org, eizan@chromium.org, Ankit Nautiyal , Daniel Vetter , David Airlie , Heiner Kallweit , Imre Deak , Jessica Zhang , Sam Ravnborg , Stanislav Lisovskiy , linux-kernel@vger.kernel.org, Bjorn Andersson , Konrad Dybcio , Johan Hovold Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, Feb 16, 2024 at 9:30=E2=80=AFAM Doug Anderson wrote: > > Hi, > > On Fri, Feb 16, 2024 at 12:21=E2=80=AFAM Javier Martinez Canillas > wrote: > > > > > The kernel tree we landed on was the v5.15 tree, which is currently > > > serving all Qualcomm sc7180-based Chromebooks, all Mediatek 8173 > > > Chromebooks and all Mediatek 8186 Chromebooks. There are also a pile > > > of x86 Chromebooks running our v5.15 kernel. This code shouldn't > > > affect them because (unless I'm mistaken) they don't use the two > > > affected panel drivers. In any case, I haven't heard any screams from > > > them either. Given my landing plans of "the week of the 26th", this > > > still gives another 1.5 weeks for any screams to reach my ears. > > > > > > ...or are you looking for non-ChromeOS test reports? I'm not sure how > > > to encourage those. I suppose sometimes folks at Red Hat end up > > > stumbling over similar panel problems to those of us in ChromeOS. > > > Maybe +Javier would be interested in providing a Tested-by? > > > > > > > I do have a SC7180 based HP X2 Chromebook and could test your patch (no= t > > today but I could do it early next week), although I haven't followed s= o > > if you could please let me know what exactly do you want me to verify. > > > > AFAIU the problem is that the fwupd daemon tries to scan DP busses even= if > > the panel is turned off and that's what takes a lot of time (due retrie= s), > > and your patch makes the driver to bail out immediately ? If that's the > > case, I guess that just starting fwupd daemon with an without your patc= h > > while the panel is turned off could be a good test ? > > Sorry! I wasn't trying to sign you up for extra work. I'm not > convinced that any extra verification on a Chromebook is all that > valuable since that's pretty covered by the fact that we've already > pushed this patch out to real users on Chromebooks. I think Neil was > hoping for some confirmation that my patch didn't break someone else's > hardware. I think maybe good enough is if you have some type of > hardware that uses eDP and that you could verify that my patch does > break anything about it? > > I'm not aware of anyone with extensive DP AUX character device usage. > I guess I thought of Javier because I remembered him at least also > using fwupd and some of the fwupd plugins try to talk to DP things > over the DP AUX character device. > > If someone is really in a testing mood and wanted to stress the char > device, I guess something simple like "hexdump -C /dev/drm_dp_aux*" > for whatever eDP AUX is associated with eDP would at least do some > reading. You could stress turning the display on and off while doing > that with and without my patch. Presumably it will be better (error > out more quickly) with my patch. > > If you wanted to stress the i2c path, you could do something like this > (the grep assumes you're using ti-sn65dsi86 as your eDP bridge chip, > but hopefully easy to adjust): > > bus=3D$(i2cdetect -l | grep sn65 | sed 's/i2c-\([0-9]*\).*$/\1/') > i2cdump ${bus} 0x50 i > > That should dump your EDID. Again it should error out quickly when the > panel is off after my patch but should start working again when the > panel is on. > > > Hmmm, thinking about all the above, I guess there is one case that > _could_ be broken by my patch. I really hope not, though. If someone > has a panel that's on an always-on rail or on a shared rail with some > other device (like the touchscreen) that's keeping the panel power on > then without my patch it would be possible to do DP AUX transactions > even when the panel was "off" from Linux's point of view. It would > have worked mostly due to luck, but now luck will run out and it will > stop working. I really hope nobody has userspace that is relying on > this, but I suppose it's always possible that somewhere, someone's > userspace is. If you are or know of someone who is then please shout. > > -Doug Tested on my Thinkpad X13s, with display on, I get the did when hexdumping /dev/drm_dp_aux2, with display off I get device/resource busy. Tested-by: Steev Klimaszewski