Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754019AbYKGQWk (ORCPT ); Fri, 7 Nov 2008 11:22:40 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752358AbYKGQWa (ORCPT ); Fri, 7 Nov 2008 11:22:30 -0500 Received: from mx2.redhat.com ([66.187.237.31]:60382 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750962AbYKGQW3 (ORCPT ); Fri, 7 Nov 2008 11:22:29 -0500 Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: <20081107075003.fa93ccf4.akpm@linux-foundation.org> References: <20081107075003.fa93ccf4.akpm@linux-foundation.org> <20081107003816.9b0f947a.akpm@linux-foundation.org> <20081107052336.652868737@polymtl.ca> <20081107053349.861709786@polymtl.ca> <20081106220530.5b0e3a96.akpm@linux-foundation.org> <25363.1226056819@redhat.com> To: Andrew Morton Cc: dhowells@redhat.com, Nicolas Pitre , Mathieu Desnoyers , Linus Torvalds , Ingo Molnar , Peter Zijlstra , linux-kernel@vger.kernel.org, Ralf Baechle , benh@kernel.crashing.org, paulus@samba.org, David Miller , Ingo Molnar , Thomas Gleixner , Steven Rostedt , linux-arch@vger.kernel.org Subject: Re: [RFC patch 08/18] cnt32_to_63 should use smp_rmb() Date: Fri, 07 Nov 2008 16:21:55 +0000 Message-ID: <8189.1226074915@redhat.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1369 Lines: 32 Andrew Morton wrote: > If gcc did that then it would need to generate static instances of > inlined functions within individual compilation units. It would be a > disaster for the kernel. For a start, functions which are "inlined" in kernel > modules wouldn't be able to access their static storage and modprobing > them would fail. Do you expect a static inline function that lives in a header file and that has a static variable in it to share that static variable over all instances of that function in a program? Or do you expect the static variable to be limited at the file level? Or just at the invocation level? > Does mn10300's get_cycles() really count backwards? Yes, because the value is generated by a pair of cascaded 16-bit hardware down-counters. > The first two callsites I looked at (crypto/tcrypt.c and fs/ext4/mballoc.c) > assume that it is an upcounter. Hmmm... I didn't occur to me that get_cycles() was available for use outside of arch code. Possibly it wasn't so used when I first came up with the code. I should probably make it count the other way. David -- 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/