lkml.org 
[lkml]   [2006]   [Apr]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [linuxsh-dev] [PATCH] ALSA driver for Yamaa AICA on Sega Dreamcast
From
Date

>
> > + /* AICA has no capture ability */
> > + if ((err =
> > + snd_pcm_new(dreamcastcard->card, "AICA PCM", pcm_index, 1, 0,
> > + &pcm)) < 0)
> > + return err;
>
> Weird notation, linux kernel style would be:
>
> err = snc_pcm_new(...);
> if (unlikely(err < 0))
> return err;
>
> please refactor accordingly.
>

Actually this sort of formulation is common in the kernel as any grep
will show. In fact I copied it directly from the guide to writing ALSA
drivers:

http://www.alsa-project.org/~iwai/writing-an-alsa-driver/x447.htm

But I am happy to change it.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-04-17 22:03    [W:0.045 / U:1.440 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site