[PATCH v2 7/8] turbostat: Clean up error handling; disambiguate error messages; use err and errx

2013-08-20 Thread Josh Triplett
rbostat already uses _GNU_SOURCE, so switch to the err and errx functions from err.h, which take a format string. Signed-off-by: Josh Triplett --- tools/power/x86/turbostat/turbostat.c | 107 -- 1 file changed, 38 insertions(+), 69 deletions(-) diff --git a/

[PATCH v2 5/8] turbostat: Add a helper to parse a single int out of a file

2013-08-20 Thread Josh Triplett
Many different chunks of code in turbostat open a file, parse a single int out of it, and close it. Factor that out into a common function. Signed-off-by: Josh Triplett --- tools/power/x86/turbostat/turbostat.c | 81 +++ 1 file changed, 24 insertions(+), 57

[PATCH v2 2/8] turbostat: Don't attempt to printf an off_t with %zx

2013-08-20 Thread Josh Triplett
compiling for a 32-bit target: turbostat.c: In function 'get_msr': turbostat.c:231:3: warning: format '%zx' expects argument of type 'size_t', but argument 4 has type 'off_t' [-Wformat] Signed-off-by: Josh Triplett --- tools/power/x86/turbostat/turbost

[PATCH v2 6/8] turbostat: Factor out common function to open file and exit on failure

2013-08-20 Thread Josh Triplett
Several different functions in turbostat contain the same pattern of opening a file and exiting on failure. Factor out a common fopen_or_die function for that. Signed-off-by: Josh Triplett --- tools/power/x86/turbostat/turbostat.c | 31 --- 1 file changed, 16

[PATCH v2 4/8] turbostat: Check return value of fscanf

2013-08-20 Thread Josh Triplett
d_result [-Wunused-result] Fix these by checking the return value of those four calls to fscanf. Signed-off-by: Josh Triplett --- tools/power/x86/turbostat/turbostat.c | 20 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/tools/power/x86/turbostat/turbostat.c b

[PATCH v2 1/8] turbostat: Don't put unprocessed uapi headers in the include path

2013-08-20 Thread Josh Triplett
h. In the process, switch from msr.h to msr-index.h, since turbostat just wants the MSR numbers. Signed-off-by: Josh Triplett Cc: sta...@vger.kernel.org --- tools/power/x86/turbostat/Makefile| 2 +- tools/power/x86/turbostat/turbostat.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) di

[PATCH v2 3/8] turbostat: Use GCC's CPUID functions to support PIC

