]> git.baikalelectronics.ru Git - kernel.git/commit
serial: imx: fix NULL dereference Oops when pdata == NULL
authorBaruch Siach <baruch@tkos.co.il>
Tue, 22 Dec 2009 00:26:46 +0000 (16:26 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 2 Mar 2010 22:43:10 +0000 (14:43 -0800)
commit948a813fbf40a2266f501efd548f85792387aac0
treee48354ffa1eb1efd10448ae1006fa3772f45f1fc
parentd65fc4a554e305eda408e9ad251f0a04360a20cf
serial: imx: fix NULL dereference Oops when pdata == NULL

The platform code doesn't have to provide platform data to get sensible
default behaviour from the imx serial driver.

This patch does not handle NULL dereference in the IrDA case, which still
requires a valid platform data pointer (in imx_startup()/imx_shutdown()),
since I don't know whether there is a sensible default behaviour, or
should the operation just fail cleanly.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Cc: Baruch Siach <baruch@tkos.co.il>
Cc: Alan Cox <alan@linux.intel.com>
Cc: Sascha Hauer <s.hauer@pengutronix.de>
Cc: Oskar Schirmer <os@emlix.com>
Cc: Fabian Godehardt <fg@emlix.com>
Cc: Daniel Glöckner <dg@emlix.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/serial/imx.c