Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751883AbdGRRuL (ORCPT ); Tue, 18 Jul 2017 13:50:11 -0400 Received: from smtprelay0098.hostedemail.com ([216.40.44.98]:38490 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751408AbdGRRuJ (ORCPT ); Tue, 18 Jul 2017 13:50:09 -0400 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 50,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::::::::::,RULES_HIT:41:355:379:541:599:960:967:973:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1540:1593:1594:1711:1730:1747:1777:1792:2393:2525:2561:2564:2682:2685:2828:2859:2933:2937:2939:2942:2945:2947:2951:2954:3022:3138:3139:3140:3141:3142:3352:3622:3865:3866:3867:3868:3870:3871:3872:3873:3874:3934:3936:3938:3941:3944:3947:3950:3953:3956:3959:4321:5007:6119:7903:8985:9025:10004:10400:10848:11232:11658:11783:11914:12043:12048:12296:12679:12740:12895:13069:13138:13160:13229:13231:13311:13357:13439:13523:13894:14180:14181:14659:14721:21067:21080:21627:30054:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:2,LUA_SUMMARY:none X-HE-Tag: trade44_1e25712b0d70c X-Filterd-Recvd-Size: 2006 Message-ID: <1500400205.25934.27.camel@perches.com> Subject: Re: [PATCH v1 00/25] lib, rtc: Print rtc_time via %pt[dt][rv] From: Joe Perches To: Andy Shevchenko , Rasmus Villemoes , Greg Kroah-Hartman , Andrew Morton , linux-kernel@vger.kernel.org, Alessandro Zummo , Alexandre Belloni , linux-rtc@vger.kernel.org Cc: Mark Salyzyn Date: Tue, 18 Jul 2017 10:50:05 -0700 In-Reply-To: <20170608134811.60786-1-andriy.shevchenko@linux.intel.com> References: <20170608134811.60786-1-andriy.shevchenko@linux.intel.com> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.22.6-1ubuntu1 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 899 Lines: 32 On Thu, 2017-06-08 at 16:47 +0300, Andy Shevchenko wrote: > Recently I have noticed too many users of struct rtc_time that printing > its content field by field. > > In this series I introduce %pt[dt][rv] specifier to make life a bit > easier. Hey Andy. I just saw a patch with a printk for rtc time from Mark Salyzyn. https://lkml.org/lkml/2017/7/18/885 Any idea if you want to push this extension? I like the concept and still think it could be extended a bit more. from: https://lkml.org/lkml/2017/6/8/1134 My preference would be for %pt[type] where is mandatory and could be: ????????r for struct rtc_time ????????6 for time64_t ????????k for ktime_t ????????T for struct timespec64 ????????etc and has an unspecified default of YYYY-MM-DD:hh:mm:ss Perhaps use the "date" formats without the leading % uses for for additional styles.