Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1259626rwd; Thu, 18 May 2023 09:50:08 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5vn7AWSkjTlh65r+CCvqeqVDeQz14u+w1dFsknhePyrTewdEoxYYuTgjq1Uka5DJW/O5c+ X-Received: by 2002:a17:902:b610:b0:1ae:100a:4fed with SMTP id b16-20020a170902b61000b001ae100a4fedmr2920155pls.26.1684428608689; Thu, 18 May 2023 09:50:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684428608; cv=none; d=google.com; s=arc-20160816; b=bXLIaZy2eJLCH3jYgHhFHBVLqs/flBxPIIlVf+GcBq9tgjVhYtBihVeYwzINXxj5/j daOBlTsMnPVE7IGJDHLRlVRXPFUxiIpuZWeTZ6k+7n9SGKzyYSWWqkzLWkUXvN2KMNXO GZGZgdBN4tBelPQW/IfSV6i9wRyg8KDp45yqUQxBEZ59WBAAp1OM5fgs85If77v5/zYd HAyKTZfIqzQTl9tIcMz5qyj+ZaYPKlgqatLh+Ibf7NucXhR7kLTwPKO7wPy1pjqajYDh 4k9qt9hyGBLW/0OjWcJXksTrFK3O7ZThSAxBz6zoXU0oEuUZoDitCKYoiIh7gMLR8/gS e+qQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=EO246ZqiVBRxZDxMtJpAios9D2U+bi/JcOcYKYzfYJ8=; b=MBnivtniYohVGjGbR/KxAMp1NWl/IiewL8IItJ6Qa4zx+v7SOIxdkoovI6K/AA19a8 QvBnepY4jyR/z0Ubl5tauUXKaalgtxdSDLnp5FJBg/yJrUChkJGoHDd/Gi8+uOwBa6C7 tIpIew2OuWFkFWF6pNgZOuQuuJaAtBUGxr9f0iNq18FNUwUksZEPvuZ5mKlKQ0mhs0cw OFJXFZmUFNR7dJufDJUfKRbDnw/vBbf26fbxoKr9Y5T1238C5ge7GokJss9XQMEw6Bcc 64cdLE9Yq5mwL2ZSGatNwY3/4fBks/ThQP1CU1C6hhcAm8ZRV7II0MHta734IehjTRKp oUFA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=C0SkUL7L; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g7-20020a1709029f8700b001ac36e5ec0esi1628129plq.299.2023.05.18.09.49.55; Thu, 18 May 2023 09:50:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=C0SkUL7L; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229682AbjERQrm (ORCPT + 99 others); Thu, 18 May 2023 12:47:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38400 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229445AbjERQrj (ORCPT ); Thu, 18 May 2023 12:47:39 -0400 Received: from mail-qt1-x833.google.com (mail-qt1-x833.google.com [IPv6:2607:f8b0:4864:20::833]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 270C0E6A for ; Thu, 18 May 2023 09:47:35 -0700 (PDT) Received: by mail-qt1-x833.google.com with SMTP id d75a77b69052e-3f39600f9b8so11489721cf.3 for ; Thu, 18 May 2023 09:47:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1684428454; x=1687020454; 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=EO246ZqiVBRxZDxMtJpAios9D2U+bi/JcOcYKYzfYJ8=; b=C0SkUL7LTPqYi++TtcB64tB2yY2rMEzGkd4D9JFvGhePfWVTDkxBuKx/m+Hi4c+sDI hthy6WeL3lc3ehF7bnAH2sXSAyXRLjoRbfpr0fYpkylrx6wNHoDwqSJVFZPj9RkEKkbh 2/FmwnPZrd/lh5lbL8RpbmOjKrPaqlsOOUbPw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684428454; x=1687020454; 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=EO246ZqiVBRxZDxMtJpAios9D2U+bi/JcOcYKYzfYJ8=; b=eT+MaQW38WQ6+AYvj0Qf7gW9DMRBGO0ws4NhYM9WYM5fD9u52d8QI3NZ4KakYtmZkv B8fxTwwRkZBz/aiyV3uGdHfs+aBkoSgiq16UDbV1zkACrdFy4IxEVgio5WvSXxAhplU0 YApEKtebugjI+EEN5vpWjimYDgcafzQ0oDYkJEH84oUESe3bRkBynQIttM2yDnBnCVCj IwT+nyppD1e0f09Tru5W/vGIf5/R/bDI7afVBoH38qyE3VKv8ncVP1llv+bRh5/Q8nlv I3pwihbkjFFBRV9FULhN052V8pjVJCnbL9UDvaf+OQvOnkTUY1zTvGxODMz8avHZxBuP h7hw== X-Gm-Message-State: AC+VfDzGIwJlL2qyfzJnThVOOO4IrpH5StNAdOHyVVEvGb30gWoUluo4 iwHy07Y6IOIQu+H1XGVa01LkRPV14VqX5XplxmLg2w== X-Received: by 2002:a05:622a:189e:b0:3e6:2e9e:58f1 with SMTP id v30-20020a05622a189e00b003e62e9e58f1mr434517qtc.59.1684428454207; Thu, 18 May 2023 09:47:34 -0700 (PDT) MIME-Version: 1.0 References: <20230515142552.1.I17cae37888be3a8683911991602f18e482e7a621@changeid> In-Reply-To: From: Tim Van Patten Date: Thu, 18 May 2023 10:47:23 -0600 Message-ID: Subject: Re: [PATCH] [v9] platform/chrome: cros_ec_lpc: Move host command to prepare/complete To: Tzung-Bi Shih Cc: LKML , robbarnes@google.com, lalithkraj@google.com, rrangel@chromium.org, Benson Leung , Guenter Roeck , chrome-platform@lists.linux.dev, Garrick Evans Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 17, 2023 at 7:38=E2=80=AFPM Tzung-Bi Shih = wrote: > > On Wed, May 17, 2023 at 09:56:59AM -0600, Tim Van Patten wrote: > > > I can understand the patch wants to notify EC earlier/later when the = system > > suspend/resume. But what is the issue addressed? What happens if the > > measurement of suspend/resume duration is not that accurate? > > > > Please see the following: > > - b/206860487 > > - https://docs.google.com/document/d/1AgaZmG70bAKhZb-ZMbZT-TyY49zPoKuDD= bD61dDBSTQ/edit?disco=3DAAAAws1enlw&usp_dm=3Dfalse > > I have no permission to access the doc. Since you work at Google, please request permission to access it, so the owners can grant it. > Please put the context in the commit > message. Done in the next patchset. > It's usually helpful if you could put the corresponding EC FW > changes. Why are you assuming there is EC FW with this change? Any and all of the EC changes related to this have (obviously) landed long ago. > > The issue is that we need the EC aware of the AP being in the process > > of suspend/resume from start to finish, so we can accurately > > determine: > > - How long the process took to better gauge we're meeting ChromeOS requ= irements. > > - When the AP failed to complete the process, so we can collect data > > and perform error recovery. > > Is it a new feature? No, it's not. > How could the *error* recovery do? I don't understand what this is asking. > > > What about other interfaces (i2c, spi, uart)? Do they also need to c= hange > > the callbacks? > > > > We aren't concerned about those devices, because they aren't being > > used on the devices we're seeing issues with. If devices using those > > ECs want this change, they can pick it up as well, but we don't have > > any way to test changes on those devices (whatever they may be). > > This doesn't sound good. As I would suppose you are adding some new EC F= W > features regarding to EC_CMD_HOST_SLEEP_EVENT, you should consider the > existing systems too. Again, why are you assuming there is new EC FW for this? This is only changing when an already-existing host command is being sent. Nothing is being added or removed. > What happens if a system uses older kernel (without this patch) to > communicate with new EC FW via LPC? The message is being sent regardless of whether this patch lands or not. This patch just changes when they are sent, so there is no risk from that perspective. > How about adding a new EC host command for your purpose so that it won't > affect the existing systems? I knew this was discussed in some older ser= ies > but I didn't follow the thread. > No. The necessary host command already exists and is being sent. There is no additional command being sent with this change. It is only changing when the command is being sent.