19 Dec, 2011

1 commit

  • module_param(bool) used to counter-intuitively take an int. In
    fddd5201 (mid-2009) we allowed bool or int/unsigned int using a messy
    trick.

    It's time to remove the int/unsigned int option. For this version
    it'll simply give a warning, but it'll break next kernel version.

    Signed-off-by: Rusty Russell
    Signed-off-by: Takashi Iwai

    Rusty Russell
     

01 Nov, 2011

2 commits


10 Jun, 2011

2 commits

  • The name argument of request_irq() appears in /proc/interrupts, and
    it's quite ugly when the name entry contains a space or special letters.
    In general, it's simpler and more readable when the module name appears
    there, so let's replace all entries with KBUILD_MODNAME.

    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • The convention for pci_driver.name entry in kernel drivers seem to be
    the module name or equivalent ones. But, so far, almost all PCI sound
    drivers use more verbose name like "ABC Xyz (12)", and these are fairly
    confusing when appearing as a file name.

    This patch converts the all pci_driver.name entries in sound/pci/* to
    use KBUILD_MODNAME for more unified appearance.

    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

31 Mar, 2011

1 commit


09 Feb, 2010

1 commit


07 Apr, 2009

1 commit


24 Mar, 2009

3 commits


20 Feb, 2009

1 commit

  • The usage and comments make it clear values of 1/0 were intended
    rather than -1/0

    Noticed by sparse:
    sound/pci/pcxhr/pcxhr.h:100:20: error: dubious one-bit signed bitfield
    sound/pci/pcxhr/pcxhr.h:101:22: error: dubious one-bit signed bitfield
    sound/pci/pcxhr/pcxhr.h:102:24: error: dubious one-bit signed bitfield
    sound/pci/pcxhr/pcxhr.h:103:21: error: dubious one-bit signed bitfield
    sound/pci/pcxhr/pcxhr.h:104:25: error: dubious one-bit signed bitfield
    sound/pci/pcxhr/pcxhr.h:105:20: error: dubious one-bit signed bitfield

    Signed-off-by: Harvey Harrison
    Signed-off-by: Takashi Iwai

    Harvey Harrison
     

05 Feb, 2009

1 commit


01 Feb, 2009

1 commit


23 Jan, 2009

1 commit


12 Jan, 2009

1 commit


25 Dec, 2008

2 commits


21 Dec, 2008

1 commit


18 Dec, 2008

1 commit


01 Dec, 2008

1 commit


27 Nov, 2008

1 commit

  • The function snd_mixart_create creates a link between mgr and card that
    allows snd_mixart_free to free card as well. But if snd_mixart_create
    fails, then the link has not been created and card has to be freed explicitly.

    The semantic match that finds the problem is as follows:
    (http://www.emn.fr/x-info/coccinelle/)

    //
    @r exists@
    local idexpression x;
    statement S,S1;
    position p1,p2,p3;
    expression E,E1;
    type T,T1;
    expression *ptr != NULL;
    @@

    (
    if ((x@p1 = snd_card_new(...)) == NULL) S
    |
    x@p1 = snd_card_new(...);
    )
    ... when != snd_card_free(...,(T)x,...)
    when != if (...) { }
    when != true x == NULL || ...
    when != x = E
    when != E = (T)x
    when any
    (
    if (x == NULL || ...) S1
    |
    if@p2 (...) {
    ... when != snd_card_free(...,(T1)x,...)
    when != if (...) { }
    when != x = E1
    when != E1 = (T1)x
    (
    return \(0\|\|ptr\);
    |
    return@p3 ...;
    )
    }
    )

    @ script:python @
    p1 << r.p1;
    p3 << r.p3;
    @@

    print "* file: %s snd_card_new: %s return: %s" % (p1[0].file,p1[0].line,p3[0].line)

    //

    Signed-off-by: Julia Lawall
    Signed-off-by: Takashi Iwai

    Julia Lawall
     

25 Nov, 2008

4 commits


16 Nov, 2008

1 commit

  • Error handling code following a kzalloc should free the allocated data.
    The error handling code is adjusted to call pci_disable_device(pci); as
    well, as done later in the function

    The semantic match that finds the problem is as follows:
    (http://www.emn.fr/x-info/coccinelle/)

    //
    @r exists@
    local idexpression x;
    statement S;
    expression E;
    identifier f,l;
    position p1,p2;
    expression *ptr != NULL;
    @@

    (
    if ((x@p1 = \(kmalloc\|kzalloc\|kcalloc\)(...)) == NULL) S
    |
    x@p1 = \(kmalloc\|kzalloc\|kcalloc\)(...);
    ...
    if (x == NULL) S
    )
    }
    x->f = E
    ...>
    (
    return \(0\|\|ptr\);
    |
    return@p2 ...;
    )

    @script:python@
    p1 << r.p1;
    p2 << r.p2;
    @@

    print "* file: %s kmalloc %s return %s" % (p1[0].file,p1[0].line,p2[0].line)
    //

    Signed-off-by: Julia Lawall
    Signed-off-by: Takashi Iwai

    Julia Lawall
     

13 Aug, 2008

1 commit


15 Jul, 2008

1 commit


10 Jul, 2008

2 commits


27 May, 2008

1 commit


24 Apr, 2008

4 commits

  • sparc64:

    sound/pci/pcxhr/pcxhr.c: In function `pcxhr_update_r_buffer':
    sound/pci/pcxhr/pcxhr.c:459: warning: cast to pointer from integer of different size
    sound/pci/pcxhr/pcxhr.c: In function `pcxhr_trigger_tasklet':
    sound/pci/pcxhr/pcxhr.c:628: warning: long int format, different type arg (arg 4)

    Signed-off-by: Andrew Morton
    Signed-off-by: Takashi Iwai

    Andrew Morton
     
  • sound/pci/pcxhr/pcxhr_core.c: In function `pcxhr_set_pipe_state':
    sound/pci/pcxhr/pcxhr_core.c:899: warning: long int format, different type arg (arg 4)

    suseconds_t is int on sparc64.

    Signed-off-by: Andrew Morton
    Signed-off-by: Takashi Iwai

    Andrew Morton
     
  • The variable is_capture is initialized but never used otherwise.

    The semantic patch that makes this change is as follows:
    (http://www.emn.fr/x-info/coccinelle/)

    //
    @@
    type T;
    identifier i;
    constant C;
    @@

    (
    extern T i;
    |
    - T i;

    )
    //

    Signed-off-by: Julia Lawall
    Signed-off-by: Takashi Iwai

    Julia Lawall
     
  • Inner loop redeclares err with u32 rather than int, stupid fix here
    is to change the inner err to err2.
    sound/pci/pcxhr/pcxhr_core.c:1008:8: warning: symbol 'err' shadows an earlier one
    sound/pci/pcxhr/pcxhr_core.c:983:6: originally declared here

    Signed-off-by: Harvey Harrison
    Signed-off-by: Takashi Iwai

    Harvey Harrison
     

01 Feb, 2008

2 commits

  • This header file exists only for some hacks to adapt alsa-driver
    tree. It's useless for building in the kernel. Let's move a few
    lines in it to sound/core.h and remove it.
    With this patch, sound/driver.h isn't removed but has just a single
    compile warning to include it. This should be really killed in
    future.

    Signed-off-by: Takashi Iwai
    Signed-off-by: Jaroslav Kysela

    Takashi Iwai
     
  • Check the value ranges in ctl put callbacks properly in the rest of
    PCI drivers.

    Signed-off-by: Takashi Iwai
    Signed-off-by: Jaroslav Kysela

    Takashi Iwai
     

16 Oct, 2007

2 commits