From: Roland Dreier <rdreier@cisco.com>
To: Andrew Morton <akpm@osdl.org>
Cc: Alexey Dobriyan <adobriyan@gmail.com>,
Jeff Garzik <jgarzik@pobox.com>,
netdev@vger.kernel.org
Subject: Re: [PATCH] CONFIG_PM=n slim: drivers/net/*
Date: Sat, 12 Aug 2006 10:06:29 -0700 [thread overview]
Message-ID: <adar6zlnasq.fsf@cisco.com> (raw)
In-Reply-To: <20060811194952.9d664698.akpm@osdl.org> (Andrew Morton's message of "Fri, 11 Aug 2006 19:49:52 -0700")
> > Also this won't allow
> >
> > struct pci_driver {
> > ...
> > #ifdef CONFIG_PM
> > int (*suspend)(...);
> > int (*resume)(...);
> > #endif
> > ...
> > };
> >
> > which is good for a) space savings in CONFIG_PM=n case, and
> > b) making drivers care about CONFIG_PM=n users hard way aka compilation
> > failure.
>
> eh? Both versions will generate identical code.
I think his point was that by #ifdef-ing out the assignment to
.suspend/.resume, then the actual suspend/resume members of struct
pci_driver could be removed in the CONFIG_PM=n case -- which would
shrink sizeof (struct pci_driver).
- R.
next prev parent reply other threads:[~2006-08-12 17:06 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-12 0:46 [PATCH] CONFIG_PM=n slim: drivers/net/* Alexey Dobriyan
2006-08-12 1:49 ` Andrew Morton
2006-08-12 2:30 ` Alexey Dobriyan
2006-08-12 2:49 ` Andrew Morton
2006-08-12 17:06 ` Roland Dreier [this message]
2006-08-12 18:39 ` Andrew Morton
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=adar6zlnasq.fsf@cisco.com \
--to=rdreier@cisco.com \
--cc=adobriyan@gmail.com \
--cc=akpm@osdl.org \
--cc=jgarzik@pobox.com \
--cc=netdev@vger.kernel.org \
/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).