20 Jan, 2021

1 commit

  • commit 3e096a2112b7b407549020cf095e2a425f00fabb upstream.

    MIXART.txt has been converted to ReST and renamed. Fix the reference
    in alsa-configuration.rst.

    Fixes: 3d8e81862ce4 ("ALSA: doc: ReSTize MIXART.txt")
    Signed-off-by: Jonathan Neuschäfer
    Cc:
    Link: https://lore.kernel.org/r/20210101221942.1068388-1-j.neuschaefer@gmx.net
    Signed-off-by: Takashi Iwai
    Signed-off-by: Greg Kroah-Hartman

    Jonathan Neuschäfer
     

15 Oct, 2020

4 commits

  • Some such markups are invalid, as reported by Sphinx:

    ./Documentation/sound/kernel-api/writing-an-alsa-driver.rst:3317: WARNING: Unparseable C cross-reference: 'snd_rawmidi_transmit*'
    Invalid C declaration: Expected end of definition. [error at 20]
    snd_rawmidi_transmit*
    --------------------^
    ./Documentation/sound/kernel-api/writing-an-alsa-driver.rst:3917: WARNING: Unparseable C cross-reference: 'copy_from/to_user'
    Invalid C declaration: Expected end of definition. [error at 9]
    copy_from/to_user
    ---------^

    The first case seems to be better replaced by a literal.

    For the second one, let's generate cross-references, by
    spliting it in two.

    Reviewed-by: Takashi Iwai
    Signed-off-by: Mauro Carvalho Chehab

    Mauro Carvalho Chehab
     
  • the :c:type shouldn't be used with structs with Sphinx 3,
    as the C domain there uses .. c:struct for structs.

    As we have the automarkup extension, let's just get rid of
    all :c:type as a whole, as those will be automagically
    marked as such.

    This solves a bunch of warnings with Sphinx 3, like those:

    .../Documentation/sound/kernel-api/writing-an-alsa-driver.rst:490: WARNING: Unparseable C cross-reference: 'calling snd_card_free'
    Invalid C declaration: Expected end of definition. [error at 8]
    calling snd_card_free
    --------^
    .../Documentation/sound/kernel-api/writing-an-alsa-driver.rst:3328: WARNING: Unparseable C cross-reference: 'snd_rawmidi_transmit*'
    Invalid C declaration: Expected end of definition. [error at 20]
    snd_rawmidi_transmit*
    --------------------^
    .../Documentation/sound/kernel-api/writing-an-alsa-driver.rst:3928: WARNING: Unparseable C cross-reference: 'copy_from/to_user'
    Invalid C declaration: Expected end of definition. [error at 9]
    copy_from/to_user
    ---------^

    Reviewed-by: Takashi Iwai
    Signed-off-by: Mauro Carvalho Chehab

    Mauro Carvalho Chehab
     
  • The sound API is documented on two different parts:
    under Documentation/driver-api/sound.rst and under
    Documentation/sound/kernel-api/alsa-driver-api.rst.

    The alsa-driver-api.rst seems more complete, and APIs
    are split per type. There's just one missing kernel-doc
    markup there.

    Add it and drop the duplicated one.

    Reviewed-by: Takashi Iwai
    Signed-off-by: Mauro Carvalho Chehab

    Mauro Carvalho Chehab
     
  • The :c:type:`foo` only works properly with structs before
    Sphinx 3.x.

    On Sphinx 3.x, structs should now be declared using the
    .. c:struct, and referenced via :c:struct tag.

    As we now have the automarkup.py macro, that automatically
    convert:
    struct foo

    into cross-references, let's get rid of that, solving
    several warnings when building docs with Sphinx 3.x.

    Reviewed-by: André Almeida # blk-mq.rst
    Reviewed-by: Takashi Iwai # sound
    Reviewed-by: Mike Rapoport
    Reviewed-by: Greg Kroah-Hartman
    Signed-off-by: Mauro Carvalho Chehab

    Mauro Carvalho Chehab
     

03 Sep, 2020

