Re: [PATCH 3/9] jump label: Fix module __init section race

From: Steven Rostedt
Date: Fri Oct 15 2010 - 22:09:32 EST


On Fri, 2010-10-15 at 16:09 -0400, Steven Rostedt wrote:

> --- a/kernel/jump_label.c
> +++ b/kernel/jump_label.c
> @@ -168,7 +168,8 @@ void jump_label_update(unsigned long key, enum jump_label_type type)
> count = e_module->nr_entries;
> iter = e_module->table;
> while (count--) {
> - if (kernel_text_address(iter->code))
> + if (iter->key &&
> + kernel_text_address(iter->code))

Peter, I know you hated this, but the alternative is either:

if (iter->key &&
kernel_text_address(iter->code))

or break 80 chars. All three seem bad (although I don't mind breaking 80
chars for this). But I'll leave it for now.

-- Steve

> arch_jump_label_transform(iter, type);
> iter++;
> }
> @@ -366,6 +367,39 @@ static void remove_jump_label_module(struct module *mod)
> }
> }


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/