Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
284e7ca7
cloud-kernel
项目概览
openanolis
/
cloud-kernel
1 年多 前同步成功
通知
161
Star
36
Fork
7
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
cloud-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
284e7ca7
编写于
7月 02, 2012
作者:
T
Takashi Iwai
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
ALSA: convert PM ops of platform_driver to new pm ops
Signed-off-by:
N
Takashi Iwai
<
tiwai@suse.de
>
上级
8bf01d8a
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
58 addition
and
51 deletion
+58
-51
sound/arm/pxa2xx-ac97.c
sound/arm/pxa2xx-ac97.c
+3
-6
sound/atmel/abdac.c
sound/atmel/abdac.c
+9
-8
sound/atmel/ac97c.c
sound/atmel/ac97c.c
+9
-8
sound/drivers/aloop.c
sound/drivers/aloop.c
+10
-9
sound/drivers/dummy.c
sound/drivers/dummy.c
+10
-8
sound/drivers/pcsp/pcsp.c
sound/drivers/pcsp/pcsp.c
+7
-4
sound/ppc/powermac.c
sound/ppc/powermac.c
+10
-8
未找到文件。
sound/arm/pxa2xx-ac97.c
浏览文件 @
284e7ca7
...
...
@@ -108,7 +108,7 @@ static struct pxa2xx_pcm_client pxa2xx_ac97_pcm_client = {
#ifdef CONFIG_PM
static
int
pxa2xx_ac97_do_suspend
(
struct
snd_card
*
card
,
pm_message_t
state
)
static
int
pxa2xx_ac97_do_suspend
(
struct
snd_card
*
card
)
{
pxa2xx_audio_ops_t
*
platform_ops
=
card
->
dev
->
platform_data
;
...
...
@@ -144,7 +144,7 @@ static int pxa2xx_ac97_suspend(struct device *dev)
int
ret
=
0
;
if
(
card
)
ret
=
pxa2xx_ac97_do_suspend
(
card
,
PMSG_SUSPEND
);
ret
=
pxa2xx_ac97_do_suspend
(
card
);
return
ret
;
}
...
...
@@ -160,10 +160,7 @@ static int pxa2xx_ac97_resume(struct device *dev)
return
ret
;
}
static
const
struct
dev_pm_ops
pxa2xx_ac97_pm_ops
=
{
.
suspend
=
pxa2xx_ac97_suspend
,
.
resume
=
pxa2xx_ac97_resume
,
};
static
SIMPLE_DEV_PM_OPS
(
pxa2xx_ac97_pm_ops
,
pxa2xx_ac97_suspend
,
pxa2xx_ac97_resume
);
#endif
static
int
__devinit
pxa2xx_ac97_probe
(
struct
platform_device
*
dev
)
...
...
sound/atmel/abdac.c
浏览文件 @
284e7ca7
...
...
@@ -535,9 +535,9 @@ static int __devinit atmel_abdac_probe(struct platform_device *pdev)
}
#ifdef CONFIG_PM
static
int
atmel_abdac_suspend
(
struct
platform_device
*
pdev
,
pm_message_t
msg
)
static
int
atmel_abdac_suspend
(
struct
device
*
pdev
)
{
struct
snd_card
*
card
=
platform
_get_drvdata
(
pdev
);
struct
snd_card
*
card
=
dev
_get_drvdata
(
pdev
);
struct
atmel_abdac
*
dac
=
card
->
private_data
;
dw_dma_cyclic_stop
(
dac
->
dma
.
chan
);
...
...
@@ -547,9 +547,9 @@ static int atmel_abdac_suspend(struct platform_device *pdev, pm_message_t msg)
return
0
;
}
static
int
atmel_abdac_resume
(
struct
platform_
device
*
pdev
)
static
int
atmel_abdac_resume
(
struct
device
*
pdev
)
{
struct
snd_card
*
card
=
platform
_get_drvdata
(
pdev
);
struct
snd_card
*
card
=
dev
_get_drvdata
(
pdev
);
struct
atmel_abdac
*
dac
=
card
->
private_data
;
clk_enable
(
dac
->
pclk
);
...
...
@@ -559,9 +559,11 @@ static int atmel_abdac_resume(struct platform_device *pdev)
return
0
;
}
static
SIMPLE_DEV_PM_OPS
(
atmel_abdac_pm
,
atmel_abdac_suspend
,
atmel_abdac_resume
);
#define ATMEL_ABDAC_PM_OPS &atmel_abdac_pm
#else
#define atmel_abdac_suspend NULL
#define atmel_abdac_resume NULL
#define ATMEL_ABDAC_PM_OPS NULL
#endif
static
int
__devexit
atmel_abdac_remove
(
struct
platform_device
*
pdev
)
...
...
@@ -590,9 +592,8 @@ static struct platform_driver atmel_abdac_driver = {
.
driver
=
{
.
name
=
"atmel_abdac"
,
.
owner
=
THIS_MODULE
,
.
pm
=
ATMEL_ABDAC_PM_OPS
,
},
.
suspend
=
atmel_abdac_suspend
,
.
resume
=
atmel_abdac_resume
,
};
static
int
__init
atmel_abdac_init
(
void
)
...
...
sound/atmel/ac97c.c
浏览文件 @
284e7ca7
...
...
@@ -1135,9 +1135,9 @@ static int __devinit atmel_ac97c_probe(struct platform_device *pdev)
}
#ifdef CONFIG_PM
static
int
atmel_ac97c_suspend
(
struct
platform_device
*
pdev
,
pm_message_t
msg
)
static
int
atmel_ac97c_suspend
(
struct
device
*
pdev
)
{
struct
snd_card
*
card
=
platform
_get_drvdata
(
pdev
);
struct
snd_card
*
card
=
dev
_get_drvdata
(
pdev
);
struct
atmel_ac97c
*
chip
=
card
->
private_data
;
if
(
cpu_is_at32ap7000
())
{
...
...
@@ -1151,9 +1151,9 @@ static int atmel_ac97c_suspend(struct platform_device *pdev, pm_message_t msg)
return
0
;
}
static
int
atmel_ac97c_resume
(
struct
platform_
device
*
pdev
)
static
int
atmel_ac97c_resume
(
struct
device
*
pdev
)
{
struct
snd_card
*
card
=
platform
_get_drvdata
(
pdev
);
struct
snd_card
*
card
=
dev
_get_drvdata
(
pdev
);
struct
atmel_ac97c
*
chip
=
card
->
private_data
;
clk_enable
(
chip
->
pclk
);
...
...
@@ -1165,9 +1165,11 @@ static int atmel_ac97c_resume(struct platform_device *pdev)
}
return
0
;
}
static
SIMPLE_DEV_PM_OPS
(
atmel_ac97c_pm
,
atmel_ac97c_suspend
,
atmel_ac97c_resume
);
#define ATMEL_AC97C_PM_OPS &atmel_ac97c_pm
#else
#define atmel_ac97c_suspend NULL
#define atmel_ac97c_resume NULL
#define ATMEL_AC97C_PM_OPS NULL
#endif
static
int
__devexit
atmel_ac97c_remove
(
struct
platform_device
*
pdev
)
...
...
@@ -1211,9 +1213,8 @@ static struct platform_driver atmel_ac97c_driver = {
.
driver
=
{
.
name
=
"atmel_ac97c"
,
.
owner
=
THIS_MODULE
,
.
pm
=
ATMEL_AC97C_PM_OPS
,
},
.
suspend
=
atmel_ac97c_suspend
,
.
resume
=
atmel_ac97c_resume
,
};
static
int
__init
atmel_ac97c_init
(
void
)
...
...
sound/drivers/aloop.c
浏览文件 @
284e7ca7
...
...
@@ -1177,10 +1177,9 @@ static int __devexit loopback_remove(struct platform_device *devptr)
}
#ifdef CONFIG_PM
static
int
loopback_suspend
(
struct
platform_device
*
pdev
,
pm_message_t
state
)
static
int
loopback_suspend
(
struct
device
*
pdev
)
{
struct
snd_card
*
card
=
platform
_get_drvdata
(
pdev
);
struct
snd_card
*
card
=
dev
_get_drvdata
(
pdev
);
struct
loopback
*
loopback
=
card
->
private_data
;
snd_power_change_state
(
card
,
SNDRV_CTL_POWER_D3hot
);
...
...
@@ -1190,13 +1189,18 @@ static int loopback_suspend(struct platform_device *pdev,
return
0
;
}
static
int
loopback_resume
(
struct
platform_
device
*
pdev
)
static
int
loopback_resume
(
struct
device
*
pdev
)
{
struct
snd_card
*
card
=
platform
_get_drvdata
(
pdev
);
struct
snd_card
*
card
=
dev
_get_drvdata
(
pdev
);
snd_power_change_state
(
card
,
SNDRV_CTL_POWER_D0
);
return
0
;
}
static
SIMPLE_DEV_PM_OPS
(
loopback_pm
,
loopback_suspend
,
loopback_resume
);
#define LOOPBACK_PM_OPS &loopback_pm
#else
#define LOOPBACK_PM_OPS NULL
#endif
#define SND_LOOPBACK_DRIVER "snd_aloop"
...
...
@@ -1204,13 +1208,10 @@ static int loopback_resume(struct platform_device *pdev)
static
struct
platform_driver
loopback_driver
=
{
.
probe
=
loopback_probe
,
.
remove
=
__devexit_p
(
loopback_remove
),
#ifdef CONFIG_PM
.
suspend
=
loopback_suspend
,
.
resume
=
loopback_resume
,
#endif
.
driver
=
{
.
name
=
SND_LOOPBACK_DRIVER
,
.
owner
=
THIS_MODULE
,
.
pm
=
LOOPBACK_PM_OPS
,
},
};
...
...
sound/drivers/dummy.c
浏览文件 @
284e7ca7
...
...
@@ -1065,9 +1065,9 @@ static int __devexit snd_dummy_remove(struct platform_device *devptr)
}
#ifdef CONFIG_PM
static
int
snd_dummy_suspend
(
struct
platform_device
*
pdev
,
pm_message_t
state
)
static
int
snd_dummy_suspend
(
struct
device
*
pdev
)
{
struct
snd_card
*
card
=
platform
_get_drvdata
(
pdev
);
struct
snd_card
*
card
=
dev
_get_drvdata
(
pdev
);
struct
snd_dummy
*
dummy
=
card
->
private_data
;
snd_power_change_state
(
card
,
SNDRV_CTL_POWER_D3hot
);
...
...
@@ -1075,13 +1075,18 @@ static int snd_dummy_suspend(struct platform_device *pdev, pm_message_t state)
return
0
;
}
static
int
snd_dummy_resume
(
struct
platform_
device
*
pdev
)
static
int
snd_dummy_resume
(
struct
device
*
pdev
)
{
struct
snd_card
*
card
=
platform
_get_drvdata
(
pdev
);
struct
snd_card
*
card
=
dev
_get_drvdata
(
pdev
);
snd_power_change_state
(
card
,
SNDRV_CTL_POWER_D0
);
return
0
;
}
static
SIMPLE_DEV_PM_OPS
(
snd_dummy_pm
,
snd_dummy_suspend
,
snd_dummy_resume
);
#define SND_DUMMY_PM_OPS &snd_dummy_pm
#else
#define SND_DUMMY_PM_OPS NULL
#endif
#define SND_DUMMY_DRIVER "snd_dummy"
...
...
@@ -1089,13 +1094,10 @@ static int snd_dummy_resume(struct platform_device *pdev)
static
struct
platform_driver
snd_dummy_driver
=
{
.
probe
=
snd_dummy_probe
,
.
remove
=
__devexit_p
(
snd_dummy_remove
),
#ifdef CONFIG_PM
.
suspend
=
snd_dummy_suspend
,
.
resume
=
snd_dummy_resume
,
#endif
.
driver
=
{
.
name
=
SND_DUMMY_DRIVER
,
.
owner
=
THIS_MODULE
,
.
pm
=
SND_DUMMY_PM_OPS
,
},
};
...
...
sound/drivers/pcsp/pcsp.c
浏览文件 @
284e7ca7
...
...
@@ -200,15 +200,18 @@ static void pcsp_stop_beep(struct snd_pcsp *chip)
}
#ifdef CONFIG_PM
static
int
pcsp_suspend
(
struct
platform_device
*
dev
,
pm_message_t
state
)
static
int
pcsp_suspend
(
struct
device
*
dev
)
{
struct
snd_pcsp
*
chip
=
platform
_get_drvdata
(
dev
);
struct
snd_pcsp
*
chip
=
dev
_get_drvdata
(
dev
);
pcsp_stop_beep
(
chip
);
snd_pcm_suspend_all
(
chip
->
pcm
);
return
0
;
}
static
SIMPLE_DEV_PM_OPS
(
pcsp_pm
,
pcsp_suspend
,
NULL
);
#define PCSP_PM_OPS &pcsp_pm
#else
#define
pcsp_suspend
NULL
#define
PCSP_PM_OPS
NULL
#endif
/* CONFIG_PM */
static
void
pcsp_shutdown
(
struct
platform_device
*
dev
)
...
...
@@ -221,10 +224,10 @@ static struct platform_driver pcsp_platform_driver = {
.
driver
=
{
.
name
=
"pcspkr"
,
.
owner
=
THIS_MODULE
,
.
pm
=
PCSP_PM_OPS
,
},
.
probe
=
pcsp_probe
,
.
remove
=
__devexit_p
(
pcsp_remove
),
.
suspend
=
pcsp_suspend
,
.
shutdown
=
pcsp_shutdown
,
};
...
...
sound/ppc/powermac.c
浏览文件 @
284e7ca7
...
...
@@ -144,19 +144,24 @@ static int __devexit snd_pmac_remove(struct platform_device *devptr)
}
#ifdef CONFIG_PM
static
int
snd_pmac_driver_suspend
(
struct
platform_device
*
devptr
,
pm_message_t
state
)
static
int
snd_pmac_driver_suspend
(
struct
device
*
dev
)
{
struct
snd_card
*
card
=
platform_get_drvdata
(
devptr
);
struct
snd_card
*
card
=
dev_get_drvdata
(
dev
);
snd_pmac_suspend
(
card
->
private_data
);
return
0
;
}
static
int
snd_pmac_driver_resume
(
struct
platform_device
*
devptr
)
static
int
snd_pmac_driver_resume
(
struct
device
*
dev
)
{
struct
snd_card
*
card
=
platform_get_drvdata
(
devptr
);
struct
snd_card
*
card
=
dev_get_drvdata
(
dev
);
snd_pmac_resume
(
card
->
private_data
);
return
0
;
}
static
SIMPLE_DEV_PM_OPS
(
snd_pmac_pm
,
snd_pmac_driver_suspend
,
snd_pmac_driver_resume
);
#define SND_PMAC_PM_OPS &snd_pmac_pm
#else
#define SND_PMAC_PM_OPS NULL
#endif
#define SND_PMAC_DRIVER "snd_powermac"
...
...
@@ -164,13 +169,10 @@ static int snd_pmac_driver_resume(struct platform_device *devptr)
static
struct
platform_driver
snd_pmac_driver
=
{
.
probe
=
snd_pmac_probe
,
.
remove
=
__devexit_p
(
snd_pmac_remove
),
#ifdef CONFIG_PM
.
suspend
=
snd_pmac_driver_suspend
,
.
resume
=
snd_pmac_driver_resume
,
#endif
.
driver
=
{
.
name
=
SND_PMAC_DRIVER
,
.
owner
=
THIS_MODULE
,
.
pm
=
SND_PMAC_PM_OPS
,
},
};
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录