ASoC: davinci: Kill BUG_ON() usage
commit befff4fbc27e19b14b343eb4a65d8f75d38b6230 upstream Don't use BUG_ON() for a non-critical sanity check on production systems. This patch replaces with a softer WARN_ON() and an error path. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
6a65aa55cb
commit
d74abcff60
@ -1748,7 +1748,8 @@ static int davinci_mcasp_get_dma_type(struct davinci_mcasp *mcasp)
|
||||
PTR_ERR(chan));
|
||||
return PTR_ERR(chan);
|
||||
}
|
||||
BUG_ON(!chan->device || !chan->device->dev);
|
||||
if (WARN_ON(!chan->device || !chan->device->dev))
|
||||
return -EINVAL;
|
||||
|
||||
if (chan->device->dev->of_node)
|
||||
ret = of_property_read_string(chan->device->dev->of_node,
|
||||
|
Loading…
x
Reference in New Issue
Block a user