From: Simon Guinot Date: Tue, 19 Mar 2013 18:07:29 +0000 (-0700) Subject: leds: leds-ns2: fix oops at module removal X-Git-Tag: omap-for-v3.10/dt-fixes-for-merge-window~22^2~4 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3de1929ba61df87a0561c4f1fb7161c401fe3d04;p=pandora-kernel.git leds: leds-ns2: fix oops at module removal This patch fixes a regression introduced by commit 72052fcc10 ("leds: leds-ns2: add device tree binding"). When the driver is initialized with device tree data, platform_data pointer is NULL. This causes a kernel oops at removal. To fix this bug, num_leds is moved into driver_data and platform_data is not longer used from ns2_led_remove(). Signed-off-by: Simon Guinot Signed-off-by: Bryan Wu --- Reading git-diff-tree failed