20 Jul, 2020

1 commit

  • Follow the recent inclusive terminology guidelines and replace the
    word "slave" in vmaster API. I chose the word "follower" at this time
    since it seems fitting for the purpose.

    Note that the word "master" is kept in API, since it refers rather to
    audio master volume control.

    Also, while we're at it, a typo in comments is corrected, too.

    Link: https://lore.kernel.org/r/20200717154517.27599-1-tiwai@suse.de
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

15 Jul, 2020

1 commit

  • Follow the recent inclusive terminology guidelines and replace the
    words "whitelist" and "blacklist" appropriately.

    Only comment or function/variable renames, no functional changes.

    Link: https://lore.kernel.org/r/20200714172631.25371-3-tiwai@suse.de
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

09 Jul, 2020

1 commit

  • Replace the existing /* fall through */ comments and its variants with
    the new pseudo-keyword macro fallthrough[1]. Also, remove unnecessary
    fall-through markings when it is the case.

    [1] https://www.kernel.org/doc/html/latest/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through

    Signed-off-by: Gustavo A. R. Silva
    Link: https://lore.kernel.org/r/20200708203236.GA5112@embeddedor
    Signed-off-by: Takashi Iwai

    Gustavo A. R. Silva
     

17 Apr, 2020

1 commit


05 Jan, 2020

1 commit

  • Apply const prefix to each possible place: the static tables for
    registers and bits, the quirk tables, etc.

    Just for minor optimization and no functional changes.

    Link: https://lore.kernel.org/r/20200105144823.29547-11-tiwai@suse.de
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

03 Jan, 2020

3 commits

  • One snd_ac97_res_table definition remains forgotten without const.
    Let's add it for a bit of optimization.

    There should be no functional changes by this patch.

    Link: https://lore.kernel.org/r/20200103081714.9560-46-tiwai@suse.de
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • This is a preliminary patch to allow const for snd_ac97_bus_ops
    definitions in each driver's code. The ops reference is read-only,
    hence it can be declared as const for further optimization.

    There should be no functional changes by this patch.

    Link: https://lore.kernel.org/r/20200103081714.9560-23-tiwai@suse.de
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     
  • Now we may declare const for snd_device_ops definitions, so let's do
    it for optimization.

    There should be no functional changes by this patch.

    Link: https://lore.kernel.org/r/20200103081714.9560-10-tiwai@suse.de
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

09 Aug, 2019

1 commit


31 May, 2019

1 commit

  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version this program is distributed in the
    hope that it will be useful but without any warranty without even
    the implied warranty of merchantability or fitness for a particular
    purpose see the gnu general public license for more details you
    should have received a copy of the gnu general public license along
    with this program if not write to the free software foundation inc
    59 temple place suite 330 boston ma 02111 1307 usa

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 1334 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Reviewed-by: Richard Fontana
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190527070033.113240726@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

21 May, 2019

1 commit


07 Feb, 2019

1 commit

  • The calls of snd_info_register() are superfluous and should be avoided
    at the procfs creation time. They are called at the end of the whole
    initialization via snd_card_register(). This patch drops such
    superfluous calls, as well as dropping the superfluous setup of
    SNDRV_INFO_CONTENT_TEXT.

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

    Takashi Iwai
     

24 Nov, 2018

1 commit

  • The function snd_ac97_put_spsa() gets the bit shift value from the
    associated private_value, but it extracts too much; the current code
    extracts 8 bit values in bits 8-15, but this is a combination of two
    nibbles (bits 8-11 and bits 12-15) for left and right shifts.
    Due to the incorrect bits extraction, the actual shift may go beyond
    the 32bit value, as spotted recently by UBSAN check:
    UBSAN: Undefined behaviour in sound/pci/ac97/ac97_codec.c:836:7
    shift exponent 68 is too large for 32-bit type 'int'

    This patch fixes the shift value extraction by masking the properly
    with 0x0f instead of 0xff.

    Reported-and-tested-by: Meelis Roos
    Cc:
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

03 Aug, 2018

1 commit

  • For a sake of code simplification, remove the init and the exit
    entries that do nothing.

    Notes for readers: actually it's OK to remove *both* init and exit,
    but not OK to remove the exit entry. By removing only the exit while
    keeping init, the module becomes permanently loaded; i.e. you cannot
    unload it any longer!

    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

28 May, 2018

1 commit

  • Convert the S_ symbolic permissions to their octal equivalents as
    using octal and not symbolic permissions is preferred by many as more
    readable.

    see: https://lkml.org/lkml/2016/8/2/1945

    Done with automated conversion via:
    $ ./scripts/checkpatch.pl -f --types=SYMBOLIC_PERMS --fix-inplace

    Miscellanea:

    o Wrapped one multi-line call to a single line

    Signed-off-by: Joe Perches
    Acked-by: Vinod Koul
    Signed-off-by: Takashi Iwai

    Joe Perches
     

28 Feb, 2017

1 commit

  • Fix typos and add the following to the scripts/spelling.txt:

    swith||switch
    swithable||switchable
    swithed||switched
    swithing||switching

    While we are here, fix the "update" to "updates" in the touched hunk in
    drivers/net/wireless/marvell/mwifiex/wmm.c.

    Link: http://lkml.kernel.org/r/1481573103-11329-2-git-send-email-yamada.masahiro@socionext.com
    Signed-off-by: Masahiro Yamada
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Masahiro Yamada
     

15 Nov, 2016

1 commit

  • Sphinx takes a word like (*foo)->bar in the kernel-doc comments as a
    part of the emphasized marker, and complains like

    ./sound/pci/ac97/ac97_codec.c:1908: WARNING: Inline emphasis start-string without end-string.

    For avoiding this, wrap it with the quotes (``) in the comment.

    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