2013-08-20 Thread Josh Triplett
("cpuid" : "=a" (fms), "=c" (ecx), "=d" (edx) : "a" (1) : "ebx"); ^ GCC provides a header cpuid.h, containing a __get_cpuid function that works with both PIC and non-PIC. (On PIC, it saves and restores ebx around the cpuid instruction

[PATCH] turbostat: Don't put unprocessed uapi headers in the include path

2013-08-10 Thread Josh Triplett
h. In the process, switch from msr.h to msr-index.h, since turbostat just wants the MSR numbers. Signed-off-by: Josh Triplett Cc: sta...@vger.kernel.org --- CCing this to stable because it fixes a broken build on some systems. Applies as far back as 3.8. tools/power/x86/turbostat/Makefile| 2

[PATCH] turbostat: Don't attempt to printf an off_t with %zx

2013-08-10 Thread Josh Triplett
compiling for a 32-bit target: turbostat.c: In function 'get_msr': turbostat.c:231:3: warning: format '%zx' expects argument of type 'size_t', but argument 4 has type 'off_t' [-Wformat] Signed-off-by: Josh Triplett --- tools/power/x86/turbostat/turbost

[PATCH] turbostat: Use GCC's CPUID functions to support PIC

2013-08-10 Thread Josh Triplett
("cpuid" : "=a" (fms), "=c" (ecx), "=d" (edx) : "a" (1) : "ebx"); ^ GCC provides a header cpuid.h, containing a __get_cpuid function that works with both PIC and non-PIC. (On PIC, it saves and restores ebx around the cpuid instruction

[PATCH] turbostat: Check return value of fscanf

2013-08-10 Thread Josh Triplett
d_result [-Wunused-result] Fix these by checking the return value of those four calls to fscanf. Signed-off-by: Josh Triplett --- tools/power/x86/turbostat/turbostat.c | 20 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/tools/power/x86/turbostat/turbostat.c b

[PATCH] i915: Add a Kconfig option to turn on i915.preliminary_hw_support by default

2013-08-13 Thread Josh Triplett
When building kernels for a preliminary hardware target, having to add a kernel command-line option can prove inconvenient. Add a Kconfig option that changes the default of this option to 1. Signed-off-by: Josh Triplett --- I dropped the indication of the default in the module parameter

Re: [PATCH tip/core/rcu 6/7] rcu: Drive quiescent-state-forcing delay from HZ

2013-04-12 Thread Josh Triplett
> 250 > +#define RCU_JIFFIES_TILL_FORCE_QS 2 > +#else > +#define RCU_JIFFIES_TILL_FORCE_QS 1 > +#endif This seems like it really wants to use a duration calculated directly from HZ; perhaps (HZ/100)? - Josh Triplett -- To unsubscribe from this list: send the line "unsubs

Re: [PATCH tip/core/rcu 0/7] RCU fixes for 3.11

2013-04-12 Thread Josh Triplett
Don't allocate bootmem from rcu_init(), courtesy of Sasha Levin. > > 5.Remove "Experimental" flags from old RCU Kconfig options. > > 6.Automatically tune defaults for delays between attempts to > force quiescent states. > > 7.Merge adjacen

Re: [PATCH tip/core/rcu 0/2] SRCU changes for 3.11

2013-04-12 Thread Josh Triplett
s time for them to go. > > 2.Fix a bug where srcu_read_lock() is not released upon return > from kvmppc_hv_setup_htab_rma(). For both: Reviewed-by: Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to major

Re: [PATCH tip/core/rcu 6/7] rcu: Drive quiescent-state-forcing delay from HZ

2013-04-13 Thread Josh Triplett
On Fri, Apr 12, 2013 at 11:38:04PM -0700, Paul E. McKenney wrote: > On Fri, Apr 12, 2013 at 04:54:02PM -0700, Josh Triplett wrote: > > On Fri, Apr 12, 2013 at 04:19:13PM -0700, Paul E. McKenney wrote: > > > From: "Paul E. McKenney" > > > > > > Syst

Re: [PATCH tip/core/rcu 08/12] rcu: Remove the CONFIG_TINY_RCU ifdefs in rcutiny.h

2013-04-13 Thread Josh Triplett
IG_TINY_RCU legs of those ifdefs. > > Signed-off-by: Paul E. McKenney The #else branches of these ifdefs ought to disappear in the first patch of the series, since they cover the CONFIG_TINY_PREEMPT_RCU case. - Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe li

Re: [PATCH tip/core/rcu 0/12] TINY_RCU changes for 3.11

2013-04-13 Thread Josh Triplett
ing formats from documentation. > > 12. Shrink TINY_RCU a bit by moving exit_rcu() to TREE_RCU, leaving > TINY_RCU with a static inline empty function. For 2-7 and 9-12: Reviewed-by: Josh Triplett I responded to patch 8 with a note about moving part of it to patch 1; with that

Re: [PATCH tip/core/rcu 0/8] RCU callback-numbering simplifications for 3.11

2013-04-13 Thread Josh Triplett
caller, so inline check_for_new_grace_period(). > > 7.Given that rcu_start_gp_per_cpu() is a trivial wrapper function > with only one caller, inline it into its sole remaining call site. > > 8.Eliminate now-redundant call to note_gp_changes(). For all 8: Reviewed

Re: [PATCH tip/core/rcu 6/7] rcu: Drive quiescent-state-forcing delay from HZ

2013-04-13 Thread Josh Triplett
On Sat, Apr 13, 2013 at 12:34:25PM -0700, Paul E. McKenney wrote: > On Sat, Apr 13, 2013 at 11:18:00AM -0700, Josh Triplett wrote: > > On Fri, Apr 12, 2013 at 11:38:04PM -0700, Paul E. McKenney wrote: > > > On Fri, Apr 12, 2013 at 04:54:02PM -0700, Josh Triplett wrote: > >

Re: [PATCH tip/core/rcu 13/13] rcu: Shrink TINY_RCU by reworking CPU-stall ifdefs

2013-05-21 Thread Josh Triplett
are static, and called in only one place, so shouldn't the compiler inline them (and thus throw them away completely when empty)? Why does it not do so? - Josh Triplett > --- > kernel/rcutiny.c| 4 ++-- > kernel/rcutiny_plugin.h | 6 ++ > 2 files changed, 4 inse

Re: [PATCH tip/core/rcu 0/2] Documentation changes for 3.11

2013-05-21 Thread Josh Triplett
ng OS jitter form the kworker workqueue > kthreads. For some reason these are numbered 1/2, 2/2, and 1/1. In any case, for all three: Reviewed-by: Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kerne

Re: [PATCH tip/core/rcu 13/13] rcu: Shrink TINY_RCU by reworking CPU-stall ifdefs

2013-05-21 Thread Josh Triplett
On Tue, May 21, 2013 at 02:09:57PM -0700, Paul E. McKenney wrote: > On Tue, May 21, 2013 at 10:31:41AM -0700, Josh Triplett wrote: > > On Mon, May 20, 2013 at 07:58:20AM -0700, Paul E. McKenney wrote: > > > From: "Paul E. McKenney" > > > > &g

Re: very strange dependencies on CONFIG_EXPERT=n in kernel 3.8

2013-03-11 Thread Josh Triplett
xing. So, for now, turn on CONFIG_EXPERT and live with having CONFIG_DEBUG_KERNEL turned on. That aside, several of the above options should not depend on EXPERT; why would PCSPKR_PLATFORM or DEBUG_MEMORY_INIT need to depend on EXPERT? - Josh Triplett -- To unsubscribe from this list: send the lin

Re: [PATCH] drivers: gpu: drm: i915: Replaced calls to kmalloc & memcpy with kmemdup

2013-03-11 Thread Josh Triplett
this should just "return kmemdup(...);". That suggests an obvious further cleanup that coccinelle could easily handle: if (!foo) return NULL; return foo; should become just "return foo;". And you might then want to check for variables used *only* to capture a return value and

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-02 Thread Josh Triplett
? In particular, once this goes in, I'd like to add RCU-based hash resizing to it, which will require wrapping the hash table in a struct that also contains the size. So, please do consider having such a struct rather than relying on static array sizes. - Josh Triplett -- To unsubscribe fro

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-02 Thread Josh Triplett
d having to > dynamically allocate buckets for all cases. What about using a C99 flexible array member? Kernel style prohibits variable-length arrays, but I don't think the same rationale applies to flexible array members. struct hash_table { size_t count; struct hlist_head buc

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-02 Thread Josh Triplett
have a global non-static anonymous union. Using the non-union form would actually allow a global non-static hash table: #define DEFINE_HASHTABLE_INIT(name, bits) struct hash_table name = { .bits = bits, .buckets = { [0 ... ((1 << bits) - 1)] = HLIST_HEAD_INIT } } /* elsewhere */ extern struct ha

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-02 Thread Josh Triplett
On Thu, Aug 02, 2012 at 06:48:07PM +0200, Sasha Levin wrote: > On 08/02/2012 06:15 PM, Josh Triplett wrote: > > On Thu, Aug 02, 2012 at 03:04:19PM +0200, Sasha Levin wrote: > >> On 08/02/2012 01:23 PM, Sasha Levin wrote: > >>>> #define DEFINE_HASH_TABLE(nam

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-02 Thread Josh Triplett
tables of a fixed size are really quite noticeably faster. So I would > say that Sasha's patch to make *that* case easy actually sounds nice, > rather than making some more complicated case that is fundamentally > slower and more complicated. The current approach that Sasha and I ha

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-02 Thread Josh Triplett
On Thu, Aug 02, 2012 at 11:08:06AM -0700, Linus Torvalds wrote: > On Thu, Aug 2, 2012 at 10:59 AM, Josh Triplett wrote: > > > > You shouldn't have any extra indirection for the base, if it lives > > immediately after the size. > > Umm. You *always* have the ext

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-02 Thread Josh Triplett
On Thu, Aug 02, 2012 at 07:54:42PM +0200, Sasha Levin wrote: > On 08/02/2012 07:44 PM, Josh Triplett wrote: > > On Thu, Aug 02, 2012 at 06:48:07PM +0200, Sasha Levin wrote: > >> On 08/02/2012 06:15 PM, Josh Triplett wrote: > >>> On Thu, Aug 02, 2012 at 03:04

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-02 Thread Josh Triplett
On Thu, Aug 02, 2012 at 01:32:41PM -0700, Linus Torvalds wrote: > On Thu, Aug 2, 2012 at 1:25 PM, Josh Triplett wrote: > > > > Sorry, I should clarify what I meant: you'll have a total of one extra > > indirection, not two. > > Yes. But the hash table address gen

Re: [RFC 1/4] hashtable: introduce a small and naive hashtable

2012-08-03 Thread Josh Triplett
On Thu, Aug 02, 2012 at 11:47:01PM +0200, Sasha Levin wrote: > On 08/02/2012 10:41 PM, Josh Triplett wrote: > > On Thu, Aug 02, 2012 at 07:54:42PM +0200, Sasha Levin wrote: > >> /* I've "preprocessed" the DEFINE macro below */ > >> union { >

[PATCH] scripts/get_maintainer.pl: Default to --no-rolestats when output not a terminal

2012-08-03 Thread Josh Triplett
s and mails sent to some but not all recipients. To avoid the need to explicitly pass --no-rolestats for batch use, enable --rolestats by default only when outputting to a terminal. Reported-by: Alex Kelly Signed-off-by: Josh Triplett --- scripts/get_maintainer.pl | 13 - 1

Re: [PATCH] scripts/get_maintainer.pl: Default to --no-rolestats when output not a terminal

2012-08-03 Thread Josh Triplett
On Fri, Aug 03, 2012 at 11:33:21AM -0700, Joe Perches wrote: > On Fri, 2012-08-03 at 11:27 -0700, Josh Triplett wrote: > > scripts/get_maintainer.pl defaults to showing --rolestats, which > > provides annotations explaining why each person or list might want to > > know about

Re: [PATCH] scripts/get_maintainer.pl: Default to --no-rolestats when output not a terminal

2012-08-03 Thread Josh Triplett
On Fri, Aug 03, 2012 at 05:37:30PM -0700, Joe Perches wrote: > On Fri, 2012-08-03 at 11:47 -0700, Josh Triplett wrote: > > On Fri, Aug 03, 2012 at 11:33:21AM -0700, Joe Perches wrote: > > > On Fri, 2012-08-03 at 11:27 -0700, Josh Triplett wrote: > > > > scripts

Re: [RFC v3 1/7] hashtable: introduce a small and naive hashtable

2012-08-06 Thread Josh Triplett
macro, don't include the semicolon. > +/** > + * hash_for_each_possible - iterate over all possible objects for a giver key s/giver/given/ > + * @name: hashtable to iterate > + * @obj: the type * to use as a loop cursor for each bucke s/bucke/bucket/ - Josh Triplett -- To unsubscribe from th

Re: [PATCH] tty: Added a CONFIG_TTY option to allow removal of TTY

2012-08-24 Thread Josh Triplett
t but the ps/2 mouse bits shouldn't. On the other hand, most people disabling CONFIG_TTY will be building an extreme embedded system, and on such a system a PS/2 mouse seems highly unlikely. Given that, perhaps the goal of removing dependencies on TTY could happen incrementally once CO

Re: [PATCHv4 2/3] fs: Make core dump functionality optional

2012-08-10 Thread Josh Triplett
l that only takes up ~200k, at which point 2.6k represents a >1% decrease. Add a few more changes like this, and those decreases start to add up. At this point, no one thing you can chop out of the kernel will give you a 100k decrease by itself; you need a pile of changes like this one to do

[ANNOUNCE,RFC] rcuhashbash synchronization benchmark module

2008-02-19 Thread Josh Triplett
. For the locking approaches to synchronization, fine-grained locking works better than coarse-grained, and heavyweight locks like reader-writer locks lose to simpler locks like spinlocks. I look forward to any comments people may have on the rcuhashbash synchronization benchmark. - Josh Triplett S

Re: [PATCH 1/1] boot: Put initcall_debug into its own Kconfig option DEBUG_INITCALL

2012-08-13 Thread Josh Triplett
hose patches need to avoid introducing too much complexity. However, I don't think it makes sense to object to a patch that saves space solely on the grounds that it doesn't save *more* space. That would make it impossible to cut out small things, and small things add up. - Josh

Re: [PATCH 1/1] boot: Put initcall_debug into its own Kconfig option DEBUG_INITCALL

2012-08-14 Thread Josh Triplett
On Tue, Aug 14, 2012 at 08:03:41AM -0400, Josh Boyer wrote: > On Mon, Aug 13, 2012 at 9:18 PM, Josh Triplett wrote: > > On Mon, Aug 13, 2012 at 03:39:54PM -0700, Randy Dunlap wrote: > >> On 08/13/2012 03:08 PM, Thai Bui wrote: > >> >Hi all, > >> >

Re: [PATCH 1/1] boot: Put initcall_debug into its own Kconfig option DEBUG_INITCALL

2012-08-14 Thread Josh Triplett
On Tue, Aug 14, 2012 at 01:13:00PM -0700, Randy Dunlap wrote: > On 08/13/2012 06:18 PM, Josh Triplett wrote: > > On Mon, Aug 13, 2012 at 03:39:54PM -0700, Randy Dunlap wrote: > > In any case, do you object to the introduction of a Kconfig option at > > all, or to that option d

Re: [PATCH 1/1] boot: Put initcall_debug into its own Kconfig option DEBUG_INITCALL

2012-08-14 Thread Josh Triplett
On Tue, Aug 14, 2012 at 02:25:07PM -0700, Randy Dunlap wrote: > Surely. I have no gross objection to this specific patch. OK. Thanks! PATCHv2 will hide the option behind EMBEDDED and make it default to y. - Josh Triplett -- To unsubscribe from this list: send the line "unsubscri

Re: [PATCH] sched: Support compiling out real-time scheduling with REALTIME_SCHED.

2012-08-15 Thread Josh Triplett
the fair scheduler, and as this patch shows, far fewer on the real-time scheduler. Given both of the above, writing and integrating an entirely new scheduler (*and* dealing with the repeats of old flamewars that would ensue after posting it) seems a bit much to ask for a student project. :)

Re: False warning from Sparse

2012-07-21 Thread Josh Triplett
m. If that solution or a similar refactoring doesn't appeal to you, then you don't currently have any way of making that context warning go away, short of improving Sparse to handle this situation better. - Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

Re: [PATCH 4/4] rcutorture: use DEFINE_STATIC_SRCU()

2012-10-12 Thread Josh Triplett
On Sat, Oct 13, 2012 at 01:14:17AM +0800, Lai Jiangshan wrote: > use DEFINE_STATIC_SRCU() to simplify the rcutorture.c > > Signed-off-by: Lai Jiangshan Reviewed-by: Josh Triplett > --- > kernel/rcutorture.c | 41 ++--- > 1 files cha

Re: [PATCH 4/10] compiler-gcc{3,4}.h: Use GCC_VERSION macro

2012-09-28 Thread Josh Triplett
. If you intended to change that, could you please document why? And in any case, could you make that semantic change in a separate commit from the switch to GCC_VERSION? - Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a messa

Re: [PATCH 5/10] compiler{,-gcc4}.h: Remove duplicate macros

2012-09-28 Thread Josh Triplett
mpiletime_error seems wrong. - Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

Re: [PATCH 6/10] bug.h: Replace __linktime_error with __compiletime_error

2012-09-28 Thread Josh Triplett
extern void __build_bug_failed(void)\ > - __linktime_error("BUILD_BUG failed"); \ > + __compiletime_error("BUILD_BUG failed");\ > __build_bug_failed(); \ > } while (0) This change shoul

Re: [PATCH 7/10] compiler{,-gcc4}.h: Introduce __flatten function attribute

2012-09-28 Thread Josh Triplett
#endif > + > +/* flatten introduced in 4.1, but broken in 4.6.0 (gcc bug #48731)*/ > +# if GCC_VERSION != 40600 > +# define __flatten __attribute__((flatten)) > +# endif > +#endif /* GCC_VERSION >= 40102 */ Same comment as before: why 40102 rather than 40100? - Josh Triplett --

Re: [PATCH 8/10] bug.h: Make BUILD_BUG_ON generate compile-time error

2012-09-28 Thread Josh Triplett
rror_fallback() macro that declares a negative-sized array; you could then define __compiletime_error_fallback() as an empty macro when it doesn't exist. - Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vge

Re: [Bulk] Re: [PATCH 4/10] compiler-gcc{3,4}.h: Use GCC_VERSION macro

2012-09-28 Thread Josh Triplett
On Fri, Sep 28, 2012 at 07:31:53PM -0500, Daniel Santos wrote: > On 09/28/2012 07:20 PM, Josh Triplett wrote: > > On Fri, Sep 28, 2012 at 06:20:05PM -0500, Daniel Santos wrote: > >> --- a/include/linux/compiler-gcc4.h > >> +++ b/include/linux/compiler-gcc4.h > >&g

Re: [Bulk] Re: [PATCH 5/10] compiler{,-gcc4}.h: Remove duplicate macros

2012-09-28 Thread Josh Triplett
On Fri, Sep 28, 2012 at 07:34:36PM -0500, Daniel Santos wrote: > On 09/28/2012 07:23 PM, Josh Triplett wrote: > > On Fri, Sep 28, 2012 at 06:20:06PM -0500, Daniel Santos wrote: > >> __linktime_error() does the same thing as __compiletime_error() and is > >> only used

Re: [PATCH 7/10] compiler{,-gcc4}.h: Introduce __flatten function attribute

2012-09-28 Thread Josh Triplett
On Fri, Sep 28, 2012 at 07:38:32PM -0500, Daniel Santos wrote: > On 09/28/2012 07:26 PM, Josh Triplett wrote: > > On Fri, Sep 28, 2012 at 06:20:08PM -0500, Daniel Santos wrote: > >> --- a/include/linux/compiler-gcc4.h > >> +++ b/include/linux/compiler-

[PATCHv4 0/3] Fix ACPI BGRT support for images located in EFI boot services memory

2012-09-28 Thread Josh Triplett
hould replace the version currently in tip x86/efi. Josh Triplett (3): efi: Defer freeing boot services memory until after ACPI init efi: Add a function to look up existing IO memory mappings efi: Fix the ACPI BGRT driver for images located in EFI boot services memory arch/x86/platform/efi/

[PATCHv4 1/3] efi: Defer freeing boot services memory until after ACPI init

2012-09-28 Thread Josh Triplett
Some new ACPI 5.0 tables reference resources stored in boot services memory, so keep that memory around until we have ACPI and can extract data from it. Signed-off-by: Josh Triplett --- arch/x86/platform/efi/efi.c | 31 ++- include/linux/efi.h |5

[PATCHv4 2/3] efi: Add a function to look up existing IO memory mappings

2012-09-28 Thread Josh Triplett
mapping already created during EFI intiialization. Since the EFI code already maintains a memory map for that memory, add a function efi_lookup_mapped_addr to look up mappings in that memory map. Signed-off-by: Josh Triplett --- arch/x86/platform/efi/efi.c | 28

[PATCHv4 3/3] efi: Fix the ACPI BGRT driver for images located in EFI boot services memory

2012-09-28 Thread Josh Triplett
driver. Rework the existing ACPI BGRT driver to act as a simple wrapper exposing that image (and the properties from the BGRT) via sysfs. Signed-off-by: Josh Triplett --- arch/x86/platform/efi/Makefile |1 + arch/x86/platform/efi/efi-bgrt.c | 76 ++ arch

Re: [PATCH 8/10] bug.h: Make BUILD_BUG_ON generate compile-time error

2012-09-28 Thread Josh Triplett
On Fri, Sep 28, 2012 at 08:26:08PM -0500, Daniel Santos wrote: > On 09/28/2012 07:32 PM, Josh Triplett wrote: > > On Fri, Sep 28, 2012 at 06:20:09PM -0500, Daniel Santos wrote: > >> Negative sized arrays wont create a compile-time error in some cases > >> starting

Re: [PATCH 3/10] compiler-gcc.h: Add gcc-recommended GCC_VERSION macro

2012-09-30 Thread Josh Triplett
l, since Linux requires GCC 3.2 or newer. From compiler-gcc3.h: #if __GNUC_MINOR__ < 2 # error Sorry, your compiler is too old - please upgrade it. #endif - Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.ke

Re: [PATCH 8/10] bug.h: Make BUILD_BUG_ON generate compile-time error

2012-09-30 Thread Josh Triplett
On Sun, Sep 30, 2012 at 06:29:01PM -0500, Daniel Santos wrote: > On 09/28/2012 09:55 PM, Josh Triplett wrote: > > Assuming you don't call BUILD_BUG_ON_MSG more than once per line: > > > > /tmp$ cat test.c > > #define BUILD_BUG_ON_MSG_INTERNAL2(cond, msg, line) \ &

Re: linux-next: build warning after merge of the tip tree

2012-10-01 Thread Josh Triplett
mit f383a1e37bc3 ("efi: Add a stub for > efi_enter_virtual_mode on non-x86") and following patches. These > function definitions should be "static inline". Already fixed in the current version of those patches in tip. - Josh Triplett -- To unsubscribe from this list:

Re: [PATCHv3 1/4] efi: Add a stub for efi_enter_virtual_mode on non-x86

2012-10-01 Thread Josh Triplett
On Mon, Oct 01, 2012 at 08:28:32PM +, Arnd Bergmann wrote: > On Saturday 08 September 2012, Josh Triplett wrote: > > +#ifdef CONFIG_X86 > > extern void efi_enter_virtual_mode (void); /* switch EFI to virtual > > mode, if possible */ > > +#else > > +static

Re: [PATCH v6 4/25] compiler-gcc{3,4}.h: Use GCC_VERSION macro

2012-10-01 Thread Josh Triplett
PATCHLEVEL__ <= 1 > > +# if GCC_VERSION >= 40100 && GCC_VERSION <= 40101 > > //# error Your version of gcc miscompiles the __weak directive > > # endif > > #endif > > @@ -13,11 +13,11 @@ > > #define __must_check __attribute

Re: CONFIG_EXPERT is a booby trap

2012-10-01 Thread Josh Triplett
> > Anyway, the hid drivers are certainly a big user of this mechanism. > Many of them are like HID_APPLE: > > config HID_APPLE > tristate "Apple {i,Power,Mac}Books" if EXPERT > depends on (USB_HID || BT_HIDP) > default !EXPERT This just see

Re: [PATCHv4] tty: Added a CONFIG_TTY option to allow removal of TTY

2013-01-18 Thread Josh Triplett
19 -13 > do_exit 15431526 -17 > bitmap_zero 60 40 -20 > arch_local_irq_save 137 117 -20 > release_task 674 652 -22 > s

Re: + rcu-split-listh-and-move-rcu-protected-lists-into-rculisth.patch added to -mm tree

2008-02-26 Thread Josh Triplett
gt; Signed-off-by: Franck Bui-Huu <[EMAIL PROTECTED]> > Acked-by: Paul E. McKenney <[EMAIL PROTECTED]> > Cc: Josh Triplett <[EMAIL PROTECTED]> > Signed-off-by: Andrew Morton <[EMAIL PROTECTED]> This seems fine to me. Having the headers separate might make it more dif

Re: + rcu-split-listh-and-move-rcu-protected-lists-into-rculisth.patch added to -mm tree

2008-02-26 Thread Josh Triplett
Franck Bui-Huu wrote: > Josh Triplett wrote: >> [I did not see this patch go by on any mailing list, so I replied to >> the -mm mail and CCed LKML.] >> > > Well I'm pretty sure to have always CC'ed LKML, see for example: > > http://lkml.org/lkml/20

Re: [PATCH 6/6] x86: Exit RCU extended QS on notify resume

2012-07-06 Thread Josh Triplett
AR if X86_32 > > select GENERIC_STRNCPY_FROM_USER > > select GENERIC_STRNLEN_USER > > + select HAVE_RCU_USER_QS if X86_64 > > And I will bite yet again. Why only 64-bit kernels? Because HAVE_RCU_USER_QS requires an architecture-specific component, and this patch series only added

Re: [PATCH tip/core/rcu 4/6] rcu: Silence compiler array out-of-bounds false positive

2013-01-07 Thread Josh Triplett
t change it unexpectedly, since rcu_num_lvls doesn't get declared as static? Unfortunately, the loop macros in rcutree.h make it difficult to make rcu_num_lvls static, but as far as I can tell only one use of those macros ever gets expanded outside of rcutree.c: the one in rcutree_trace.c. If

Re: [PATCH tip/core/rcu 0/6] RCU fixes for 3.9

2013-01-07 Thread Josh Triplett
cu_start_batch(). > > 2. Declare rcu_is_cpu_rrupt_from_idle() static, courtesy of > > Josh Triplett. > > 3. Make rcu_eqs_enter_common() trace the new nesting value instead > > of zero, courtesy of Li Zhong. > > 4. Silence a gcc array-out-of-bounds false positive in rcu

Re: [PATCH tip/core/rcu 1/1] Tiny RCU changes for 3.9

2013-01-07 Thread Josh Triplett
sual "---" line between the commit message and the patch. This patch seems reasonable to me, but the repeated use of #if defined(CONFIG_SMP) || defined(CONFIG_RCU_TRACE) seems somewhat annoying, and fragile if you ever decide to change the conditions. How about defining an appropriate s

Re: [PATCH tip/core/rcu 0/3] Documentation and rcutorture changes for 3.9

2013-01-07 Thread Josh Triplett
e list of atomic operations and memory > barriers, courtesy of Richard Braun. For the whole series: Reviewed-by: Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH tip/core/rcu 05/14] rcu: Distinguish "rcuo" kthreads by RCU flavor

