1. 03 Jun, 2019 1 commit
  2. 30 May, 2019 8 commits
  3. 29 May, 2019 5 commits
    • Tzung-Bi Shih's avatar
      ASoC: core: use component driver name as component name · b19671d6
      Tzung-Bi Shih authored
      fmt_single_name() uses device name to determine component name.  If
      multiple components bind to the same device, the debugfs creation in
      soc_init_component_debugfs() would fail due to duplicated entity
      names.
      
      Name provided by component driver is unique enough to represent each
      component.  Use component driver name as the component name to avoid
      name duplication.
      Signed-off-by: default avatarTzung-Bi Shih <tzungbi@google.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      b19671d6
    • Shengjiu Wang's avatar
      ASoC: cs42xx8: Fix build error with CONFIG_GPIOLIB is not set · 7cda6223
      Shengjiu Wang authored
      config: x86_64-randconfig-x000201921-201921
      compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
      reproduce:
              make ARCH=x86_64
      
      sound/soc/codecs/cs42xx8.c: In function ‘cs42xx8_probe’:
      sound/soc/codecs/cs42xx8.c:472:25: error: implicit declaration of function ‘devm_gpiod_get_optional’; did you mean ‘devm_clk_get_optional’? [-Werror=implicit-function-declaration]
        cs42xx8->gpiod_reset = devm_gpiod_get_optional(dev, "reset",
                               ^~~~~~~~~~~~~~~~~~~~~~~
                               devm_clk_get_optional
      sound/soc/codecs/cs42xx8.c:473:8: error: ‘GPIOD_OUT_HIGH’ undeclared (first use in this function); did you mean ‘GPIOF_INIT_HIGH’?
              GPIOD_OUT_HIGH);
              ^~~~~~~~~~~~~~
              GPIOF_INIT_HIGH
      sound/soc/codecs/cs42xx8.c:473:8: note: each undeclared identifier is reported only once for each function it appears in
      sound/soc/codecs/cs42xx8.c:477:2: error: implicit declaration of function ‘gpiod_set_value_cansleep’; did you mean ‘gpio_set_value_cansleep’? [-Werror=implicit-function-declaration]
        gpiod_set_value_cansleep(cs42xx8->gpiod_reset, 0);
        ^~~~~~~~~~~~~~~~~~~~~~~~
        gpio_set_value_cansleep
      
      Fixes: bfe95dfa ("ASoC: cs42xx8: Add reset gpio handling")
      Reported-by: default avatarkbuild test robot <lkp@intel.com>
      Signed-off-by: default avatarShengjiu Wang <shengjiu.wang@nxp.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      7cda6223
    • Pierre-Louis Bossart's avatar
      ASoC: Intel: sof-rt5682: fix undefined references with Baytrail-only support · 17fc2487
      Pierre-Louis Bossart authored
      The sof-rt5682 machine driver supports both legacy Baytrail devices
      and more recent ApolloLake/CometLake platforms. When only Baytrail is
      selected, the compilation fails with the following errors:
      
      ERROR: "hdac_hdmi_jack_port_init"
      [sound/soc/intel/boards/snd-soc-sof_rt5682.ko] undefined!
      
      ERROR: "hdac_hdmi_jack_init"
      [sound/soc/intel/boards/snd-soc-sof_rt5682.ko] undefined!
      
      Fix by selecting SND_SOC_HDAC_HDMI unconditionally. The code for HDMI
      support is not reachable on Baytrail so this change has no functional
      impact.
      
      Fixes: f70abd75 ("ASoC: Intel: add sof-rt5682 machine driver")
      Reported-by: default avatarkbuild test robot <lkp@intel.com>
      Signed-off-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      17fc2487
    • Gen Zhang's avatar
      wcd9335: fix a incorrect use of kstrndup() · a5498811
      Gen Zhang authored
      In wcd9335_codec_enable_dec(), 'widget_name' is allocated by kstrndup().
      However, according to doc: "Note: Use kmemdup_nul() instead if the size
      is known exactly." So we should use kmemdup_nul() here instead of
      kstrndup().
      Signed-off-by: default avatarGen Zhang <blackgod016574@gmail.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      a5498811
    • Georgii Staroselskii's avatar
      ASoC: sun4i-codec: fix first delay on Speaker · 1f2675f6
      Georgii Staroselskii authored
      Allwinner DAC seems to have a delay in the Speaker audio routing. When
      playing a sound for the first time, the sound gets chopped. On a second
      play the sound is played correctly. After some time (~5s) the issue gets
      back.
      
      This commit seems to be fixing the same issue as bf14da7e but
      for another codepath.
      
      This is the DTS that was used to debug the problem.
      
      &codec {
              allwinner,pa-gpios = <&r_pio 0 11 GPIO_ACTIVE_HIGH>; /* PL11 */
              allwinner,audio-routing =
                      "Speaker", "LINEOUT";
      
              status = "okay";
      }
      Signed-off-by: default avatarGeorgii Staroselskii <georgii.staroselskii@emlid.com>
      Reviewed-by: default avatarChen-Yu Tsai <wens@csie.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      1f2675f6
  4. 28 May, 2019 23 commits
  5. 24 May, 2019 3 commits
    • Ranjani Sridharan's avatar
      ASoC: core: lock client_mutex while removing link components · 34ac3c3e
      Ranjani Sridharan authored
      Removing link components results in topology unloading. So,
      acquire the client_mutex before removing components in
      soc_remove_link_components. This will prevent the lockdep warning
      seen when dai links are removed during topology removal.
      Signed-off-by: default avatarRanjani Sridharan <ranjani.sridharan@linux.intel.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      34ac3c3e
    • Jon Hunter's avatar
      ASoC: simple-card: Restore original configuration of DAI format · 4819d062
      Jon Hunter authored
      Revert commit 069d037a ("ASoC: simple-card: Fix configuration of
      DAI format"). During further review, it turns out that the actual issue
      was caused by an incorrectly formatted device-tree node describing the
      soundcard.
      
      The following is incorrect because the simple-audio-card
      'bitclock-master' and 'frame-master' properties should not reference the
      actual codec phandle ...
      
      	sound {
      		compatible = "simple-audio-card";
      		...
      	=>	simple-audio-card,bitclock-master = <&codec>;
      	=>	simple-audio-card,frame-master = <&codec>;
      		...
      
      		simple-audio-card,cpu {
      			sound-dai = <&xxx>;
      		};
      
      		simple-audio-card,codec {
      	=>		sound-dai = <&codec>;
      		};
      	};
      
      Rather, these properties should reference the phandle to the
      'simple-audio-card,codec' property as shown below ...
      
      	sound {
      		compatible = "simple-audio-card";
      		...
      	=>	simple-audio-card,bitclock-master = <&codec>;
      	=>	simple-audio-card,frame-master = <&codec>;
      		...
      
      		simple-audio-card,cpu {
      			sound-dai = <&xxx>;
      		};
      
      	=>	codec: simple-audio-card,codec { /* simple-card wants here */
      			sound-dai = <&xxx>;	 /* not here */
      		};
      	};
      Signed-off-by: default avatarJon Hunter <jonathanh@nvidia.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      4819d062
    • Gustavo A. R. Silva's avatar
      ASoC: qdsp6: q6core: Use struct_size() in kmemdup() · e718a3eb
      Gustavo A. R. Silva authored
      Make use of the struct_size() helper instead of an open-coded version
      in order to avoid any potential type mistakes, in particular in the
      context in which this code is being used.
      
      So, replace code of the following form:
      
      sizeof(*fwk) + fwk->num_services * sizeof(fwk->svc_api_info[0]);
      
      with:
      
      struct_size(fwk, svc_api_info, fwk->num_services)
      
      and so on...
      
      Notice that variables bytes and len are unnecessary, hence they are
      removed.
      
      This code was detected with the help of Coccinelle.
      Signed-off-by: default avatarGustavo A. R. Silva <gustavo@embeddedor.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      e718a3eb