From 08d3631c44da53bc101b299c7fd849f3dfee3ca1 Mon Sep 17 00:00:00 2001 From: Xun Zhang Date: Tue, 18 Jun 2019 15:17:18 +0800 Subject: [PATCH] ASoC: Intel: sof-rt5682: fix kernel memory allocation flag In "sof_audio_probe", we should use GFP_KERNEL instead of GFP_ATOMIC for memory allocation because the device can sleep. Signed-off-by: Xun Zhang --- sound/soc/intel/boards/sof_rt5682.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/intel/boards/sof_rt5682.c b/sound/soc/intel/boards/sof_rt5682.c index 64db00353e18..daeaa396d928 100644 --- a/sound/soc/intel/boards/sof_rt5682.c +++ b/sound/soc/intel/boards/sof_rt5682.c @@ -551,7 +551,7 @@ static int sof_audio_probe(struct platform_device *pdev) int dmic_be_num, hdmi_num; int ret, ssp_amp, ssp_codec; - ctx = devm_kzalloc(&pdev->dev, sizeof(*ctx), GFP_ATOMIC); + ctx = devm_kzalloc(&pdev->dev, sizeof(*ctx), GFP_KERNEL); if (!ctx) return -ENOMEM;