From: Sebastian Andrzej Siewior Date: Wed, 2 Feb 2011 19:01:21 +0000 (+0530) Subject: spi/pxa2xx pci: fix the release - remove race X-Git-Tag: v2.6.38-rc6~30^2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0f3e1d27a7e3f98d996d707d649128e229b65deb;p=pandora-kernel.git spi/pxa2xx pci: fix the release - remove race Right now the platform device and its platform data is included in one big struct which requires its custom ->release function. The problem with the release function within the driver is that it might be called after the driver was removed because someone was holding a reference to it and it was not called right after platform_device_unregister(). So we also free the platform device memory to which one might hold a reference. This patch uses the normal pdev functions so this kind of race does not occur. Signed-off-by: Sebastian Andrzej Siewior Signed-off-by: Grant Likely --- Reading git-diff-tree failed