diff options
Diffstat (limited to 'sound/soc/codecs/wm8900.c')
-rw-r--r-- | sound/soc/codecs/wm8900.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sound/soc/codecs/wm8900.c b/sound/soc/codecs/wm8900.c index de99206a0103..ac308993ac5a 100644 --- a/sound/soc/codecs/wm8900.c +++ b/sound/soc/codecs/wm8900.c | |||
@@ -1399,6 +1399,21 @@ static __devexit int wm8900_i2c_remove(struct i2c_client *client) | |||
1399 | return 0; | 1399 | return 0; |
1400 | } | 1400 | } |
1401 | 1401 | ||
1402 | #ifdef CONFIG_PM | ||
1403 | static int wm8900_i2c_suspend(struct i2c_client *client, pm_message_t msg) | ||
1404 | { | ||
1405 | return snd_soc_suspend_device(&client->dev); | ||
1406 | } | ||
1407 | |||
1408 | static int wm8900_i2c_resume(struct i2c_client *client) | ||
1409 | { | ||
1410 | return snd_soc_resume_device(&client->dev); | ||
1411 | } | ||
1412 | #else | ||
1413 | #define wm8900_i2c_suspend NULL | ||
1414 | #define wm8900_i2c_resume NULL | ||
1415 | #endif | ||
1416 | |||
1402 | static const struct i2c_device_id wm8900_i2c_id[] = { | 1417 | static const struct i2c_device_id wm8900_i2c_id[] = { |
1403 | { "wm8900", 0 }, | 1418 | { "wm8900", 0 }, |
1404 | { } | 1419 | { } |
@@ -1412,6 +1427,8 @@ static struct i2c_driver wm8900_i2c_driver = { | |||
1412 | }, | 1427 | }, |
1413 | .probe = wm8900_i2c_probe, | 1428 | .probe = wm8900_i2c_probe, |
1414 | .remove = __devexit_p(wm8900_i2c_remove), | 1429 | .remove = __devexit_p(wm8900_i2c_remove), |
1430 | .suspend = wm8900_i2c_suspend, | ||
1431 | .resume = wm8900_i2c_resume, | ||
1415 | .id_table = wm8900_i2c_id, | 1432 | .id_table = wm8900_i2c_id, |
1416 | }; | 1433 | }; |
1417 | 1434 | ||