Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7aa4d5c8 authored by Alan Cox's avatar Alan Cox Committed by Jiri Kosina
Browse files

doubletalk: probe failure causes OOPS

The code bothers to probe for the device, but on failing to find it proceeds
to try and release a NULL resource, thereby ruining it's prior good
behaviour

Resolves-Bug: https://bugzilla.kernel.org/show_bug.cgi?id=88581


Signed-off-by: default avatarAlan Cox <alan@linux.intel.com>
Signed-off-by: default avatarJiri Kosina <jkosina@suse.cz>
parent b69a7806
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -361,6 +361,7 @@ static int synth_probe(struct spk_synth *synth)
	port_val &= 0xfbff;
	if (port_val != 0x107f) {
		pr_info("DoubleTalk PC: not found\n");
		if (synth_lpc)
			synth_release_region(synth_lpc, SYNTH_IO_EXTENT);
		return -ENODEV;
	}