lkml.org 
[lkml]   [2009]   [Jun]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 8/8] imx: serial: add IrDA support to serial driver
On Tue, Jun 09, 2009 at 18:07:38 +0100, Alan Cox wrote:
> > Sure, the path will be optimized away, but still
> > the conditional statement is subjected to syntax
> > and scope analysis and gcc will correctly complain
> > that irda_inv_rx is not declared.
>
> Why are only about half of them done this way rather than all ?

Because only half of them use IrDA specific struct fields
directly, thus need to be ifdef'd explicitely.

Like I wrote before, we could replace all the

if (USE_IRDA(x)) ...

with some

#ifdef CONFIG_IRDA
if (x->use_irda) ...

but that way we would have more ifdef's around.
A matter of taste, I'ld say. If you vote for the
latter, we can adjust the patch accordingly, of
course.

Oskar


\
 
 \ /
  Last update: 2009-06-09 20:07    [W:0.075 / U:0.520 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site