Re: [ 01/10] [Suspend2] kernel/power/modules.h



Hi.

On Thursday 02 February 2006 22:48, Pekka J Enberg wrote:
On Wednesday 01 February 2006 23:01, Pekka Enberg wrote:
+
+static inline void suspend_initialise_module_lists(void) {
+ INIT_LIST_HEAD(&suspend_filters);
+ INIT_LIST_HEAD(&suspend_writers);
+ INIT_LIST_HEAD(&suspend_modules);
+}

I couldn't find a user for this. I would imagine there's only one,
though, and this should be inlined there?

On Thu, 2 Feb 2006, Nigel Cunningham wrote:
I forgot to mention re this - yes, there's just one caller, in another
set of patches I'll send later (this was just the first set!). Having the
function to be inlined in this .h so that it's with other module specific
code, and then used in the caller once it has been #included, isn't that
the right way to do things?

Sorry, I can't parse the above :-). My point was that this is
probably called in a .c file so move the function in that file and
introduce it whenever you introduce the caller.

I understand that. However if I do it, I separate the routine from the code it
logically belongs with. On the other hand, I do no harm by leaving it in the
header. We don't end up with multiple copies of the routine.

Regards,

Nigel
--
See our web page for Howtos, FAQs, the Wiki and mailing list info.
http://www.suspend2.net IRC: #suspend2 on Freenode

Attachment: pgpvznFI5z4vP.pgp
Description: PGP signature



Relevant Pages

  • Re: Finding the instance reference of an object [long and probably boring]
    ... The semantics of call-by-sharing differ from call-by-reference in that assignments to function arguments within the function aren't visible to the caller. ... Although this term has widespread usage in the Python community, identical semantics in other languages such as Java and Visual Basic are often described as call-by-value, where the value is implied to be a reference to the object. ... The caller and called routine communicate only through the argument and result objects; routines do not have access to any variables of the caller. ...
    (comp.lang.python)
  • Re: BOONY lives!!! (Was: Re: Honeypot stats)
    ... group, calling image, phase of the moon, or whatever, the privileged routine needs to validate the caller BEFORE it does anything. ... How can I check that the callER of the UWSS has been INSTALLed. ... Feel free to put Exec_lock and User_Init in same/different shareables ... But if the callers need to be restricted based on privilege, ...
    (comp.os.vms)
  • Re: Re-starting...again
    ... helped me to keep a routine. ... imagine you are ... the shot, "look" at the object ball, and shoot. ... It takes away the pressure to "just hit the ball now" and establishes a good mental rhythm. ...
    (rec.sport.billiard)
  • Re: OOREXX 3.2 Elapsed timer (ooREXX V4.0.0 iffy too I think)
    ... 'Any timing the caller is doing is not affected'. ... No poor wording there! ... The clock is saved across internal routine calls, ...
    (comp.lang.rexx)
  • Re: Release 1.1 (beta) of my AES implementation
    ... > Now imagine using your style of coding in a project 10 tims bigger than ... application would invoke in main or a routine the ... > If you cripple your code out of the gate then it can only really go ... > simple to do, writing thread safe routines is fairly trivial, etc... ...
    (sci.crypt)