1
0
Fork 0

MLK-24290-1 ASoC: imx-cs42888: change dev_err for dev_dbg for -EPROBE_DEFER case

For the -EPROBE_DEFER case, it is not real error, and just resource is
not ready. It needs to use debug message instead of error message for it.
It could avoid unexpected console message for every device's probe, eg
SD/USB devices plug in, suspend/resume process, etc.

SD device plug in:
mmc1: new high speed SDHC card at address aaaa
mmcblk1: mmc1:aaaa SA16G 14.8 GiB
imx-cs42888 sound-cs42888: failed to find codec platform device

USB device plug in:
usb 2-1: USB disconnect, device number 2
usb 3-1: new SuperSpeed Gen 1 USB device number 2 using cdns-usb3
usb-storage 3-1:1.0: USB Mass Storage device detected
scsi host0: usb-storage 3-1:1.0
imx-cs42888 sound-cs42888: failed to find codec platform device
scsi 0:0:0:0: Direct-Access     SanDisk  Ultra            1.00 PQ: 0 ANSI: 6
sd 0:0:0:0: [sda] 60062500 512-byte logical blocks: (30.8 GB/28.6 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
 sda: sda1
sd 0:0:0:0: [sda] Attached SCSI removable disk
imx-cs42888 sound-cs42888: failed to find codec platform device

Suspend/resume process:
OOM killer disabled.
Freezing remaining freezable tasks ... (elapsed 0.083 seconds) done.
printk: Suspending console(s) (use no_console_suspend to debug)
fec 5b040000.ethernet eth0: Link is Down
PM: suspend devices took 0.684 seconds
Disabling non-boot CPUs ...
CPU1: shutdown
psci: CPU1 killed (polled 4 ms)
CPU2: shutdown
psci: CPU2 killed (polled 0 ms)
CPU3: shutdown
psci: CPU3 killed (polled 0 ms)
Enabling non-boot CPUs ...
Detected VIPT I-cache on CPU1
GICv3: CPU1: found redistributor 1 region 0:0x0000000051b20000
CPU1: Booted secondary processor 0x0000000001 [0x410fd042]
CPU1 is up
Detected VIPT I-cache on CPU2
GICv3: CPU2: found redistributor 2 region 0:0x0000000051b40000
CPU2: Booted secondary processor 0x0000000002 [0x410fd042]
CPU2 is up
Detected VIPT I-cache on CPU3
GICv3: CPU3: found redistributor 3 region 0:0x0000000051b60000
CPU3: Booted secondary processor 0x0000000003 [0x410fd042]
CPU3 is up
imx-cs42888 sound-cs42888: failed to find codec platform device
PM: resume devices took 0.240 seconds
OOM killer enabled.
Restarting tasks ...

Reviewed-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Signed-off-by: Peter Chen <peter.chen@nxp.com>
5.4-rM2-2.2.x-imx-squashed
Peter Chen 2020-06-09 15:29:58 +08:00
parent fb41895e4f
commit b22d33047d
No known key found for this signature in database
GPG Key ID: 4859298150D671BB
1 changed files with 1 additions and 1 deletions

View File

@ -383,7 +383,7 @@ static int imx_cs42888_probe(struct platform_device *pdev)
codec_dev = of_find_i2c_device_by_node(codec_np);
if (!codec_dev || !codec_dev->dev.driver) {
dev_err(&pdev->dev, "failed to find codec platform device\n");
dev_dbg(&pdev->dev, "failed to find codec platform device\n");
ret = -EPROBE_DEFER;
goto fail;
}