Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp3600574imm; Mon, 4 Jun 2018 06:25:38 -0700 (PDT) X-Google-Smtp-Source: ADUXVKJ2Kvh2R/NPH+8dK84GtCdHDD8QPPRoB2j2RZKlFqfJvLyKabo5CjfbD/WaKqG9DLz4RuZY X-Received: by 2002:a17:902:b48f:: with SMTP id y15-v6mr11164266plr.261.1528118738861; Mon, 04 Jun 2018 06:25:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528118738; cv=none; d=google.com; s=arc-20160816; b=ToFuzZjiukPqS2DA9/FfDVfzyTlyKQOKggHoTYxXJGF9IeK2RlkGKgtQh66XcI3T8c 4Dro+QiCt6GlpNt6rUSrlRCUh+LE59qg/0SEY+IlrjVIcmtDkqiKsuQxIQWfIqh/40rR q0KKEkTR/uBObRiC7FNjoGIhhBbHkwYNT7+erTk8Yr6ZEJUWIoOB5WX5OHmiHiEKJs3a AmPcnKPwRImPtqbTLk4VwRFj8NeJZZz+9l+FTFFLkWIwOa+6qFy1fTEOdpFJ7GNg2fec ficB15KkAQh1imp0oxp8eGH/UMYNjqw8zFl6w0BxB0PgbcFUUccIP3Wl5RClgNSsA2ld PQVA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:reply-to:mime-version:dkim-signature :arc-authentication-results; bh=P8hwdrM8dUg1TCp+3S7MYDTFbfUwVFd+nN6/DlnJwxc=; b=YfI+bdLPQMUIsxL/yQpl27atgGmSkmgducMf2LHxAk+z8Hd0chjWDFjBpiF1WhB6VH 4XdG+G247ilGacVVvQeovUjsEMBWSOZ4TS+JJNxWlPFvmo5/87od/1FZguxQdvNhggHV zPX/TJVxaLINKMAwHQh/JqQVAA4Vk411OiknsyHmoduo7zq0PjjcE3T5W3EeCuL/aaGu DzTparPGjMzkWSxD7K9lY0Rbrzgmc793LnJAEWlOXCxWmt2R38RNzfgzbEpGo/OFlbyY UihjPa4mMjz4ZJ6uAiSl9I2w4lZGNeXYUf7arcDcwjgEXbsoHxqZsCjFYE12b0AXZ6ET yliQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=SpCLektm; 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=samsung.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z19-v6si3684956pff.100.2018.06.04.06.25.23; Mon, 04 Jun 2018 06:25:38 -0700 (PDT) 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; dkim=fail header.i=@gmail.com header.s=20161025 header.b=SpCLektm; 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=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753140AbeFDNYt (ORCPT + 99 others); Mon, 4 Jun 2018 09:24:49 -0400 Received: from mail-wr0-f195.google.com ([209.85.128.195]:34195 "EHLO mail-wr0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752429AbeFDNYr (ORCPT ); Mon, 4 Jun 2018 09:24:47 -0400 Received: by mail-wr0-f195.google.com with SMTP id a12-v6so8470015wro.1; Mon, 04 Jun 2018 06:24:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:reply-to:sender:in-reply-to:references:from:date :message-id:subject:to:cc; bh=P8hwdrM8dUg1TCp+3S7MYDTFbfUwVFd+nN6/DlnJwxc=; b=SpCLektm14ZW24IkFn6rKYaWJltwWxtbpInEJUoPa25mkIdFPJN9ZsZwy9sytZBF5Z /HpnxEFq+K1aXMQfQAoU1ySMBiQyEu5aT0VfntZVg/tNyHLaEYVxQu2rt9fGhCU9FqQV 9jaYkJWgn6AW+X4Y4AI28vZMQwst4zKZDk4AExRptwvzXf/tvRQDgtBj+Y3X4qDZ/Z1p f3ynrytkLWE9q9XvQjuCg9vV/o8xCDddwWFb8sOlxZn+AieWdbfPAoAKSjtCkElRCld4 sw4xPzLR1IOSAtxmpI86xFex6hvZ1/L5SzNNs0JKqAcSrRg1Ef8ZWEVFgf6nYLUKvQGr S2bw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:sender:in-reply-to :references:from:date:message-id:subject:to:cc; bh=P8hwdrM8dUg1TCp+3S7MYDTFbfUwVFd+nN6/DlnJwxc=; b=IK0VsEO0p0W9aTFYnwEOa2bCgPjp+e7+8uvEdZhmBrvyIuPnfSpB6AljGQ6EIIeysy ebNT9UNooPFUYH9lIQ4VP3240kJf11xnwlO4SMmeVPCv5RVOYZHYEWvWnKD3oYfNu//n x4yLlZMPxaTLRz85pBpdwpYv1p/Kp8exiGRLZtV0A4a4nYpDrYgXvB9LVVP1s75FEVgX 4QADVqdopeJq/HwO9A0TqR9x83rF7rlx6dEVdSSBd4INti3k8GHdj1Y/P+evsxy2oQph H9/6POB1fHlJHYaTOivSxTW+llAh+X/Av5SHyHvI2QMR4q1TvxPbhVKGBziHTQXlpFTu 3VJQ== X-Gm-Message-State: ALKqPwco9sj03ewbPAzJvuRh3CKWwoUGY0GtffXolOx88E0zDo2Y9T3N DLHgYD7vcWma0gOXkKXjmRDs6d5Z/hAhKzL6PNs= X-Received: by 2002:adf:dd8c:: with SMTP id x12-v6mr17950997wrl.212.1528118686058; Mon, 04 Jun 2018 06:24:46 -0700 (PDT) MIME-Version: 1.0 Reply-To: myungjoo.ham@gmail.com Received: by 2002:adf:b593:0:0:0:0:0 with HTTP; Mon, 4 Jun 2018 06:24:05 -0700 (PDT) In-Reply-To: References: <1527745019-25155-1-git-send-email-akhilpo@codeaurora.org> <20180531061720epcms1p31f5451bcf3150a7dddd33e1e415bb730@epcms1p3> From: MyungJoo Ham Date: Mon, 4 Jun 2018 22:24:05 +0900 X-Google-Sender-Auth: uhk0bc3yDk9KF47stAqiEjxafjQ Message-ID: Subject: Re: [RFC] PM / devfreq: Add support for alerts To: Akhil P Oommen Cc: "linux-pm@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "mka@chromium.org" , "jcrouse@codeaurora.org" , Kyungmin Park , Chanwoo Choi , "linux-arm-msm@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Akhil, Actually, this provides custom events for governors, with different behaviors per each governor, while Matthias's give you the effects not targeted for a specific governor. Could you please show me why (the usage cases) you need this additional event for governors? (You need to implement an event handler in each governor for this approach). Cheers, MyungJoo On Fri, Jun 1, 2018 at 8:43 PM, Akhil P Oommen wrote: > > > On 5/31/2018 11:47 AM, MyungJoo Ham wrote: >>> >>> Currently, DEVFREQ reevaluates the device state periodically and/or >>> based on the OPP list changes. Private API has to be exposed to allow >>> the device driver to alert/notify the governor to reevaluate when a new >>> set of data is available. This makes the governor more coupled to a >>> particular device driver. We can improve here by exposing a DEVFREQ API >>> to allow the device drivers to send generic alerts to the governor. >>> >>> Signed-off-by: Akhil P Oommen >>> --- >>> drivers/devfreq/devfreq.c | 21 +++++++++++++++++++++ >>> drivers/devfreq/governor.h | 1 + >>> include/linux/devfreq.h | 5 +++++ >>> 3 files changed, 27 insertions(+) >>> >> Hello Akhil, >> >> It appears that this will have the same effect with >> "[PATCH 08/11] PM / devfreq: Make update_devfreq() public" from Matthias >> Kaehlcke, doesn't it? >> >> >> Cheers, >> MyungJoo >> > Hi MyngJoo, > > The patch you mentioned is a step in the right direction. But this patch > allows: > 1. the governor to decide whether to reevaluate or not. I feel it would be a > better architecture (better Separation of Concern) if that decision is left > to the governor alone. > 2. the devices to share multiple types of alerts. A governor may use these > alerts for internal bookkeeping/algorithm and decide to reevaluate policy > when it is necessary. Since we are opening up a new devfreq API for devices, > isn't it better to go for a generic one? > > Regards, > Akhil. -- MyungJoo Ham, Ph.D. S/W Center, Samsung Electronics