Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: Ralf Baechle <ralf@linux-mips.org>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Antony Pavlov <antonynpavlov@gmail.com>,
	linux-mips@linux-mips.org, Lars-Peter Clausen <lars@metafoo.de>
Subject: Re: [PATCH 2/2] MIPS: JZ4740: add missing header file to serial.h
Date: Wed, 17 Oct 2012 17:03:19 +0200	[thread overview]
Message-ID: <20121017150319.GB7047@linux-mips.org> (raw)
In-Reply-To: <CAMuHMdUf-UBNE+2DxvOo5Cc5+FbzQzvCMBJN2epBesmn0dnoAQ@mail.gmail.com>

On Tue, Oct 16, 2012 at 10:19:33AM +0200, Geert Uytterhoeven wrote:

> On Mon, Oct 15, 2012 at 11:38 PM, Antony Pavlov <antonynpavlov@gmail.com> wrote:
> > The 'uart_port' struct is used in the declaration of
> > the jz4740_serial_out() function.
> 
> It only needs a forward declaration, as it just references the pointer type.
> 
> > This commit adds the missing header file containing
> > declaration of the 'uart_port' struct.
> >
> > Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
> > ---
> >  arch/mips/jz4740/serial.h |    2 ++
> >  1 file changed, 2 insertions(+)
> >
> > diff --git a/arch/mips/jz4740/serial.h b/arch/mips/jz4740/serial.h
> > index aa5a939..dfc155c 100644
> > --- a/arch/mips/jz4740/serial.h
> > +++ b/arch/mips/jz4740/serial.h
> > @@ -16,6 +16,8 @@
> >  #ifndef __MIPS_JZ4740_SERIAL_H__
> >  #define __MIPS_JZ4740_SERIAL_H__
> >
> > +#include <linux/serial_core.h>
> > +
> 
> I.e. you can just use instead:
> 
>     struct uart_port;
> 
> >  void jz4740_serial_out(struct uart_port *p, int offset, int value);
> >
> >  #endif

Serial_core.h drags in eerythign and the kitchen sink so I really prefer
the forward declaration.

  Ralf

  reply	other threads:[~2012-10-17 15:03 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-15 21:38 [PATCH 1/2] MIPS: JZ4740: fix '#include guard' in serial.h Antony Pavlov
2012-10-15 21:38 ` [PATCH 2/2] MIPS: JZ4740: add missing header file to serial.h Antony Pavlov
2012-10-16  8:19   ` Geert Uytterhoeven
2012-10-17 15:03     ` Ralf Baechle [this message]
2012-10-17 14:59   ` Ralf Baechle

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=20121017150319.GB7047@linux-mips.org \
    --to=ralf@linux-mips.org \
    --cc=antonynpavlov@gmail.com \
    --cc=geert@linux-m68k.org \
    --cc=lars@metafoo.de \
    --cc=linux-mips@linux-mips.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