提交 af21cbb1 编写于 作者: D Dmitry Eremin-Solenikov 提交者: Eric Miao

pcmcia: limit pxa2xx_balloon3 subdriver to balloon3 platform

pxa2xx_balloon3 tries to register pxa2xx-pcmcia device not checking whether
machine is really balloon3, thus messing multi-machine kernels. Fix it up.
Signed-off-by: NDmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: NEric Miao <eric.y.miao@gmail.com>
上级 a6d710fe
...@@ -25,6 +25,8 @@ ...@@ -25,6 +25,8 @@
#include <mach/balloon3.h> #include <mach/balloon3.h>
#include <asm/mach-types.h>
#include "soc_common.h" #include "soc_common.h"
/* /*
...@@ -127,6 +129,9 @@ static int __init balloon3_pcmcia_init(void) ...@@ -127,6 +129,9 @@ static int __init balloon3_pcmcia_init(void)
{ {
int ret; int ret;
if (!machine_is_balloon3())
return -ENODEV;
balloon3_pcmcia_device = platform_device_alloc("pxa2xx-pcmcia", -1); balloon3_pcmcia_device = platform_device_alloc("pxa2xx-pcmcia", -1);
if (!balloon3_pcmcia_device) if (!balloon3_pcmcia_device)
return -ENOMEM; return -ENOMEM;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册