2013-01-07 Thread Josh Triplett
a name ending in /$cpunum ?, rather than just $cpunum? For instance, kworker/0, kworker/1, and so on? Seems like these threads should follow that convention. - Josh Triplett -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

Re: [PATCH tip/core/rcu 04/14] rcu: Provide compile-time control for no-CBs CPUs

2013-01-07 Thread Josh Triplett
> printk(KERN_INFO "\tRCU restricting CPUs from NR_CPUS=%d to > nr_cpu_ids=%d.\n", NR_CPUS, nr_cpu_ids); > #ifdef CONFIG_RCU_NOCB_CPU > +#if CONFIG_RCU_NOCB_CPU_DEFAULT != 0 That would then make each of these conditionals self-documenting as well. - Josh Triplett -- To unsubscribe

Re: [PATCH tip/core/rcu 1/1] Tiny RCU changes for 3.9

2013-01-07 Thread Josh Triplett
On Mon, Jan 07, 2013 at 08:57:48AM -0800, Paul E. McKenney wrote: > On Mon, Jan 07, 2013 at 07:58:10AM -0800, Josh Triplett wrote: > > On Sat, Jan 05, 2013 at 09:50:59AM -0800, Paul E. McKenney wrote: > > > rcu: Provide RCU CPU stall warnings for tiny RCU > > > >

