diff options
author | Jonathan Cameron <jic23@cam.ac.uk> | 2011-07-13 15:54:56 +0100 |
---|---|---|
committer | Dominik Brodowski <linux@dominikbrodowski.net> | 2011-07-29 17:55:10 +0200 |
commit | a747ce835e69069f9bccfb7791008127012cbf32 (patch) | |
tree | 62af73dbb14057a33fbddc303c27ed3e6ad32c7e /drivers/pcmcia | |
parent | 02f8c6aee8df3cdc935e9bdd4f2d020306035dbe (diff) | |
download | linux-stable-a747ce835e69069f9bccfb7791008127012cbf32.tar.gz linux-stable-a747ce835e69069f9bccfb7791008127012cbf32.tar.bz2 linux-stable-a747ce835e69069f9bccfb7791008127012cbf32.zip |
drivers:pcmcia:soc_common: make socket_init and socket_suspend optional
10 boards define these empty, probably indicating not everyone has a use for them.
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/pcmcia')
-rw-r--r-- | drivers/pcmcia/soc_common.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/pcmcia/soc_common.c b/drivers/pcmcia/soc_common.c index 768f9572a8c8..a0a9c2aa8d78 100644 --- a/drivers/pcmcia/soc_common.c +++ b/drivers/pcmcia/soc_common.c @@ -186,8 +186,8 @@ static int soc_common_pcmcia_sock_init(struct pcmcia_socket *sock) struct soc_pcmcia_socket *skt = to_soc_pcmcia_socket(sock); debug(skt, 2, "initializing socket\n"); - - skt->ops->socket_init(skt); + if (skt->ops->socket_init) + skt->ops->socket_init(skt); return 0; } @@ -207,7 +207,8 @@ static int soc_common_pcmcia_suspend(struct pcmcia_socket *sock) debug(skt, 2, "suspending socket\n"); - skt->ops->socket_suspend(skt); + if (skt->ops->socket_suspend) + skt->ops->socket_suspend(skt); return 0; } |