public inbox for linux-serial@vger.kernel.org
 help / color / mirror / Atom feed
From: Philippe Langlais <philippe.langlais@stericsson.com>
To: "Dr. David Alan Gilbert" <linux@treblig.org>
Cc: "linux-serial@vger.kernel.org" <linux-serial@vger.kernel.org>
Subject: Re: serial.h v serial_core.h PORT_ defines?
Date: Tue, 31 Aug 2010 13:55:44 +0200	[thread overview]
Message-ID: <4C7CEDC0.50600@stericsson.com> (raw)
In-Reply-To: <20100827193541.GA29541@gallifrey>

Hi,
You are right.
I'll add my define in serial_core.h (#19), and withdraw U6_16550A 
definition in serial.h.
I'll post a patch to fix it.
I have the same question about these double definitions.

Thanks

Philippe

On 08/27/10 21:35, Dr. David Alan Gilbert wrote:
> Hi,
>    I was playing with sparse and it flagged that in drivers/serial/8250.c
> there is a duplicate initialiser in the uart_config[] array
> (from Linus's git):
>
>         [PORT_NS16550A] = {
>                  .name           = "NS16550A",
>                  .fifo_size      = 16,
>                  .tx_loadsz      = 16,
>                  .fcr            = UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
>                  .flags          = UART_CAP_FIFO | UART_NATSEMI,
>          },
>
> and
>         [PORT_U6_16550A] = {
>                  .name           = "U6_16550A",
>                  .fifo_size      = 64,
>                  .tx_loadsz      = 64,
>                  .fcr            = UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
>                  .flags          = UART_CAP_FIFO | UART_CAP_AFE,
>          },
>
> now PORT_NS16550A is defined as 14 in serial_core.h:
>
> #define PORT_NS16550A   14
>
> and PORT_U6_16550A is defined as 14 in serial.h:
>
> 235dae5d (Philippe Langlais 2010-07-29 17:13:57 +0200  80) #define PORT_U6_16550A       14
>
> I guess that might subtly break NS16550A users?
>
> My assumption is that Philippe's addition should actually
> be to the serial_core.h list which currently goes upto 18.
>
> However, that leaves the question of why is there a set of nearly
> but not quite idential defines in serial.h and serial_core.h?
>
> (please leave me on cc for replies)
>
> Dave
>    

      reply	other threads:[~2010-08-31 11:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-27 19:35 serial.h v serial_core.h PORT_ defines? Dr. David Alan Gilbert
2010-08-31 11:55 ` Philippe Langlais [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=4C7CEDC0.50600@stericsson.com \
    --to=philippe.langlais@stericsson.com \
    --cc=linux-serial@vger.kernel.org \
    --cc=linux@treblig.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