projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
61b96d5
)
scsi: sr: constify sr_pm_ops structure
author
Julia Lawall
<Julia.Lawall@lip6.fr>
Sun, 28 Aug 2016 20:17:38 +0000
(22:17 +0200)
committer
Martin K. Petersen
<martin.petersen@oracle.com>
Sun, 4 Sep 2016 05:28:08 +0000
(
01:28
-0400)
sr_pm_ops, of type struct dev_pm_ops, is never modified, so declare it
as const.
Done with the help of Coccinelle.
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/sr.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/scsi/sr.c
b/drivers/scsi/sr.c
index ed179348de80b6d39a5600caf2784f37a3413237..bed2bbd6b92304cec9eabb73245224782da7fc21 100644
(file)
--- a/
drivers/scsi/sr.c
+++ b/
drivers/scsi/sr.c
@@
-83,7
+83,7
@@
static int sr_init_command(struct scsi_cmnd *SCpnt);
static int sr_done(struct scsi_cmnd *);
static int sr_runtime_suspend(struct device *dev);
-static struct dev_pm_ops sr_pm_ops = {
+static
const
struct dev_pm_ops sr_pm_ops = {
.runtime_suspend = sr_runtime_suspend,
};