Skip to content

Commit

Permalink
pcmcia: limit pxa2xx_trizeps4 subdriver to trizeps4 platform
Browse files Browse the repository at this point in the history
pxa2xx_trizeps4 tries to register pxa2xx-pcmcia device not checking whether
machine is really trizeps4, thus messing multi-machine kernels. Fix it up.

Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
  • Loading branch information
Dmitry Eremin-Solenikov authored and Eric Miao committed Apr 12, 2011
1 parent af21cbb commit 735443f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/pcmcia/pxa2xx_trizeps4.c
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,9 @@ static int __init trizeps_pcmcia_init(void)
{
int ret;

if (!machine_is_trizeps4() && !machine_is_trizeps4wl())
return -ENODEV;

trizeps_pcmcia_device = platform_device_alloc("pxa2xx-pcmcia", -1);
if (!trizeps_pcmcia_device)
return -ENOMEM;
Expand Down

0 comments on commit 735443f

Please sign in to comment.