Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751046AbWEHVUt (ORCPT ); Mon, 8 May 2006 17:20:49 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751088AbWEHVUt (ORCPT ); Mon, 8 May 2006 17:20:49 -0400 Received: from smtp.osdl.org ([65.172.181.4]:27050 "EHLO smtp.osdl.org") by vger.kernel.org with ESMTP id S1751046AbWEHVUs (ORCPT ); Mon, 8 May 2006 17:20:48 -0400 Date: Mon, 8 May 2006 14:23:22 -0700 From: Andrew Morton To: balbir@in.ibm.com Cc: linux-kernel@vger.kernel.org, lse-tech@lists.sourceforge.net, jlan@engr.sgi.com Subject: Re: [Patch 1/8] Setup Message-Id: <20060508142322.71e88a54.akpm@osdl.org> In-Reply-To: <20060502061255.GL13962@in.ibm.com> References: <20060502061255.GL13962@in.ibm.com> X-Mailer: Sylpheed version 1.0.0 (GTK+ 1.2.10; i386-vine-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 891 Lines: 30 Balbir Singh wrote: > > +static inline void delayacct_end(struct timespec *start, struct timespec *end, > + u64 *total, u32 *count) > +{ > + struct timespec ts = {0, 0}; > + s64 ns; > + > + do_posix_clock_monotonic_gettime(end); > + timespec_sub(&ts, start, end); > + ns = timespec_to_ns(&ts); > + if (ns < 0) > + return; > + > + spin_lock(¤t->delays->lock); > + *total += ns; > + (*count)++; > + spin_unlock(¤t->delays->lock); > +} - too large to be inlined - The initialisation of `ts' is unneeded (maybe it generated a bogus warning, but it won't do that if you switch timespec_sub to return-by-value) - 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/