Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp5735009rdb; Wed, 13 Dec 2023 19:10:00 -0800 (PST) X-Google-Smtp-Source: AGHT+IGLKeiqP5Zz4WnHH39Dk4+3V+5ttF1/vlBP12LytBvNYxrQ7xs3asizxBAFGHDg4SmBYJwF X-Received: by 2002:a05:6808:320a:b0:3ba:3c4:264c with SMTP id cb10-20020a056808320a00b003ba03c4264cmr10554126oib.62.1702523400536; Wed, 13 Dec 2023 19:10:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702523400; cv=none; d=google.com; s=arc-20160816; b=LWO+8ZmzjsDDK2EKh8EUceI+kAWGwCna0B7KSfCX5wKqT0bRD8Jnq/kncmc6fs75O1 Js72fY12TrXTfJuR8x1aaFFblKDYSJPuBsN1Ec7lfoLKvfOGI23u+HinBmVB5bKf/ll1 4HeBd9l3qWddRb4/Hll+Kx71fdLIz5Cz2P2evNUSPE6wEchXQW89YIM8OtZc+uNWijQh JQlHy+lYxAzwwvrIw5v/WiersPPFXYXj+IbKL8wDSj9X/eZqTVlxxfUFSUnvywDuz0t+ h7F1Y1fWxgLG1UtCjhLQSSNnAWHC+W5WXAyq3/PL9WFpSZvUKReBoGQw7yqdrv8IATyA NGXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=vm8VoKSjujA4QK9mehc82gkD5zMwK/6TtCYfWa8Dlhs=; fh=ypU+pLf8yz6N1snYAdjb4sFM3+a8q+pqhvncxPt9djY=; b=IMqlZwHgSorma9pINVtf+d9dzi3XST2zkYwLNaLEY04FWAxKq2MysOQ1AyIlBaTb+C matM/6Imw6vlRTxtaq3X/esm5zrOzTCuAW9cyoxrZzPdSrIyERb4KiG41qMV7Qo8hxZ3 5BhLbxihvvm0cSrQL2/vwlFRocNITuZ4P9/1xsFh/3wl+8HHdlRqje/EcyHgaYbKFOGH i6loXl7MEs7ngUJpaXX/9bo/YbmXZbKthedLUXslnMueXDKeyo3zR0jBLn8PT1ybY3lI +WPNhQLYxbOltalgC8eKItCx5SaOqoH7CYFdovtFEEAizwKA7ci3Tviwj75w3/8mKr5g 79/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=nC+RhMcT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id q24-20020a17090a2e1800b0028abd1b8731si3819464pjd.145.2023.12.13.19.10.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Dec 2023 19:10:00 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=nC+RhMcT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 3F1A68024583; Wed, 13 Dec 2023 19:09:58 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1443066AbjLNDJj (ORCPT + 99 others); Wed, 13 Dec 2023 22:09:39 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40810 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230117AbjLNDJi (ORCPT ); Wed, 13 Dec 2023 22:09:38 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0C29DB0 for ; Wed, 13 Dec 2023 19:09:45 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 19CCFC433C8; Thu, 14 Dec 2023 03:09:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1702523384; bh=xzN8VBpaQ+C7FVjwAk3uk6XkuZkz8OK0t7++aNp/cIM=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=nC+RhMcTfI/6+5mFEnRMg0ZdIKa7dY0hlVas3wsZuOWL4dp4qkeELxPuR3z0z+M0w XnLvoKtUCNSQbw8YLXWwmvhJLa7eb5rHfU+VXUd9Q+kVtosQ3yhZDlmAdwV2T5nMVV 6j0J2beZpq1bzBCSABWofyFdhI0wcbt/45kPk1Mdovuxj95c5YMMl/TswoWh/Pj89J 42aJkUJBMovQJzuZYkaWMG4/BtPiTozdNRA+n2YOyF2irlRvEehsr4gKR4zatKEYrQ 7DK91asMXsHWtdZSyOE6TwJZX53lZ1kPlpx3N5mcmtQvyd6N8QzPBuylQoPrVBPKgs Fnf129/eaGwwg== Date: Thu, 14 Dec 2023 11:09:41 +0800 From: Tzung-Bi Shih To: Mark Hasemeyer Cc: LKML , Raul Rangel , Benson Leung , Bhanu Prakash Maiya , Chen-Yu Tsai , Guenter Roeck , Prashant Malani , Rob Barnes , chrome-platform@lists.linux.dev Subject: Re: [PATCH v1 6/6] platform/chrome: cros_ec: Use PM subsystem to manage wakeirq Message-ID: References: <20231213110009.v1.1.Ifd0903f1c351e84376d71dbdadbd43931197f5ea@changeid> <20231213110009.v1.6.Ieee574a0e94fbaae01fd6883ffe2ceeb98d7df28@changeid> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231213110009.v1.6.Ieee574a0e94fbaae01fd6883ffe2ceeb98d7df28@changeid> X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Wed, 13 Dec 2023 19:09:58 -0800 (PST) On Wed, Dec 13, 2023 at 11:00:24AM -0700, Mark Hasemeyer wrote: > The cros ec driver is manually managing the wake irq by calling > enable_irq_wake/disable_irq_wake during suspend/resume. > > Modify the driver to use the power management subsystem to manage the > wakeirq. > > The wake capability of the interrupt is provided by the underlying > firmware/device tree. Some Chromebooks rely solely on the ec_sync pin to > wake the AP but they do not specify the interrupt as wake capable in the > ACPI _CRS or device tree. For LPC/ACPI based systems a DMI quirk is > introduced listing boards whose firmware should not be trusted to > provide correct wake capable values. > > The irq wake logic was added on an interface basis (lpc, spi, uart) as > opposed to adding it to cros_ec.c because the i2c subsystem already does > this work on our behalf. It looks to me the patch combines multiple changes. Please separate them into smaller pieces for reviewing easier. Another confusing about the patch subject: "6/6"? Is it a series? I don't see the cover letter.