Received: by 10.223.185.116 with SMTP id b49csp1055007wrg; Fri, 16 Feb 2018 11:35:17 -0800 (PST) X-Google-Smtp-Source: AH8x226p+Wp62Hcs3aasVCiGylUe45ACEkifwGHCKuBzMYrksivVk7btRXCD9i9fD2xtGOvMZMwj X-Received: by 10.98.18.65 with SMTP id a62mr7101193pfj.115.1518809717274; Fri, 16 Feb 2018 11:35:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518809717; cv=none; d=google.com; s=arc-20160816; b=qz3BXgUlyxyGSsUp24o250vI4GgJ3QrK0fDdL7zma9jD8Sk78Gau0yCsw7oEG+65Xw BH7W+xLGpeG8nomzpP+6Zjmb37u+E98/DmW7JKY+7+ISX2llkJseQTe0RoJbXpEBWmtp roTaqAuSOxVM+78bX+b71s155sbeoZrF26ONdKZjr8dZJ0olGy7vJnxBRjHxiWtEu+He PHRHDe32fTVo59uB/01k6RKjOv/bAGyYadw44/Yh7ahLaekiMj7dmZRzwCTeDduXO7eR zxOaU4EUFg8RK1+BO48b+GL5xt2szrstA4T43TZEMHs6R/mu7ifbSElX6fLPzKNpots8 rakg== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=n94Rt4cxefnwNAs0rZq20vpEH4mufsZBE9FMc2/9fbQ=; b=uR+/YqkNMp808N7cDIOqWFL19hAo0d85NQQ9TB/PVb1fTVpS40i2sE8wMvoXbCXsDm t2Wik8tTw0efErqs3exZv7ckrmersMy635TF0laeOzL+iVJWFLq2dX+jpHu2QXvWqlml /gL6paJ54vNCRzrXgjIeN8b1QmUX615ybm0CqLyjl85yzNnKiLK2a7WvaSsvZUFfiPFz nVxTbuEH5e4VSXdZ5MmyMmoLzRztVVmS89d1sVn3BIn0aoIXRYfkXsLKRmJSUvL3bQTy HkuRFQfv2qddLmeerzcIDuv23OiBmzTBpAF4Rr4Ft2QEbApreD4cs6FO82mjAWrryWcd tCtA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a13si3046611pgt.344.2018.02.16.11.35.02; Fri, 16 Feb 2018 11:35:17 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754211AbeBPI0n (ORCPT + 99 others); Fri, 16 Feb 2018 03:26:43 -0500 Received: from mail-wm0-f66.google.com ([74.125.82.66]:39085 "EHLO mail-wm0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754190AbeBPI0k (ORCPT ); Fri, 16 Feb 2018 03:26:40 -0500 Received: by mail-wm0-f66.google.com with SMTP id b21so1607341wme.4 for ; Fri, 16 Feb 2018 00:26:40 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=n94Rt4cxefnwNAs0rZq20vpEH4mufsZBE9FMc2/9fbQ=; b=br+Jr1xPHHQoHY8qIcfxsp5vgf+ASl9lxuQxjJoWFBQgfWtJcZXgVeCO86t507OmOe 56Np//hWEx4aNTHaV4Szm+nB95fuQuz7yRwKTbkXbViYPqF3I50LHWhITQpsm1nOYNeD 95EaBRRPMBYvYZuNeRjEtHEyyPw0G/ZH5wPmEnFme68eQ7b58iyFIO3FRHQfaRN04FXd 3oAGaF2ApVZq8LEkv9MiglwFHt5mHUIBgHSO8RfWRld+r98JSD11gMRZ8kY6XETUagRG 3olHcN+CwzAchnQZ8unnKj3Nrm8i1feD16ae0nPglmiLi0JD9nMmO5g3x2hmjD6CacJd N6BQ== X-Gm-Message-State: APf1xPDEfpqLmWhuVB8AtOgCgmidQvy4iZNDAEHjhn8FoWLvasoXkM+t klnn+WeREQfrsbQ4gvLymxkAYQ== X-Received: by 10.80.195.85 with SMTP id q21mr7039914edb.254.1518769599495; Fri, 16 Feb 2018 00:26:39 -0800 (PST) Received: from shalem.localdomain (546A5441.cm-12-3b.dynamic.ziggo.nl. [84.106.84.65]) by smtp.gmail.com with ESMTPSA id a5sm13329807edm.38.2018.02.16.00.26.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Feb 2018 00:26:38 -0800 (PST) Subject: udev USB autosupend whitelist (was Re: [PATCH] Bluetooth: btusb: Restore QCA Rome suspend/resume fix with a "rewritten" version) To: Brian Norris Cc: Marcel Holtmann , Gustavo Padovan , Johan Hedberg , linux-bluetooth@vger.kernel.org, linux-serial@vger.kernel.org, linux-acpi@vger.kernel.org, stable@vger.kernel.org, Leif Liddy , Matthias Kaehlcke , Daniel Drake , Kai-Heng Feng , matadeen@qti.qualcomm.com, linux-kernel@vger.kernel.org, Greg Kroah-Hartman , Guenter Roeck References: <20180108094416.4789-1-hdegoede@redhat.com> <20180213022455.GA151190@rodete-desktop-imager.corp.google.com> <8cd918fd-bf6f-70ac-e561-e7deffa695f0@redhat.com> <20180216022721.GA69988@rodete-desktop-imager.corp.google.com> From: Hans de Goede Message-ID: <0a13d0f3-8e0d-74df-df9c-2bf0622a9fb6@redhat.com> Date: Fri, 16 Feb 2018 09:26:37 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <20180216022721.GA69988@rodete-desktop-imager.corp.google.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, Going a bit off-topic here, so changed the subject. I will reply on topic in another mail. On 16-02-18 03:27, Brian Norris wrote: > Hi Hans, > > On Tue, Feb 13, 2018 at 12:25:55PM +0100, Hans de Goede wrote: >> On 13-02-18 03:24, Brian Norris wrote: >>> On Mon, Jan 08, 2018 at 10:44:16AM +0100, Hans de Goede wrote: >>>> Commit 7d06d5895c15 ("Revert "Bluetooth: btusb: fix QCA...suspend/resume"") >>>> removed the setting of the BTUSB_RESET_RESUME quirk for QCA Rome devices, >>>> instead favoring adding USB_QUIRK_RESET_RESUME quirks in usb/core/quirks.c. >>>> >>>> This was done because the DIY BTUSB_RESET_RESUME reset-resume handling >>>> has several issues (see the original commit message). An added advantage >>>> of moving over to the USB-core reset-resume handling is that it also >>>> disables autosuspend for these devices, which is similarly broken on these. >>> >>> Wait, is autosuspend actually broken for all QCA Rome chipsets? I don't >>> think so -- I'm using one now. >> >> And have you manually enabled USB autosuspend for it, or are you >> running something which might have done so, e.g. powertop --auto-tune ? >> >> Because if you did not do that then you're already not using autosuspend >> for your QCA devices and this patch will change nothing. > > I use a set of udev rules that manually whitelist devices for > autosuspend. You can see it here: > > https://chromium.googlesource.com/chromiumos/platform2/+/43728a93f6de137006c6b92fbb2a7cc4f353c9bf/power_manager/udev/gen_autosuspend_rules.py#83 > > You'll find at least one Rome chip in there. Oh, that is a very interesting link for the work I've been doing to improve Linux power-consumption in general: https://fedoraproject.org/wiki/Changes/ImprovedLaptopBatteryLife I was actually planning on at least doing such a list for WWAN modems, for btusb my approach has been to just enable it everywhere (except for QCA devices as I got bugreports for those). Note that I plan to eventually submit this whitelist to the udev rules which are part of systemd upstream, so if chromeos is using systemd too, this is something to be aware of for you. Question, is the white-listing of the root and rate-limiting hubs really necessary? I thought these have this enabled by default? Also any caveats here I should be aware of? Regards, Hans