Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934323AbaJ3TIY (ORCPT ); Thu, 30 Oct 2014 15:08:24 -0400 Received: from mout.kundenserver.de ([212.227.17.10]:51187 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751426AbaJ3TIX (ORCPT ); Thu, 30 Oct 2014 15:08:23 -0400 From: Arnd Bergmann To: Tina Ruchandani Cc: pavel@ucw.cz, len.brown@intel.com, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, opw-kernel@googlegroups.com, rjw@rjwysocki.net Subject: Re: [PATCH] PM / Hibernate: Migrate to ktime_t Date: Thu, 30 Oct 2014 20:08:17 +0100 Message-ID: <3436721.isgG5Fql2m@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) In-Reply-To: <20141030180453.GA55907@localhost> References: <20141030180453.GA55907@localhost> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Provags-ID: V02:K0:mugUDOMwjLRF2ZZrmNaV57ogBVJXwo7QWl2+KliBVz+ +r0IEhlHEqpOxfFnigDFdsRWLfEAKYO1bHHal93hG/QrEGeSa6 UVUL/Et+1roZQGiKMXcfwXtJ1khpeTXdmkSebqlFfCJSMe245S KzVZyZa/2Ss7Fkum83fsJCwauFU3hMiAsU9qdtewbeDOOgYhDE 4lhqgGPo++3xMTdGjvfwH6icuhY0hu7QNjrNKrGyJ+VReKXUE6 /IRFG2nZiMElfGZoVPQoPBck9zdplEhXU7emmeLLEMXKNuCitt P9LCzqOcF6nFtMN8Evk9QnXKjBTh2U0SW9WJiKdq3dTXQizajS 8hNSMVw1L0dcXb5L3Jrk= X-UI-Out-Filterresults: notjunk:1; Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thursday 30 October 2014 11:04:53 Tina Ruchandani wrote: > This patch migrates swsusp_show_speed and its callers to using ktime_t instead > of 'struct timeval' which suffers from the y2038 problem. > > Changes to swsusp_show_speed: > - use ktime_t for start and stop times > - pass start and stop times by value > Calling functions affected: > - load_image > - load_image_lzo > - save_image > - save_image_lzo > - hibernate_preallocate_memory > Design decisions: > - use ktime_t to preserve same granularity of reporting as before > - use centisecs logic as before to avoid 'div by zero' issues caused by > using seconds and nanoseconds directly > - use monotonic time (ktime_get()) since we only care about elapsed time. > > Signed-off-by: Tina Ruchandani > Suggested-by: Arnd Bergmann Reviewed-by: Arnd Bergmann > -- > Changes in v4: > - Rebased patch off of 3.18-rc1 > Changes in v3: > Note: you need three '-' characters to separate the patch description from any extra information that you want in the mail but not in the changelog. Arnd -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/