Re: [PATCH tip/core/rcu 4/6] rcu: Silence compiler array out-of-bounds false positive

2013-01-07 Thread Josh Triplett
On Mon, Jan 07, 2013 at 07:08:55PM +0100, Markus Trippelsdorf wrote: > On 2013.01.07 at 09:16 -0800, Paul E. McKenney wrote: > > On Mon, Jan 07, 2013 at 07:50:02AM -0800, Josh Triplett wrote: > > > On Sat, Jan 05, 2013 at 09:09:36AM -0800, Paul E. McKenney wrote: > > >

Re: [PATCH tip/core/rcu 1/1] Tiny RCU changes for 3.9

2013-01-07 Thread Josh Triplett
On Mon, Jan 07, 2013 at 02:19:15PM -0800, Paul E. McKenney wrote: > On Mon, Jan 07, 2013 at 09:56:06AM -0800, Josh Triplett wrote: > > On Mon, Jan 07, 2013 at 08:57:48AM -0800, Paul E. McKenney wrote: > > > On Mon, Jan 07, 2013 at 07:58:10AM -0800, Josh Triplett wrote: > &

Re: [PATCH 3/7] Move rcutorture to tests/

2008-01-10 Thread Josh Triplett
On Thu, 2008-01-10 at 17:27 +0530, Ananth N Mavinakayanahalli wrote: > From: Ananth N Mavinakayanahalli <[EMAIL PROTECTED]> > > Move the rcutorture infrastructure to tests/ > > Signed-off-by: Ananth N Mavinakayanahalli <[EMAIL PROTECTED]> Fine by me. Acked-by: Josh

