Hi!

>       1. The best case: an init function calls a non-init, which in
>       turn calls an init:
> 
>               void __init probe() { a(); }
>               void a() { b(); }
>               void __init b() { ... }

>       in this case, is the missing __init on 'a' only a performance
>       bug in that a's code won't be freed up?

...not neccesarily an error. If a() is being used to do stuff needed at
runtime, and only calls b() at initialzation.

> On the other hand, if I understood the rules right, this next one looks like
> a more exciting error, since an __exit routine is calling an __init routine:

Actually, it is right for subtle reasons:

__exit is only used in module case. And in module case __init functions are
not freed.
                                                                Pavel
-- 
Philips Velo 1: 1"x4"x8", 300gram, 60, 12MB, 40bogomips, linux, mutt,
details at http://atrey.karlin.mff.cuni.cz/~pavel/velo/index.html.

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

Reply via email to