From: Jin Dongming Date: Wed, 29 Sep 2010 11:53:53 +0000 (+0800) Subject: ACPI, APEI, HEST Fix the unsuitable usage of platform_data X-Git-Tag: v2.6.36-rc7~25^2~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1dd6b20e368765223c31569d364219785b24700b;p=pandora-kernel.git ACPI, APEI, HEST Fix the unsuitable usage of platform_data platform_data in hest_parse_ghes() is used for saving the address of entry information of erst_tab. When the device is failed to be added, platform_data will be freed by platform_device_put(). But the value saved in platform_data should not be freed here. If it is done, it will make system panic. So I think platform_data should save the address of allocated memory which saves entry information of erst_tab. This patch fixed it and I confirmed it on x86_64 next-tree. v2: Transport the pointer of hest_hdr to platform_data using platform_device_add_data() Signed-off-by: Jin Dongming Signed-off-by: Huang Ying Signed-off-by: Len Brown --- Reading git-diff-tree failed