29 May, 2015

1 commit


05 Apr, 2015

1 commit


07 Mar, 2015

2 commits


21 Oct, 2014

2 commits


26 Feb, 2014

1 commit


30 Sep, 2013

1 commit


28 Jun, 2013

1 commit


12 Mar, 2013

1 commit

  • script/kernel-doc reports the following type of warnings (when run in verbose
    mode):

    Warning(sound/core/init.c:152): No description found for return value of
    'snd_card_create'

    To fix that:
    - add missing descriptions of function return values
    - use "Return:" sections to describe those return values

    Along the way:
    - complete some descriptions
    - fix some typos

    Signed-off-by: Yacine Belkadi
    Signed-off-by: Takashi Iwai

    Yacine Belkadi
     

15 Oct, 2012

1 commit


07 Sep, 2012

1 commit

  • ALC650 has a channel swap option between surround and CLFE channels,
    so we need to tweak the channel maps dynamically depending on the
    register bit.

    Now struct snd_ac97 can contain chmap pointers for playback and
    capture. The driver may store these and let ac97 driver changing the
    channel mapping dynamically.

    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

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


15 Aug, 2011

1 commit


19 Feb, 2011

1 commit


18 Feb, 2011

1 commit


15 Jan, 2011

1 commit


13 Dec, 2010

1 commit

  • flush_scheduled_work() is deprecated and scheduled to be removed.

    * cancel[_delayed]_work() + flush_scheduled_work() ->
    cancel[_delayed]_work_sync().

    * wm8350, wm8753 and soc-core use custom code to cancel a delayed
    work, execute it immediately if it was pending and wait for its
    completion. This is equivalent to flush_delayed_work_sync(). Use
    it instead.

    Signed-off-by: Tejun Heo
    Acked-by: Mark Brown
    Signed-off-by: Takashi Iwai

    Tejun Heo
     

30 Mar, 2010

1 commit

  • …it slab.h inclusion from percpu.h

    percpu.h is included by sched.h and module.h and thus ends up being
    included when building most .c files. percpu.h includes slab.h which
    in turn includes gfp.h making everything defined by the two files
    universally available and complicating inclusion dependencies.

    percpu.h -> slab.h dependency is about to be removed. Prepare for
    this change by updating users of gfp and slab facilities include those
    headers directly instead of assuming availability. As this conversion
    needs to touch large number of source files, the following script is
    used as the basis of conversion.

    http://userweb.kernel.org/~tj/misc/slabh-sweep.py

    The script does the followings.

    * Scan files for gfp and slab usages and update includes such that
    only the necessary includes are there. ie. if only gfp is used,
    gfp.h, if slab is used, slab.h.

    * When the script inserts a new include, it looks at the include
    blocks and try to put the new include such that its order conforms
    to its surrounding. It's put in the include block which contains
    core kernel includes, in the same order that the rest are ordered -
    alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
    doesn't seem to be any matching order.

    * If the script can't find a place to put a new include (mostly
    because the file doesn't have fitting include block), it prints out
    an error message indicating which .h file needs to be added to the
    file.

    The conversion was done in the following steps.

    1. The initial automatic conversion of all .c files updated slightly
    over 4000 files, deleting around 700 includes and adding ~480 gfp.h
    and ~3000 slab.h inclusions. The script emitted errors for ~400
    files.

    2. Each error was manually checked. Some didn't need the inclusion,
    some needed manual addition while adding it to implementation .h or
    embedding .c file was more appropriate for others. This step added
    inclusions to around 150 files.

    3. The script was run again and the output was compared to the edits
    from #2 to make sure no file was left behind.

    4. Several build tests were done and a couple of problems were fixed.
    e.g. lib/decompress_*.c used malloc/free() wrappers around slab
    APIs requiring slab.h to be added manually.

    5. The script was run on all .h files but without automatically
    editing them as sprinkling gfp.h and slab.h inclusions around .h
    files could easily lead to inclusion dependency hell. Most gfp.h
    inclusion directives were ignored as stuff from gfp.h was usually
    wildly available and often used in preprocessor macros. Each
    slab.h inclusion directive was examined and added manually as
    necessary.

    6. percpu.h was updated not to include slab.h.

    7. Build test were done on the following configurations and failures
    were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my
    distributed build env didn't work with gcov compiles) and a few
    more options had to be turned off depending on archs to make things
    build (like ipr on powerpc/64 which failed due to missing writeq).

    * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
    * powerpc and powerpc64 SMP allmodconfig
    * sparc and sparc64 SMP allmodconfig
    * ia64 SMP allmodconfig
    * s390 SMP allmodconfig
    * alpha SMP allmodconfig
    * um on x86_64 SMP allmodconfig

    8. percpu.h modifications were reverted so that it could be applied as
    a separate patch and serve as bisection point.

    Given the fact that I had only a couple of failures from tests on step
    6, I'm fairly confident about the coverage of this conversion patch.
    If there is a breakage, it's likely to be something in one of the arch
    headers which should be easily discoverable easily on most builds of
    the specific arch.

    Signed-off-by: Tejun Heo <tj@kernel.org>
    Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
    Cc: Ingo Molnar <mingo@redhat.com>
    Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>

    Tejun Heo
     

29 Mar, 2010

1 commit

  • BugLink: https://launchpad.net/bugs/481058

    The OR has verified that both 'Headphone Jack Sense' and 'Line Jack Sense'
    need to be muted for sound to be audible, so just add the machine's SSID
    to the ac97 jack sense blacklist.

    Reported-by: Richard Gagne
    Tested-by: Richard Gagne
    Cc:
    Signed-off-by: Daniel T Chen
    Signed-off-by: Takashi Iwai

    Daniel Chen
     

26 Mar, 2010

1 commit