Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3200016imu; Mon, 28 Jan 2019 00:08:17 -0800 (PST) X-Google-Smtp-Source: ALg8bN5TEF97zFxSnVgI/HZKMxguujDXsik/K02suf19XvglD8vGLNqDHb/xnPNOK9bwZ7rSmQ5s X-Received: by 2002:a62:3943:: with SMTP id g64mr21267078pfa.114.1548662897032; Mon, 28 Jan 2019 00:08:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548662897; cv=none; d=google.com; s=arc-20160816; b=rb41S914C+IRVFjZE+9YG88GmYpY9yUQ95W+w3mfnABShGyGt0oAczbbxm2/G03PdG LfVNSp9FSfoh1tAzBEZcQ1lNGsYTxPnETqJ5+6grz2FW6kyHWhv/XqGDqXEQo7rOxdcZ +kaxiDMT5itCKHKTrlR3Sj84tX6HdgX5PlG1DqyKaT2JAm8yXx9FY4ptkq03mCJdSe89 +P5CwoqE7yFx4VyrjLPOTnLOkwJpJ1Iznffol/PbyH2XiWX2toBeB2kFZpqbnpgjW0u9 MQTBJjcWb159CeGGu2AnhoiWaibbwOTj3ra7mTqL3H5whl2d/2r2aEhOsv4OwOTVTa0S YGvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:dlp-filter:cms-type :content-transfer-encoding:date:message-id:in-reply-to:cc:to:from :reply-to:subject:mime-version:dkim-signature:dkim-filter; bh=TM9djE3L0yJ81lsZxrNZ0rovqWWXgV3h5YaPywYLCUU=; b=zaiOrjXFjanPXTSz4A/b0LuRhW4hunp4M3Lk0PYlsKuXPt7x7/O4pptFsEwYU42fw4 RaSlsFEU0L3hK8cyUHqLR1kp1Lhh/0TFfczsgKrbimP0YgKhl/iugBOGAUOjCfsjVc4r Wgf7gwxw30PFCAyzBBnZhlgVbuJZ3TqP4PzyUa7xrSxaVkgU7bRXcyYWLrR/1i5h33XG vlAoYeMxJm63tK137HOIGsxfPOmsaGIK7mzmCYjEkr3XS0qLoB+RsBUwIR4JRJvXPWmY nlRboUe4/yTPGWWt+/cVMxYmu65tLsqk7z9vMHeLOIl3MkGa5gSF9TmG0djHSvmj+TQH o24w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=IWRE2rmf; 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=pass (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 10si4291026pgk.101.2019.01.28.00.08.01; Mon, 28 Jan 2019 00:08:17 -0800 (PST) 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=pass header.i=@samsung.com header.s=mail20170921 header.b=IWRE2rmf; 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=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726862AbfA1IFq (ORCPT + 99 others); Mon, 28 Jan 2019 03:05:46 -0500 Received: from mailout3.samsung.com ([203.254.224.33]:43888 "EHLO mailout3.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726654AbfA1IFp (ORCPT ); Mon, 28 Jan 2019 03:05:45 -0500 Received: from epcas1p4.samsung.com (unknown [182.195.41.48]) by mailout3.samsung.com (KnoxPortal) with ESMTP id 20190128080542epoutp03096cdc27e05a2576759aafe884267ad9~99I8z34rw0692706927epoutp03J for ; Mon, 28 Jan 2019 08:05:42 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout3.samsung.com 20190128080542epoutp03096cdc27e05a2576759aafe884267ad9~99I8z34rw0692706927epoutp03J DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1548662742; bh=TM9djE3L0yJ81lsZxrNZ0rovqWWXgV3h5YaPywYLCUU=; h=Subject:Reply-To:From:To:CC:In-Reply-To:Date:References:From; b=IWRE2rmfISbTC1J0Wy9ZfGyZxzh1gFtFEPmkicVfu3ByVGGVoeWNHXjrDHF/YLN5y Q7aG6KdNuSXRPSNn/ADMFoXjNOGSX1Gnb402Bapq4Bhg6Oq+VGyb5I54vKNSE++KXh KWr9Sy+0oAZbp6TO+AkW7VFml7M3Jigkv7HLcTsM= Received: from epsmges1p1.samsung.com (unknown [182.195.40.157]) by epcas1p2.samsung.com (KnoxPortal) with ESMTP id 20190128080538epcas1p299102d865a77f168357787b62df02213~99I5SpOO_2177421774epcas1p2Q; Mon, 28 Jan 2019 08:05:38 +0000 (GMT) X-AuditID: b6c32a35-297ff70000000fea-7b-5c4eb7cff98f Received: from epcas1p2.samsung.com ( [182.195.41.46]) by epsmges1p1.samsung.com (Symantec Messaging Gateway) with SMTP id 45.8C.04074.FC7BE4C5; Mon, 28 Jan 2019 17:05:35 +0900 (KST) Mime-Version: 1.0 Subject: RE: [PATCH] devfreq: Suspend all devices on system shutdown Reply-To: myungjoo.ham@samsung.com From: MyungJoo Ham To: Marek Szyprowski , "linux-kernel@vger.kernel.org" , "linux-pm@vger.kernel.org" , "linux-samsung-soc@vger.kernel.org" CC: Chanwoo Choi , Krzysztof Kozlowski , Bartlomiej Zolnierkiewicz , Lukasz Luba , Markus Reichl X-Priority: 3 X-Content-Kind-Code: NORMAL In-Reply-To: <20190125135403.10228-1-m.szyprowski@samsung.com> X-Drm-Type: N,general X-Msg-Generator: Mail X-Msg-Type: PERSONAL X-Reply-Demand: N Message-ID: <20190128080535epcms1p44636143629448c4e24a6628e87a72bf2@epcms1p4> Date: Mon, 28 Jan 2019 17:05:35 +0900 X-CMS-MailID: 20190128080535epcms1p44636143629448c4e24a6628e87a72bf2 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" X-CPGSPASS: Y X-CPGSPASS: Y CMS-TYPE: 101P X-Brightmail-Tracker: H4sIAAAAAAAAA11Sa0gUURTmOrvrKI1cV7OLSW0DigruOuraWL5Ai5VUpP5EWTrooOI+pp1d yzLaMqlMM0tIxTLBijbEfK5oBG5iT11CyEwNEUWFLEqLzNT2idK/73znO+c7596DY+JGkT9e oNaxWjWjJEWegu4XIdIwiyk9M7xsKYZuq20V0gvmEHp0eU5IWyxP3elPhgB6pLdBRC9VDgC6 1vLcjV4Y+A3oloFJ90RPxaeJC4p24zWRov/rMzfFjU4jUCy178oQHiuMzWeZXFYrYdU5mtwC dV4ceehIVlKWPDqcCqNi6L2kRM2o2DgyOTUj7GCB0joSKSlilHorlcHwPCmLj9Vq9DpWkq/h dXEky+UquRhOyjMqXq/Ok+ZoVPuo8PAIuVWYXZhfPR3MdeJnZl4sCgzgl6gceOAIRqHvQ18E 5cATF8MegEaq/lgDHCegN1rr8bFBH5iMpof8bHIxJJFh7Dlmwz5Qhq5OdQMbFsEw1PV00t7G Fy4DdKnto9AWYHASIPPyD+AwI1DtlVmBA+9Epkdddt4DxqO65Q9CB78djT1ZdHfhb4ONzlpf VPZ5CHNgbzS10gdcfWprNpw9z6HpiveYzRjBywAZ67rdHAkZenf3tX1jAqah2duLmG0zAQxE G9NeDkkyanvywO6Lwd3ItNhgl2AwBLX2ylzjG9pW3f/HGPRCX39WCF18z70Zp2sQMvc1O/UB 6O2dJuf4CjTXMYrdBHvqN1+6fotx/abxfYAZgR/L8ao8lqc4auvftgP7cYbKe0DNcKoZQByQ 24ija2mZYiFTxBerzADhGOlL9DenZ4qJXKb4LKvVZGn1SpY3A7l1/WrMf3uOxnrqal0WJY+I jIyko6hoOUWRO4jWxKRMMcxjdGwhy3Ks1lXnhnv4G4CeXFv9+fCv5lQXV1zzMurE1DfR+umI BHx06jDXNL/EFC0cvWWqGTz+6jxBXI/J6Zc2FKiC+58lec62hO5HCScPXKySRksqjR2HS7wK o6qNK4EdRevjM5ZS2Xj6cGxieRDzRpD2mOoeSZnRZ88HtYDKzyI0YRo4fipl9UHJWikp4PMZ KhTT8sw/WsnORrIDAAA= DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20190125135414eucas1p2ffc71c63f1a27f67d076dec889954b40 References: <20190125135403.10228-1-m.szyprowski@samsung.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org >This way devfreq core ensures that all its devices will be set to safe >operation points before reboot operation. There are board on which some >aggressive power saving operation points are behind the capabilities of >the bootloader to properly reset the hardware and boot the board. This >way one can avoid board crash early after reboot. > >Similar pattern is used in CPUfreq subsystem. > >Reported-by: Markus Reichl >Signed-off-by: Marek Szyprowski >--- You are invoking ALL devfreq suspend callbacks at shutdown with this commit. Can you make it invoke only devices explicitly saying their needs to handle "SHUTDOWN" event? For example, we can add a flag at struct devfreq_dev_profile: "uint32_t requirement" , where 0x1: need to operate at the initial frequency for suspend 0x2: need to operate at the initial frequency for shutdown 0x4: it forgets its status at resume, reconfigure frequency at resume. (or reverse 0x1's semantics for the backward compatibility) ... Cheers, MyungJoo