Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp5220236rwb; Mon, 14 Nov 2022 00:47:58 -0800 (PST) X-Google-Smtp-Source: AA0mqf6K928SlrZjmIRYYbEBJ1hnr2/SDWu/XApYt0hI/iyZF/En0KSh6sjtZ7JTUEvOHbfdm4SB X-Received: by 2002:a17:902:daca:b0:17a:a81:2a52 with SMTP id q10-20020a170902daca00b0017a0a812a52mr12614413plx.159.1668415678538; Mon, 14 Nov 2022 00:47:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668415678; cv=none; d=google.com; s=arc-20160816; b=iRNS/aqMiKD+82EnW049ZSKA2mNxYVtPqTMR8IvkmFNJA9nl9P7UE5tB0hSBDaVbXf qr/jSVIW7zoU8PRI4wCZtNYC3FtHNcPiI/8tE0ObWb4FJXIYs6q5XYqsmhXHNfN7+OBF NAQN5yJ+QyPlbG0iBrgCrQbD6KWls9C+zRdGKZz0XOdR2QD1QUR3gy/QQm6z9ZKYhqFa DF6jAC+6IeXV9zlfHjQfv0KR/RDiks6LDlDcpdiR+3nme2LnLHm6UUXT06DWJHtbEMww SK5iXkp/pix4Dxbg1cdRM9AKrWQg1wjp1POuF2aKb8iSJJAPpQ5FSWISP7xXjjyByvta eZ+w== 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=HQGkATHIiYKOQokJXf6c9QY0hq8U9EHsD8wCrhW5CFs=; b=ku1IRJlUARkEPCDyAwvFLsk4KVOFBqnaC9H/BJ4lcZuvvIjU7cZtWgM+XoAjjWpHTG uc8FL47la+0vSWEmG9+6yy6GntyaeL1dhTvgxznJ3aggYOjw93azDaZ2xbr99BBo0g+O VoYjUrmkrhnVVRWF4zQvHasBtbgqHkkK6qYABZJlC6jjhmNSY1ZBoY7Q5QL1dlj/hMbo sJdkYI3/7gFMp0bx8cspJvmUIr28LjVWZtDGCrzy+6ebBb130q8VJIT67n9EVswA7Giy s7waec703WY87qUL6qAkfkblhYx+pzZTRGpKSYX4VCpJY1nMU4IbszhnbqUjXKyc3r99 LGQA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=yr+eNoZv; 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=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e8-20020aa78248000000b0056cd93aac47si8258126pfn.358.2022.11.14.00.47.47; Mon, 14 Nov 2022 00:47:58 -0800 (PST) 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=@linuxfoundation.org header.s=korg header.b=yr+eNoZv; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235914AbiKNHMu (ORCPT + 88 others); Mon, 14 Nov 2022 02:12:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54420 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234021AbiKNHMt (ORCPT ); Mon, 14 Nov 2022 02:12:49 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CD6D813E13; Sun, 13 Nov 2022 23:12:46 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 601D960ED9; Mon, 14 Nov 2022 07:12:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 33E06C433C1; Mon, 14 Nov 2022 07:12:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1668409965; bh=lilXaazAdhkbfVH4r45BrIKBuaIhsxredlrTJPuVlTk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=yr+eNoZv9eHLu0GnwKHzlOKCqE3b/3nTkMds8zWUkpGiYjbtixX+j+uXGpuNJ7ljA Khrw+5LK2ACsPAktwOoe6yIzXApPQu2ZnL3m8YEPTkvh8A+DOuDqGy7rtEV0yF0N3t Y6pYa6CkU7GLDhHVdIXknG6noEPnFLH1GNVjDekk= Date: Mon, 14 Nov 2022 08:12:42 +0100 From: Greg KH To: Mario Limonciello Cc: Sven van Ashbrook , Rafael J Wysocki , linux-pm@vger.kernel.org, platform-driver-x86@vger.kernel.org, Pavel Machek , Len Brown , John Stultz , Thomas Gleixner , Stephen Boyd , Rajneesh Bhardwaj , S-k Shyam-sundar , rrangel@chromium.org, Rajat Jain , David E Box , Hans de Goede , linux-kernel@vger.kernel.org Subject: Re: [RFC v2 1/3] PM: Add a sysfs files to represent sleep duration Message-ID: References: <20221110064723.8882-1-mario.limonciello@amd.com> <20221110064723.8882-2-mario.limonciello@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20221110064723.8882-2-mario.limonciello@amd.com> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS 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 Thu, Nov 10, 2022 at 12:47:21AM -0600, Mario Limonciello wrote: > +static ssize_t last_hw_state_residency_show(struct kobject *kobj, > + struct kobj_attribute *attr, char *buf) > +{ > + return sprintf(buf, "%llu\n", suspend_stats.last_hw_state_residency); sysfs_emit() please for sysfs files, not a "raw" sprintf(). checkpatch.pl should have caught that for you, but sometimes it doesn't. thanks, greg k-h