From patchwork Mon May 9 21:20:10 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Muckle X-Patchwork-Id: 9050051 Return-Path: X-Original-To: patchwork-linux-pm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id C2EE19F30C for ; Mon, 9 May 2016 21:21:56 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E41BC20123 for ; Mon, 9 May 2016 21:21:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1500920108 for ; Mon, 9 May 2016 21:21:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752437AbcEIVVn (ORCPT ); Mon, 9 May 2016 17:21:43 -0400 Received: from mail-pa0-f54.google.com ([209.85.220.54]:34424 "EHLO mail-pa0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752320AbcEIVUT (ORCPT ); Mon, 9 May 2016 17:20:19 -0400 Received: by mail-pa0-f54.google.com with SMTP id r5so78442272pag.1 for ; Mon, 09 May 2016 14:20:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=0yJ7tFHcAQWGSD8wsojTY/+ANtvzytSuQbZWv8TxnRc=; b=gsn75TZgFRetMSdsbadbCsx0S0QhS+LNzbIXyZADFPVJSLbu1uC26Rxgb7wohulU3Y wdPacLiceA6NovixoUWbainhe3Fc63sGhZmaHf8rV0hCNC1grTWHxAIzTYjU72lyk0Hz DCciUMqNisXiOf2uw4DDxFtJ7pV/AOV5Lk2kk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=0yJ7tFHcAQWGSD8wsojTY/+ANtvzytSuQbZWv8TxnRc=; b=jOAPkthPdWhHWSniDQakoNuP3pvYeaunfkldQMqcTgmWyb3j3+0vowtQAfk76Z/dYQ BqpNbAmAaRgIX0YI35UWJOmOFAKgmGvBw3h326gFGpvrmtlEc9y8E+t4wRMFEtXe90WT /UzmcvLLMNv7TeBG+nqPPdASi5/qYXWdUE8qnAfCCtOcB17CPnzqs9oPb9YAzHKCoYEj yeRlE1v/MJBY1Kz/F+fBtf51/xJKM6G8kML8JDmaDBGRoOe4UdKGwPnE9bwobXkJrgKC A9khUACzK59CdAJ0efpdd+QJJCyUJa9vzxIzJaIfM+oJV9UKq1oPXDQZTwVwJPq9q+HQ 7njQ== X-Gm-Message-State: AOPr4FVa4j1CtNqm4WdfTeQ+zXFCrk6FBS92+ve5ZIbiihrGR3KlGK00Rt/0AWwxgTr4crWl X-Received: by 10.66.95.102 with SMTP id dj6mr11388162pab.152.1462828818613; Mon, 09 May 2016 14:20:18 -0700 (PDT) Received: from graphite.smuckle.net (cpe-76-167-105-107.san.res.rr.com. [76.167.105.107]) by smtp.gmail.com with ESMTPSA id g5sm42815345pac.1.2016.05.09.14.20.17 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 09 May 2016 14:20:18 -0700 (PDT) From: Steve Muckle X-Google-Original-From: Steve Muckle To: Peter Zijlstra , Ingo Molnar , "Rafael J. Wysocki" Cc: linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, Vincent Guittot , Morten Rasmussen , Dietmar Eggemann , Juri Lelli , Patrick Bellasi , Michael Turquette , Viresh Kumar , Srinivas Pandruvada , Len Brown Subject: [PATCH 1/5] sched: cpufreq: add cpu to update_util_data Date: Mon, 9 May 2016 14:20:10 -0700 Message-Id: <1462828814-32530-2-git-send-email-smuckle@linaro.org> X-Mailer: git-send-email 2.4.10 In-Reply-To: <1462828814-32530-1-git-send-email-smuckle@linaro.org> References: <1462828814-32530-1-git-send-email-smuckle@linaro.org> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Spam-Status: No, score=-8.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Upcoming support for scheduler cpufreq callbacks on remote wakeups will require the client to know what the target CPU is that the callback is being invoked for. Add this information into the callback data structure. Signed-off-by: Steve Muckle --- include/linux/sched.h | 1 + kernel/sched/cpufreq.c | 1 + 2 files changed, 2 insertions(+) diff --git a/include/linux/sched.h b/include/linux/sched.h index 8344e1947eec..81aba7dc5966 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -3238,6 +3238,7 @@ static inline unsigned long rlimit_max(unsigned int limit) struct update_util_data { void (*func)(struct update_util_data *data, u64 time, unsigned long util, unsigned long max); + int cpu; }; void cpufreq_add_update_util_hook(int cpu, struct update_util_data *data, diff --git a/kernel/sched/cpufreq.c b/kernel/sched/cpufreq.c index 1141954e73b4..d88a78ea805d 100644 --- a/kernel/sched/cpufreq.c +++ b/kernel/sched/cpufreq.c @@ -42,6 +42,7 @@ void cpufreq_add_update_util_hook(int cpu, struct update_util_data *data, return; data->func = func; + data->cpu = cpu; rcu_assign_pointer(per_cpu(cpufreq_update_util_data, cpu), data); } EXPORT_SYMBOL_GPL(cpufreq_add_update_util_hook);