netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Gu Zheng <guz.fnst@cn.fujitsu.com>
To: David Miller <davem@davemloft.net>
Cc: <netdev@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	<joe@perches.com>
Subject: Re: [PATCH v2] net: introduce helper macro for_each_cmsghdr
Date: Thu, 11 Dec 2014 09:05:59 +0800	[thread overview]
Message-ID: <5488EDF7.7070001@cn.fujitsu.com> (raw)
In-Reply-To: <20141210.144430.1749715282635917425.davem@davemloft.net>

Hi David,
On 12/11/2014 03:44 AM, David Miller wrote:

> From: David Miller <davem@davemloft.net>
> Date: Wed, 10 Dec 2014 13:48:04 -0500 (EST)
> 
>> From: Gu Zheng <guz.fnst@cn.fujitsu.com>
>> Date: Wed, 10 Dec 2014 13:36:25 +0800
>>
>>> Introduce helper macro for_each_cmsghdr as a wrapper of the enumerating
>>> cmsghdr from msghdr, just cleanup. 
>>>
>>> Signed-off-by: Gu Zheng <guz.fnst@cn.fujitsu.com>
>>
>> Applied, thanks.
> 
> This breaks the build, I'm reverting.

I'm very sorry.

> 
> You cannot use your new macros in
> Documentation/networking/timestamping/txtimestamp.c, that is a
> userland program and the header you are adding your helper to is not
> available to userspace.

IMO, the user-land programs need to be build with the matched headers separately.
I split the kernel codes and the user-land programs, build and install the kernel first,
and then build the user-land ones. 

> 
> This also means you didn't sufficiently test the build of your
> changes.

To be honest, I do the test as I mentioned above.

Thanks,
Gu

> 
> Documentation/networking/timestamping/timestamping.c: In function ‘printpacket’:
> Documentation/networking/timestamping/timestamping.c:172:2: warning: implicit declaration of function ‘for_each_cmsghdr’ [-Wimplicit-function-declaration]
> Documentation/networking/timestamping/timestamping.c:172:30: error: expected ‘;’ before ‘{’ token
> Documentation/networking/timestamping/timestamping.c:161:18: warning: unused variable ‘ts’ [-Wunused-variable]
> Documentation/networking/timestamping/timestamping.c:160:17: warning: unused variable ‘tv’ [-Wunused-variable]
> make[3]: *** [Documentation/networking/timestamping/timestamping] Error 1
> make[3]: *** Waiting for unfinished jobs....
> Documentation/networking/timestamping/txtimestamp.c: In function ‘__recv_errmsg_cmsg’:
> Documentation/networking/timestamping/txtimestamp.c:187:2: warning: implicit declaration of function ‘for_each_cmsghdr’ [-Wimplicit-function-declaration]
> Documentation/networking/timestamping/txtimestamp.c:187:19: error: ‘cmsg’ undeclared (first use in this function)
> Documentation/networking/timestamping/txtimestamp.c:187:19: note: each undeclared identifier is reported only once for each function it appears in
> Documentation/networking/timestamping/txtimestamp.c:187:30: error: expected ‘;’ before ‘{’ token
> Documentation/networking/timestamping/txtimestamp.c:185:18: warning: unused variable ‘cm’ [-Wunused-variable]
> Documentation/networking/timestamping/txtimestamp.c:184:27: warning: unused variable ‘tss’ [-Wunused-variable]
> Documentation/networking/timestamping/txtimestamp.c:183:28: warning: unused variable ‘serr’ [-Wunused-variable]
> Documentation/networking/timestamping/txtimestamp.c: At top level:
> Documentation/networking/timestamping/txtimestamp.c:123:13: warning: ‘print_timestamp’ defined but not used [-Wunused-function]
> Documentation/networking/timestamping/txtimestamp.c:159:13: warning: ‘print_pktinfo’ defined but not used [-Wunused-function]
> 

  reply	other threads:[~2014-12-11  1:05 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-10  5:36 [PATCH v2] net: introduce helper macro for_each_cmsghdr Gu Zheng
2014-12-10  6:56 ` Joe Perches
2014-12-10  8:15   ` Gu Zheng
2014-12-10 14:51     ` Joe Perches
2014-12-11  1:11       ` Gu Zheng
2014-12-10 18:48 ` David Miller
2014-12-10 19:44   ` David Miller
2014-12-11  1:05     ` Gu Zheng [this message]
2014-12-11  1:47       ` David Miller
2014-12-11  1:50         ` Gu Zheng
  -- strict thread matches above, loose matches on Subject: below --
2014-12-10  1:39 Gu Zheng
2014-12-10  1:56 ` Gu Zheng
2014-12-10  2:01 ` Joe Perches
2014-12-10  2:02   ` Gu Zheng

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=5488EDF7.7070001@cn.fujitsu.com \
    --to=guz.fnst@cn.fujitsu.com \
    --cc=davem@davemloft.net \
    --cc=joe@perches.com \
    --cc=linux-kernel@vger.kernel.org \
    --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).