lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 26 Jul 2019 09:02:30 -0500
From:   Pierre-Louis Bossart <pierre-louis.bossart@...ux.intel.com>
To:     Cezary Rojewski <cezary.rojewski@...el.com>
Cc:     alsa-devel@...a-project.org, linux-kernel@...r.kernel.org,
        tiwai@...e.de, broonie@...nel.org, vkoul@...nel.org,
        gregkh@...uxfoundation.org, jank@...ence.com,
        srinivas.kandagatla@...aro.org, slawomir.blauciak@...el.com,
        Sanyog Kale <sanyog.r.kale@...el.com>
Subject: Re: [alsa-devel] [RFC PATCH 06/40] soundwire: intel: prevent possible
 dereference in hw_params


>> diff --git a/drivers/soundwire/intel.c b/drivers/soundwire/intel.c
>> index 68832e613b1e..497879dd9c0d 100644
>> --- a/drivers/soundwire/intel.c
>> +++ b/drivers/soundwire/intel.c
>> @@ -509,7 +509,7 @@ static int intel_config_stream(struct sdw_intel *sdw,
>>                      struct snd_soc_dai *dai,
>>                      struct snd_pcm_hw_params *hw_params, int link_id)
>>   {
>> -    if (sdw->res->ops && sdw->res->ops->config_stream)
>> +    if (sdw->res->ops && sdw->res->ops->config_stream && sdw->res->arg)
>>           return sdw->res->ops->config_stream(sdw->res->arg,
>>                   substream, dai, hw_params, link_id);
>>
> 
> Hmm, declaring local for sdw->res should prove useful here after 
> addition of 4th sdw->res dereference.

yes, it's an eyesore. I added this to quickly fix a kernel oops while 
debugging, will simplify. thanks for the note.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