From: Peter Huewe Date: Mon, 28 Sep 2009 23:22:40 +0000 (+0200) Subject: Staging: Panel: prevent driver from calling misc_deregister twice on same ressource X-Git-Tag: v2.6.32-rc6~21^2~6 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0b0595bfdaae1f19a052ceee2a63c307793b9c22;p=pandora-kernel.git Staging: Panel: prevent driver from calling misc_deregister twice on same ressource This patch prevents the driver from calling misc_deregister twice on the same ressouce when unloading the driver. Unloading the driver without this patch results in a Kernel BUG like this: Panel driver version 0.9.5 registered on parport0 (io=0x378). BUG: unable to handle kernel paging request at 0000000000100108 IP: [] misc_deregister+0x2d/0x90 PGD 6caff067 PUD 762b7067 PMD 0 Oops: 0002 [#1] PREEMPT SMP last sysfs file: /sys/devices/platform/w83627hf.656/in8_input ... This patch fixes this issue, although maybe not in the best way possible :) linux version v2.6.32-rc1 - linus git tree, Di 29. Sep 01:10:18 CEST 2009 Signed-off-by: Peter Huewe Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed