From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 039BDC433EF for ; Wed, 29 Jun 2022 17:35:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231243AbiF2RfQ (ORCPT ); Wed, 29 Jun 2022 13:35:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44132 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229617AbiF2RfO (ORCPT ); Wed, 29 Jun 2022 13:35:14 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C10A3286EF; Wed, 29 Jun 2022 10:35:12 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 5BF4B61E63; Wed, 29 Jun 2022 17:35:12 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id F3B1BC34114; Wed, 29 Jun 2022 17:35:08 +0000 (UTC) Authentication-Results: smtp.kernel.org; dkim=pass (1024-bit key) header.d=zx2c4.com header.i=@zx2c4.com header.b="AucPVFO5" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zx2c4.com; s=20210105; t=1656524107; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=YuSrb83T/sew09oEwC4jqlwmFmsN3/eWbuM4rfaIxQ8=; b=AucPVFO5o+D4xprp0cAdeMfdNNJ1IjiF4Z5ekpcwdbgxZHUbVXYx1VdkDXXP8xhdN00dQY p5Jk5fgzTPbwdXuMmla6Aiz90j+J9qkxtwHezru0nrhRBlygn2Nu0us7NC5/Vdmerd3vKF J13IU9BNrAfLdi4ASZ/bwCwZD5mTEOg= Received: by mail.zx2c4.com (ZX2C4 Mail Server) with ESMTPSA id f38fdb15 (TLSv1.3:AEAD-AES256-GCM-SHA384:256:NO); Wed, 29 Jun 2022 17:35:06 +0000 (UTC) Date: Wed, 29 Jun 2022 19:34:58 +0200 From: "Jason A. Donenfeld" To: Christoph Hellwig Cc: Greg Kroah-Hartman , Arve =?utf-8?B?SGrDuG5uZXbDpWc=?= , Todd Kjos , Martijn Coenen , Joel Fernandes , Christian Brauner , Hridya Valsaraju , Suren Baghdasaryan , Theodore Ts'o , "David S. Miller" , Eric Dumazet , Jakub Kicinski , "Alex Xu (Hello71)" , Paolo Abeni , Rob Herring , "Paul E. McKenney" , Frederic Weisbecker , Neeraj Upadhyay , Josh Triplett , Steven Rostedt , Mathieu Desnoyers , Lai Jiangshan , Shuah Khan , linux-kernel@vger.kernel.org, wireguard@lists.zx2c4.com, netdev@vger.kernel.org, rcu@vger.kernel.org, linux-kselftest@vger.kernel.org, sultan@kerneltoast.com Subject: Re: [PATCH] remove CONFIG_ANDROID Message-ID: References: <20220629150102.1582425-1-hch@lst.de> <20220629150102.1582425-2-hch@lst.de> <20220629161020.GA24891@lst.de> <20220629161527.GA24978@lst.de> <20220629163007.GA25279@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 29, 2022 at 06:38:09PM +0200, Jason A. Donenfeld wrote: > On the technical topic, an Android developer friend following this > thread just pointed out to me that Android doesn't use PM_AUTOSLEEP and > just has userspace causing suspend frequently. So by his rough > estimation your patch actually *will* break Android devices. Zoinks. > Maybe he's right, maybe he's not -- I don't know -- but you should > probably look into this if you want this patch to land without breakage. More details: https://cs.android.com/android/platform/superproject/+/master:system/core/libsuspend/autosuspend_wakeup_count.cpp;bpv=1;bpt=1;l=52?q=%22%2Fsys%2Fpower%2Fstate%22&start=51&gsn=sys_power_state&gs=kythe%3A%2F%2Fandroid.googlesource.com%2Fplatform%2Fsuperproject%3Flang%3Dc%252B%252B%3Fpath%3Dsystem%2Fcore%2Flibsuspend%2Fautosuspend_wakeup_count.cpp%23ftWlDJuOhS_2fn3Ri7rClxA30blj_idGgT12aoUHd1o So indeed it looks like it's userspace controlled. If you want this to be a runtime, rather than a compiletime, switch, maybe autosuspend_init() of that file could write to a sysctl. Who at Google "owns" that code? Can somebody CC them in? Jason