Ajit Kumar Pandey
c61711c1c9
ASoC: SOF: Fix NULL pointer exception in sof_pci_probe callback
...
We are accessing "desc->ops" in sof_pci_probe without checking "desc"
pointer. This results in NULL pointer exception if pci_id->driver_data
i.e desc pointer isn't defined in sof device probe:
BUG: kernel NULL pointer dereference, address: 0000000000000060
PGD 0 P4D 0
Oops: 0000 [#1 ] PREEMPT SMP NOPTI
RIP: 0010:sof_pci_probe+0x1e/0x17f [snd_sof_pci]
Code: Unable to access opcode bytes at RIP 0xffffffffc043dff4.
RSP: 0018:ffffac4b03b9b8d8 EFLAGS: 00010246
Add NULL pointer check for sof_dev_desc pointer to avoid such exception.
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Ajit Kumar Pandey <AjitKumar.Pandey@amd.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20220426183357.102155-1-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
2022-04-27 14:15:21 +01:00
..
2022-03-11 13:41:01 +00:00
2022-03-11 13:41:08 +00:00
2022-03-30 14:04:22 +02:00
2021-12-15 14:02:50 +00:00
2021-12-23 13:38:25 +00:00
2022-03-11 13:40:54 +00:00
2022-03-18 16:04:44 +00:00
2022-03-16 16:38:54 +00:00
2022-03-07 13:12:54 +00:00
2022-02-10 15:19:04 +00:00
2022-03-18 16:04:44 +00:00
2022-03-18 16:04:47 +00:00
2022-03-18 16:04:50 +00:00
2022-03-18 16:04:53 +00:00
2022-03-18 16:04:47 +00:00
2022-03-18 16:04:47 +00:00
2022-02-10 15:19:12 +00:00
2021-12-23 13:38:20 +00:00
2022-03-18 16:04:47 +00:00
2021-04-12 17:05:55 +01:00
2021-12-23 13:38:24 +00:00
2022-03-11 13:41:09 +00:00
2022-03-18 16:04:50 +00:00
2022-03-18 16:04:52 +00:00
2021-05-21 13:13:35 +01:00
2021-03-02 15:31:40 +01:00
2022-03-18 16:04:53 +00:00
2022-03-18 16:04:53 +00:00
2022-02-10 15:19:09 +00:00
2022-03-09 17:34:59 +00:00
2022-02-10 15:19:12 +00:00
2022-02-10 15:19:12 +00:00
2022-02-10 15:19:10 +00:00
2022-02-10 15:19:06 +00:00
2021-12-15 14:02:50 +00:00
2021-12-15 14:02:50 +00:00
2022-04-27 14:15:21 +01:00
2021-03-02 15:32:00 +01:00
2022-03-18 16:04:45 +00:00
2022-02-10 15:19:04 +00:00
2022-02-10 15:19:04 +00:00
2022-03-11 13:41:09 +00:00
2022-04-07 18:29:37 +01:00
2022-03-11 13:40:55 +00:00