1 commit

  • We use HDaudio and HDAudio, pick one to make searches easier.
    No functionality change

    Also fix timestamping typo in documentation.

    Reported-by: Guennadi Liakhovetski
    Signed-off-by: Pierre-Louis Bossart
    Reviewed-by: Bard Liao
    Reviewed-by: Guennadi Liakhovetski
    Signed-off-by: Kai Vehmanen
    Link: https://lore.kernel.org/r/20200902154250.1440585-1-kai.vehmanen@linux.intel.com
    Signed-off-by: Takashi Iwai

    Pierre-Louis Bossart
     

24 Aug, 2020

1 commit

  • Fix documentation build warnings for underline length too short,
    caused by s/http/https/ and not changing the accompanying underlines.

    Documentation/sound/cards/audigy-mixer.rst:335: WARNING: Title underline too short.
    US Patents (https://www.uspto.gov/)
    ----------------------------------

    Documentation/sound/cards/sb-live-mixer.rst:340: WARNING: Title underline too short.
    US Patents (https://www.uspto.gov/)
    ----------------------------------

    Fixes: 7ed33ea6b4fa ("ALSA: Replace HTTP links with HTTPS ones")
    Signed-off-by: Randy Dunlap
    Cc: Alexander A. Klimov
    Link: https://lore.kernel.org/r/357ee576-32a2-6e2b-1db6-78be39253846@infradead.org
    Signed-off-by: Takashi Iwai

    Randy Dunlap
     

03 Aug, 2020

1 commit

  • …/sound into for-linus

    ASoC: Updates for v5.9

    The biggest changes here one again come from Mormioto-san who has
    continued his dilligent work cleaning up long standing issues in the
    APIs, it's particularly nice to see the transition from digital_mute()
    to mute_stream() finally completed. There's also been a lot of work on
    the x86 code again, this time a big focus has been on cleaning up some
    issues identified by various static tests, and on the Freescale systems.
    Otherwise the biggest thing has been a lot of driver additions:

    - Convert users of digital_mute() to mute_stream().
    - Simplify I/O helper functions.
    - Add a helper for getting the RTD from a substream.
    - Many, many fixes and cleanups to the x86 code.
    - New drivers for Freescale MQS and i.MX6sx, Intel KeemBay I2S, Maxim
    MAX98360A and MAX98373 Soundwire, several Mediatek boards, nVidia
    Tegra 186 and 210, RealTek RL6231, Samsung Midas and Aries boards (some
    of the first phones I worked on!) and TI J721e EVM.

    Takashi Iwai
     

01 Aug, 2020

2 commits


22 Jul, 2020

1 commit

  • Rationale:
    Reduces attack surface on kernel devs opening the links for MITM
    as HTTPS traffic is much harder to manipulate.

    Deterministic algorithm:
    For each file:
    If not .svg:
    For each line:
    If doesn't contain `\bxmlns\b`:
    For each link, `\bhttp://[^# \t\r\n]*(?:\w|/)`:
    If neither `\bgnu\.org/license`, nor `\bmozilla\.org/MPL\b`:
    If both the HTTP and HTTPS versions
    return 200 OK and serve the same content:
    Replace HTTP with HTTPS.

    Signed-off-by: Alexander A. Klimov
    Acked-by: Rob Herring
    Link: https://lore.kernel.org/r/20200719153822.59788-1-grandmaster@al2klimov.de
    Signed-off-by: Mark Brown

    Alexander A. Klimov
     

20 Jul, 2020

1 commit

  • Rationale:
    Reduces attack surface on kernel devs opening the links for MITM
    as HTTPS traffic is much harder to manipulate.

    Deterministic algorithm:
    For each file:
    If not .svg:
    For each line:
    If doesn't contain `\bxmlns\b`:
    For each link, `\bhttp://[^# \t\r\n]*(?:\w|/)`:
    If neither `\bgnu\.org/license`, nor `\bmozilla\.org/MPL\b`:
    If both the HTTP and HTTPS versions
    return 200 OK and serve the same content:
    Replace HTTP with HTTPS.

    Signed-off-by: Alexander A. Klimov
    Link: https://lore.kernel.org/r/20200719151705.59624-1-grandmaster@al2klimov.de
    Signed-off-by: Takashi Iwai

    Alexander A. Klimov
     

07 Jul, 2020

2 commits


30 Jun, 2020

1 commit

  • sound/soc/soc-io.c was merged into sound/soc/soc-component.c, so fixup
    the Documentation to use the updated file name.

    Error: Cannot open file ../sound/soc/soc-io.c
    WARNING: kernel-doc '../scripts/kernel-doc -rst -enable-lineno ../sound/soc/soc-io.c' failed with return code 1

    Fixes: 460b42d162e3 ("ASoC: soc-component: merge soc-io.c into soc-component.c")
    Signed-off-by: Randy Dunlap
    Acked-by: Kuninori Morimoto
    Cc: Kuninori Morimoto
    Cc: Mark Brown
    Link: https://lore.kernel.org/r/a9f59f30-8cf2-ea82-567c-1706fd64fe62@infradead.org
    Signed-off-by: Mark Brown

    Randy Dunlap
     

31 Mar, 2020

2 commits

  • patch_realtek.c has historically failed to properly configure the PC
    Beep Hidden Register for the ALC256 codec (among others). Depending on
    your kernel version, symptoms of this misconfiguration can range from
    chassis noise, picked up by a poorly-shielded PCBEEP trace, getting
    amplified and played on your internal speaker and/or headphones to loud
    feedback, which responds to the "Headphone Mic Boost" ALSA control,
    getting played through your headphones. For details of the problem, see
    the patch in this series titled "ALSA: hda/realtek - Set principled PC
    Beep configuration for ALC256", which fixes the configuration.

    These symptoms have been most noticed on the Dell XPS 13 9350 and 9360,
    popular laptops that use the ALC256. As a result, several model-specific
    fixups have been introduced to try and fix the problem, the most
    egregious of which locks the "Headphone Mic Boost" control as a hack to
    minimize noise from a feedback loop that shouldn't have been there in
    the first place.

    Now that the underlying issue has been fixed, remove all these fixups.
    Remaining fixups needed by the XPS 13 are all picked up by existing pin
    quirks.

    This change should, for the XPS 13 9350/9360

    - Significantly increase volume and audio quality on headphones
    - Eliminate headphone popping on suspend/resume
    - Allow "Headphone Mic Boost" to be set again, making the headphone
    jack fully usable as a microphone jack too.

    Fixes: 8c69729b4439 ("ALSA: hda - Fix headphone noise after Dell XPS 13 resume back from S3")
    Fixes: 423cd785619a ("ALSA: hda - Fix headphone noise on Dell XPS 13 9360")
    Fixes: e4c9fd10eb21 ("ALSA: hda - Apply headphone noise quirk for another Dell XPS 13 variant")
    Fixes: 1099f48457d0 ("ALSA: hda/realtek: Reduce the Headphone static noise on XPS 9350/9360")
    Cc: stable@vger.kernel.org
    Signed-off-by: Thomas Hebb
    Link: https://lore.kernel.org/r/b649a00edfde150cf6eebbb4390e15e0c2deb39a.1585584498.git.tommyhebb@gmail.com
    Signed-off-by: Takashi Iwai

    Thomas Hebb
     
  • This codec (among others) has a hidden set of audio routes, apparently
    designed to allow PC Beep output without a mixer widget on the output
    path, which are controlled by an undocumented Realtek vendor register.
    The default configuration of these routes means that certain inputs
    aren't accessible, necessitating driver control of the register.
    However, Realtek has provided no documentation of the register, instead
    opting to fix issues by providing magic numbers, most of which have been
    at least somewhat erroneous. These magic numbers then get copied by
    others into model-specific fixups, leading to a fragmented and buggy set
    of configurations.

    To get out of this situation, I've reverse engineered the register by
    flipping bits and observing how the codec's behavior changes. This
    commit documents my findings. It does not change any code.

    Cc: stable@vger.kernel.org
    Signed-off-by: Thomas Hebb
    Link: https://lore.kernel.org/r/bd69dfdeaf40ff31c4b7b797c829bb320031739c.1585584498.git.tommyhebb@gmail.com
    Signed-off-by: Takashi Iwai

    Thomas Hebb
     

30 Mar, 2020

1 commit

  • …/sound into for-linus

    ASoC: Updates for v5.7

    This is a very big update for the core since Morimoto-san has been
    rather busy continuing his refactorings to clean up a lot of the cruft
    that we have accumilated over the years. We've also gained several new
    drivers, including initial (but still not complete) parts of the Intel
    SoundWire support.

    - Lots of refactorings to modernize the code from Morimoto-san.
    - Conversion of SND_SOC_ALL_CODECS to use imply from Geert Uytterhoeven.
    - Continued refactoring and fixing of the Intel support.
    - Soundwire and more advanced clocking support for Realtek RT5682.
    - Support for amlogic GX, Meson 8, Meson 8B and T9015 DAC, Broadcom
    DSL/PON, Ingenic JZ4760 and JZ4770, Realtek RL6231, and TI TAS2563 and
    TLV320ADCX140.

    Takashi Iwai
     

26 Mar, 2020

1 commit


06 Mar, 2020

1 commit

  • Following the example in cb2cf0de1174 ("ASoC: soc-core: care Codec
    Codec case by non_legacy_dai_naming"), determine if a DAI link contains
    only codec DAIs by examining the non_legacy_dai_naming flag in each
    DAI's component.

    For now, we assume there is only one or a small set of valid PCM stream
    parameters, so num_params == 1 is good enough. We also assume that the
    same params are valid for all supported streams. params is set to the
    subset of parameters common among all DAIs, and then the existing code
    automatically chooses the highest quality of the remaining values when
    the link is brought up.

    Signed-off-by: Samuel Holland
    Link: https://lore.kernel.org/r/20200305051143.60691-4-samuel@sholland.org
    Signed-off-by: Mark Brown

    Samuel Holland
     

29 Jan, 2020

1 commit

  • Pull sound updates from Takashi Iwai:
    "As the diffstat shows we've had again a lot of works done for this
    cycle: the majority of changes are the continued componentization and
    code refactoring in ASoC, the tree-wide PCM API updates and cleanups
    and SOF updates while a few ASoC driver updates are seen, too.

    Here we go, some highlights:

    Core:
    - Finally y2038 support landed to ALSA ABI; some ioctls have been
    extended and lots of tricks were applied
    - Applying the new managed PCM buffer API to all drivers; the API
    itself was already merged in 5.5
    - The already deprecated dimension support in ALSA control API is
    dropped completely now
    - Verification of ALSA control elements to catch API misuses

    ASoC:
    - Further code refactorings and moving things to the component level
    - Lots of updates and improvements on SOF / Intel drivers; now
    including common HDMI driver and SoundWire support
    - New driver support for Ingenic JZ4770, Mediatek MT6660, Qualcomm
    WCD934x and WSA881x, and Realtek RT700, RT711, RT715, RT1011,
    RT1015 and RT1308

    HD-audio:
    - Improved ring-buffer communications using waitqueue
    - Drop the superfluous buffer preallocation on x86

    Others:
    - Many code cleanups, mostly constifications over the whole tree
    - USB-audio: quirks for MOTU, Corsair Virtuoso, Line6 Helix
    - FireWire: code refactoring for oxfw and dice drivers"

    * tag 'sound-5.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (638 commits)
    ALSA: usb-audio: add quirks for Line6 Helix devices fw>=2.82
    ALSA: hda: Add Clevo W65_67SB the power_save blacklist
    ASoC: soc-core: remove null_snd_soc_ops
    ASoC: soc-pcm: add soc_rtd_trigger()
    ASoC: soc-pcm: add soc_rtd_hw_free()
    ASoC: soc-pcm: add soc_rtd_hw_params()
    ASoC: soc-pcm: add soc_rtd_prepare()
    ASoC: soc-pcm: add soc_rtd_shutdown()
    ASoC: soc-pcm: add soc_rtd_startup()
    ASoC: rt1015: add rt1015 amplifier driver
    ASoC: madera: Correct some kernel doc
    ASoC: topology: fix soc_tplg_fe_link_create() - link->dobj initialization order
    ASoC: Intel: skl_hda_dsp_common: Fix global-out-of-bounds bug
    ASoC: madera: Correct DMIC only input hook ups
    ALSA: cs46xx: fix spelling mistake "to" -> "too"
    ALSA: hda - Add docking station support for Lenovo Thinkpad T420s
    ASoC: Add MediaTek MT6660 Speaker Amp Driver
    ASoC: dt-bindings: rt5645: add suppliers
    ASoC: max98090: fix deadlock in max98090_dapm_put_enum_double()
    ASoC: dapm: add snd_soc_dapm_put_enum_double_locked
    ...

    Linus Torvalds
     

06 Jan, 2020

1 commit


03 Jan, 2020

2 commits


17 Dec, 2019

1 commit

  • Patrick May reported that his sound card with CMI8378 chip causes a
    crash / reboot when accessing the MIDI port that isn't actually
    present on the board. Moreover, despite of the documentation,
    passing mpu_port=0 doesn't disable the MIDI port on this board.

    It implies that the chip is a newer revision and the MPU401 port is
    integrated and mapped on the PCI register. For this chip model, the
    driver enables the MPU port unconditionally, so far.

    Although fixing the unexpected reboot would be the best solution, it's
    not so trivial to identify the cause. So, as a plan B, this patch
    extends the existing mpu_port option usage to allow disabling the port
    by specifying the value 0, just like we applied for fm_port option in
    commit 2f24d159d5ac ("[ALSA] cmipci - Allow to disable integrated FM
    port"). As default, the MPU port is still enabled, but user can pass
    mpu_port=0 to disable it.

    Reported-and-tested-by: Patrick May
    Link: https://lore.kernel.org/r/20191217081448.1144-1-tiwai@suse.de
    Signed-off-by: Takashi Iwai

    Takashi Iwai
     

21 Nov, 2019

3 commits


06 Nov, 2019

3 commits


18 Sep, 2019

1 commit

  • Pull sound updates from Takashi Iwai:
    "As shown in diffstat and logs, it was again a busy development cycle
    at this time, too. The most significant changes are still on-going
    refactoring / modernization works for ASoC core and drivers, but there
    are lots of other changes as well. Here we go, some highlights below:

    ASoC:

    - Quite a lot of cleanup / refactoring of ASoC core and APIs; most of
    them are systematic, but also including cleanups and modernization

    - A bulk of updates for some ASoC platforms, Freescale, sunxi and
    Intel SST/SOF

    - Initial support for Sound Open Firmware on i.MX8

    - Removal of deprecated w90x900 and nuc900 drivers

    - New support for Cirrus Logic CS47L15 and CS47L92, Freescale i.MX
    7ULP and 8MQ, Meson G12A and NXP UDA1334

    USB-audio:

    - More validations of descriptor units for hardening against bugs
    reported by fuzzers

    - PCM device assignment workaround for a past call-order change

    - Scarlett Gen2 mixer interface, a few more more quirks

    HD-audio:

    - Support for audio component with AMD/ATI and Nvidia HDMI codecs

    - Clean up HD-audio core and remove indirect access ops for Intel SOF

    - DMIC detection at probe; it would make systems automatically
    falling back to SST/SOF driver on devices that need DMIC handling.
    Needs a new Kconfig to set, and beware that it's still new and a
    bit experimental

    FireWire:

    - Lots of code refactoring and cleanups"

    * tag 'sound-5.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (521 commits)
    ASoC: sdm845: remove unneeded semicolon
    ASoC: fsl_sai: Implement set_bclk_ratio
    ASoC: dmaengine: Replace strncpy() with strscpy_pad() for pcm->name
    ASoC: wcd9335: remove redundant use of ret variable
    ALSA: firewire-tascam: check intermediate state of clock status and retry
    ALSA: firewire-tascam: handle error code when getting current source of clock
    ASoC: hdmi-codec: Add an op to set callback function for plug event
    ASoC: rt5677: keep analog power register at SND_SOC_BIAS_OFF
    ASoC: rt5677: Remove magic number register writes
    ASoC: soc-core: self contained soc_unbind_aux_dev()
    ASoC: soc-core: add soc_unbind_aux_dev()
    ASoC: soc-core: self contained soc_bind_aux_dev()
    ASoC: soc-core: move soc_probe_link_dais() next to soc_remove_link_dais()
    ASoC: soc-core: self contained soc_probe_link_dais()
    ASoC: soc-core: add new soc_link_init()
    ASoC: soc-core: move soc_probe_dai() next to soc_remove_dai()
    ASoC: soc-core: self contained soc_remove_link_dais()
    ASoC: soc-core: self contained soc_remove_link_components()
    ASoC: soc-core: self contained soc_probe_link_components()
    ASoC: rt1308: make array pd static const, makes object smaller
    ...

    Linus Torvalds
     

10 Sep, 2019

1 commit

  • ASoC: Updates for v5.4

    Quite a big update this time around, particularly in the core
    where we've had a lot of cleanups from Morimoto-san - there's
    not much functional change but quite a bit of modernization
    going on. We've also seen a lot of driver work, a lot of it
    cleanups but also some particular drivers.

    - Lots and lots of cleanups from Morimoto-san and Yue Haibing.
    - Lots of cleanups and enhancements to the Freescale, sunxi dnd
    Intel rivers.
    - Initial Sound Open Firmware suppot for i.MX8.
    - Removal of w90x900 and nuc900 drivers as the platforms are
    being removed.
    - New support for Cirrus Logic CS47L15 and CS47L92, Freescale
    i.MX 7ULP and 8MQ, Meson G12A and NXP UDA1334

    Takashi Iwai
     

28 Aug, 2019

1 commit


09 Aug, 2019

1 commit

  • [ This is rather a revival of the patch Tomas sent in months ago, but
    applying only with the quirk model option -- tiwai ]

    Hard coded coefficients to make Huawuei Matebook X right speaker
    work. The Matebook X has a ALC298, please refer to bug 197801 on
    how these numbers were reverse engineered from the Windows driver

    The reversed engineered sequence represents a repeating pattern
    of verbs, and the only values that are changing periodically are
    written on indexes 0x23 and 0x25:

    0x500, 0x23
    0x400, VALUE1
    0x500, 0x25
    0x400, VALUE2

    * skipped reading sequences (0x500 - 0xc00 sequences are ignored)
    * static values from reverse engineering are used

    NOTE: since a significant risk is still considered, this is provided
    as an experimental fix that isn't applied as default for now. For
    enabling the fix, you'll have to choose huawei-mbx-stereo via model
    option of snd-hda-intel module.

    If we get feedback from users that this works stably, we may apply it
    per default.

    [ Some coding style fixes and replacement with AC_VERB_* by tiwai ]

    BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=197801
    Signed-off-by: Tomas Espeleta
    Signed-off-by: Takashi Iwai

    Tomas Espeleta
     

01 Aug, 2019

1 commit


17 Jul, 2019

1 commit


03 Apr, 2019

1 commit


28 Feb, 2019

1 commit

  • …ie/sound into for-next

    ASoC: More changes for v5.1

    Another batch of changes for ASoC, no big core changes - it's mainly
    small fixes and improvements for individual drivers.

    - A big refresh and cleanup of the Samsung drivers, fixing a number of
    issues which allow the driver to be used with a wider range of
    userspaces.
    - Fixes for the Intel drivers to make them more standard so less likely
    to get bitten by core issues.
    - New driver for Cirrus Logic CS35L26.

    Takashi Iwai
     

20 Feb, 2019

1 commit