mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: weil@mail.berlios.de
Cc: linux-kernel@vger.kernel.org, avorontsov@ru.mvista.com,
	ben@decadent.org.uk, jgunthorpe@obsidianresearch.com
Subject: Re: [PATCH] phy: Add missing forward declaration (fixes compiler warning)
Date: Sun, 15 Aug 2010 00:01:48 -0700 (PDT)	[thread overview]
Message-ID: <20100815.000148.68144298.davem@davemloft.net> (raw)
In-Reply-To: <1280855041-4063-1-git-send-email-weil@mail.berlios.de>

From: Stefan Weil <weil@mail.berlios.de>
Date: Tue,  3 Aug 2010 19:04:01 +0200

> Without forward declaration for struct sk_buff, compilation
> of drivers/net/phy/fixed.c results in a warning:

linux/phy.h has had the appropriate forward declaration since
July 16th

In fact the forward declaration was added by the only patch
that added references to sk_buff in that header file:

--------------------
commit c1f19b51d1d87f3e3bb7e6648f43f7d57ed2da6b
Author: Richard Cochran <richardcochran@gmail.com>
Date:   Sat Jul 17 08:49:36 2010 +0000

    net: support time stamping in phy devices.
    
 ...
--------------------

As per your warning:

--------------------
  CC      drivers/net/phy/fixed.o
In file included from drivers/net/phy/fixed.c:20:
include/linux/phy.h:342: warning: 'struct sk_buff' declared inside parameter list
include/linux/phy.h:342: warning: its scope is only this definition or declaration, which is probably not what you want
include/linux/phy.h:343: warning: 'struct sk_buff' declared inside parameter list

(tested with linux kernel for openwrt / ar7, gcc-4.1.2)
--------------------

Line 342 in the current tree lands on a comment.  Please don't
post patches against external trees, or you'll always run into
problems like this.  Who knows what patches happen to be applied
to the openwrt tree you happen to have.

Always spin and test patches against upstream.


      reply	other threads:[~2010-08-15  7:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-03 17:04 Stefan Weil
2010-08-15  7:01 ` David Miller [this message]

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=20100815.000148.68144298.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=avorontsov@ru.mvista.com \
    --cc=ben@decadent.org.uk \
    --cc=jgunthorpe@obsidianresearch.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=weil@mail.berlios.de \
    /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

all inboxes | Powered by JetHome®