From: Ryan Mallon <rmallon@gmail.com>
To: Luca Clementi <luca.clementi@gmail.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-kernel@vger.kernel.org,
Brian Swetland <swetland@google.com>
Subject: Re: [PATCH] Staging: Android: logger: module_exit implementationg
Date: Mon, 05 Nov 2012 11:03:44 +1100 [thread overview]
Message-ID: <50970260.3020004@gmail.com> (raw)
In-Reply-To: <CAERW5OyUN_RCOsihCOUnWwAxFA4ODiqX-=i9x=zEcHXczVNCGA@mail.gmail.com>
On 04/11/12 04:45, Luca Clementi wrote:
> On Fri, Nov 2, 2012 at 11:29 AM, Greg Kroah-Hartman
> <gregkh@linuxfoundation.org> wrote:
>> On Thu, Nov 01, 2012 at 11:15:52PM -0700, Luca Clementi wrote:
<snip>
>>> + vfree(current_log->buffer);
>>> + kfree(current_log->misc.name);
>>> + kfree(current_log);
>>> + }
>>> +
>>> + return;
>>> +}
>>> +
>>> +
>>> +module_init(logger_init);
>>
>> Is module_init() the same "level" as device_initcall()? Did you test
>> this out in an Android system?
>
> Honestly I haven't tested it on Android, but in include/linux/init.h there is:
>
> #define module_init(x) __initcall(x);
> ...
> #define __initcall(fn) device_initcall(fn)
>
> Which lead me to think that there is not much difference between the two call.
The different initcalls run at different times. Often modules run with
something other than module_init if there are other dependencies on the
module/subsystem (see i2c core/busses for example). You would need to
check why logger was using device_initcall and make sure that it works
correctly (e.g. doesn't miss some early logs) in order to make this
change. It should be done as a separate patch anyway to make it easier
to identify any issues with it later.
~Ryan
next prev parent reply other threads:[~2012-11-05 0:03 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-02 6:15 [PATCH] Staging: Android: logger: module_exit implementation Luca Clementi
2012-11-02 18:29 ` [PATCH] Staging: Android: logger: module_exit implementationg Greg Kroah-Hartman
2012-11-03 5:40 ` Brian Swetland
2012-11-03 17:45 ` Luca Clementi
2012-11-05 0:03 ` Ryan Mallon [this message]
2012-11-04 23:57 ` [PATCH] Staging: Android: logger: module_exit implementation Ryan Mallon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50970260.3020004@gmail.com \
--to=rmallon@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luca.clementi@gmail.com \
--cc=swetland@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).