Re: idio{,ma}tic typos (was Re: + fix-vm_can_nonlinear-check-in-sys_remap_file_pages.patch added to -mm tree)

2007-10-10 Thread Josh Triplett
this patch to handle those as well, just by dropping the check for an 'x' or 'X', and renaming the flag. As far as patch beauty goes, I think this patch looks just fine. - Josh Triplett - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the

Re: idio{,ma}tic typos (was Re: + fix-vm_can_nonlinear-check-in-sys_remap_file_pages.patch added to -mm tree)

2007-10-10 Thread Josh Triplett
dy, which it uses to validate expressions used for things like bitfield widths or array sizes. I could easily have Sparse warn on any use of an integer constant expression as an operand of || or &&. However, I can imagine that that might lead to some false positives when intentionally u

Re: idio{,ma}tic typos (was Re: + fix-vm_can_nonlinear-check-in-sys_remap_file_pages.patch added to -mm tree)

2007-10-11 Thread Josh Triplett
Alexey Dobriyan wrote: > On Wed, Oct 10, 2007 at 04:45:46AM -0700, Josh Triplett wrote: >> Alexey Dobriyan wrote: >>> ["if (!x & y)" patch from [EMAIL PROTECTED] >>> ["if (!x & y)" patch from [EMAIL PROTECTED] >>> ["if (!x &am

Sparse 0.4.1 released

2007-11-13 Thread Josh Triplett
il Medve (1): Handle ignored attribute malloc Josh Triplett (4): Add comment on taint flags enum referencing expr->taint Add test-suite metadata to validation/local-label.c Add known-to-fail test case for a static forward declaration Makefile: VERSION=0.4.1 Mike Frysinger

[PATCH] i386: include asm/bugs.h in bugs.c for check_bugs prototype

2007-07-20 Thread Josh Triplett
C files should include the header files that prototype their functions. Eliminates a sparse warning: warning: symbol 'check_bugs' was not declared. Should it be static? Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- arch/i386/kernel/cpu/bugs.c |1 + 1 files changed, 1

[PATCH] x86_64: include asm/bugs.h in bugs.c for check_bugs prototype

2007-07-20 Thread Josh Triplett
C files should include the header files that prototype their functions. Eliminates a sparse warning: warning: symbol 'check_bugs' was not declared. Should it be static? Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- arch/x86_64/kernel/bugs.c |1 + 1 files changed, 1

[PATCH] Mark sysrq_sched_debug_show static.

2007-07-20 Thread Josh Triplett
Only sched.c uses sysrq_sched_debug_show, and sched.c includes sched_debug.c, so all uses of sysrq_sched_debug_show occur in the same source file. Eliminates a sparse warning: warning: symbol 'sysrq_sched_debug_show' was not declared. Should it be static? Signed-off-by: Josh Triple

[PATCH] i386: Mark pit_clockevent static

2007-07-20 Thread Josh Triplett
Nothing outside of arch/i386/kernel/i8253.c uses pit_clockevent, so mark it static. Eliminates a sparse warning: warning: symbol 'pit_clockevent' was not declared. Should it be static? Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- arch/i386/kernel/i8253.c |2 +- 1

[PATCH] CFS: Mark print_cfs_stats static

2007-07-20 Thread Josh Triplett
stats' was not declared. Should it be static? Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- This patch applies both to current Git and to 2.6.22.1-rt4. kernel/sched_fair.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/kernel/sched_fair.c b/kernel/sc

[-rt PATCH] i386: Mark nmi_show_regs static

2007-07-20 Thread Josh Triplett
Nothing outside of arch/i386/kernel/nmi.c uses nmi_show_regs, so mark it static. Eliminates a sparse warning introduced in -rt: warning: symbol 'nmi_show_regs' was not declared. Should it be static? Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- arch/i386/kernel/nmi.c |

[PATCH] x86_64: Mark nmi_show_regs static

2007-07-20 Thread Josh Triplett
Nothing outside of arch/x86_64/kernel/nmi.c uses nmi_show_regs, so mark it static. Eliminates a sparse warning introduced in -rt: warning: symbol 'nmi_show_regs' was not declared. Should it be static? Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- arch/x86_64/kernel/nm

Re: [PATCH] CodingStyle: proscribe do-while without braces.

2007-07-26 Thread Josh Triplett
On Thu, 2007-07-26 at 14:44 -0700, Andrew Morton wrote: > On Thu, 26 Jul 2007 14:37:02 -0700 Josh Triplett <[EMAIL PROTECTED]> wrote: > > > Sparse warns about do-while loops without braces; Linus's rationale from the > > Sparse Git changelog: > > >

[PATCH] CodingStyle: proscribe do-while without braces.

2007-07-26 Thread Josh Triplett
parse. > > Maybe that mental parsing is just me. Or maybe it should be warned > about. You decide. Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- Documentation/CodingStyle |7 +++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/Documentation/CodingStyle b

Re: [PATCH RFC -rt] Allow rcutorture to handle synchronize_sched()

2007-08-03 Thread Josh Triplett
ude approach, simply substituting the time > of day for get_random_bytes(). > > Signed-off-by: Paul E. McKenney <[EMAIL PROTECTED]> Acked-by: Josh Triplett <[EMAIL PROTECTED]> - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the

[PATCH] RCU: Remove prototype for nonexistent function synchronize_idle()

2007-08-08 Thread Josh Triplett
synchronize_idle() sounds like an interesting function, but we don't actually have it, so don't prototype it. Introduced in commit 9b06e818985d139fd9e82c28297f7744e1b484e1, in 2005. Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- include/linux/rcupdate.h |1 - 1

[PATCH] Fix typo in arch/i386/kernel/tsc.c

2007-08-09 Thread Josh Triplett
Signed-off-by: Josh Triplett <[EMAIL PROTECTED]> --- arch/i386/kernel/tsc.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/i386/kernel/tsc.c b/arch/i386/kernel/tsc.c index debd7db..8a58d30 100644 --- a/arch/i386/kernel/tsc.c +++ b/arch/i386/kernel/tsc.c @@

Re: 2.6.23-rc2-mm1: sleeping function called from invalid context at kernel/mutex.c:86

2007-08-09 Thread Josh Triplett
ress_lookup(), which is basically the same, only it doesn't take > the mutex. > > I guess a quicky fix would be to switch > kernel/time/timer_list.c:print_name_offset() from > lookup_module_symbol_name() to module_address_lookup(). But we'd still > have a mess in there. &

Re: [PATCH] CodingStyle: proscribe do-while without braces.

2007-07-27 Thread Josh Triplett
er, unless > called with extra parameter. Good point; Sparse shouldn't warn about this by default. I've turned that off in latest Sparse from Git, so you need to give -Wdo-while or -Wall to get warnings about that. However, the kernel gives -Wall, so you'll still see the warnings t

Re: [PATCH] CodingStyle: proscribe do-while without braces.

2007-07-27 Thread Josh Triplett
On Fri, 2007-07-27 at 11:27 -0700, Andrew Morton wrote: > On Fri, 27 Jul 2007 10:05:16 -0700 > Josh Triplett <[EMAIL PROTECTED]> wrote: > > > > Sparse warnings... I think it shouldn't complain either, unless > > > called with extra parameter. > > >

<    1   2   3   4   5   6   7   8   9   10   >