linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] staging: android: ashmem: Declared file operation with const keyword
@ 2020-03-28 15:15 SandeshKenjanaAshok
  2020-03-29  6:58 ` Greg Kroah-Hartman
  2020-03-29 12:54 ` kbuild test robot
  0 siblings, 2 replies; 22+ messages in thread
From: SandeshKenjanaAshok @ 2020-03-28 15:15 UTC (permalink / raw)
  Cc: sandeshkenjanaashok, Greg Kroah-Hartman,
	Arve Hjønnevåg, Todd Kjos, Martijn Coenen,
	Joel Fernandes, Christian Brauner, devel, linux-kernel

Warning found by checkpatch.pl script.

Signed-off-by: SandeshKenjanaAshok <sandeshkenjanaashok@gmail.com>
---
 drivers/staging/android/ashmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/android/ashmem.c b/drivers/staging/android/ashmem.c
index 8044510d8ec6..fbb6ac9ba1ab 100644
--- a/drivers/staging/android/ashmem.c
+++ b/drivers/staging/android/ashmem.c
@@ -367,7 +367,7 @@ ashmem_vmfile_get_unmapped_area(struct file *file, unsigned long addr,
 
 static int ashmem_mmap(struct file *file, struct vm_area_struct *vma)
 {
-	static struct file_operations vmfile_fops;
+	static const struct file_operations vmfile_fops;
 	struct ashmem_area *asma = file->private_data;
 	int ret = 0;
 
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread
* [PATCH] staging: android: ashmem: Declared file operation with const keyword
@ 2020-12-28  5:13 jovin555
  2020-12-28  6:35 ` Greg Kroah-Hartman
  2021-01-05 11:52 ` Dan Carpenter
  0 siblings, 2 replies; 22+ messages in thread
From: jovin555 @ 2020-12-28  5:13 UTC (permalink / raw)
  Cc: jovin555, Greg Kroah-Hartman, Arve Hjønnevåg,
	Todd Kjos, Martijn Coenen, Joel Fernandes, Christian Brauner,
	devel, linux-kernel

Warning found by checkpatch.pl script.

Signed-off-by: jovin555 <jovin555@gmail.com>
---
 drivers/staging/android/ashmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/android/ashmem.c b/drivers/staging/android/ashmem.c
index c05a214191da..f9cfa15b785f 100644
--- a/drivers/staging/android/ashmem.c
+++ b/drivers/staging/android/ashmem.c
@@ -367,7 +367,7 @@ ashmem_vmfile_get_unmapped_area(struct file *file, unsigned long addr,
 
 static int ashmem_mmap(struct file *file, struct vm_area_struct *vma)
 {
-	static struct file_operations vmfile_fops;
+	static const struct file_operations vmfile_fops;
 	struct ashmem_area *asma = file->private_data;
 	int ret = 0;
 
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread
* [PATCH] staging: android: ashmem: Declared file operation with const keyword
@ 2021-02-14  2:31 Thais Camacho
  2021-02-14  4:49 ` kernel test robot
  2021-02-14  8:21 ` Greg Kroah-Hartman
  0 siblings, 2 replies; 22+ messages in thread
From: Thais Camacho @ 2021-02-14  2:31 UTC (permalink / raw)
  Cc: thaiscamachoo, Greg Kroah-Hartman, Arve Hjønnevåg,
	Todd Kjos, Martijn Coenen, Joel Fernandes, Christian Brauner,
	Hridya Valsaraju, Suren Baghdasaryan, devel, linux-kernel

Warning found by checkpatch.pl script

Signed-off-by: Thais Camacho <thaiscamachoo@gmail.com>
---
 drivers/staging/android/ashmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/android/ashmem.c b/drivers/staging/android/ashmem.c
index 4789d36ddfd3..2cb665e0228c 100644
--- a/drivers/staging/android/ashmem.c
+++ b/drivers/staging/android/ashmem.c
@@ -376,7 +376,7 @@ ashmem_vmfile_get_unmapped_area(struct file *file, unsigned long addr,
 
 static int ashmem_mmap(struct file *file, struct vm_area_struct *vma)
 {
-	static struct file_operations vmfile_fops;
+	static const struct file_operations vmfile_fops;
 	struct ashmem_area *asma = file->private_data;
 	int ret = 0;
 
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread
* [PATCH] staging: android: ashmem: Declared file operation with 'const' keyword
@ 2021-05-19  8:19 Hriday Hegde
  2021-05-19  8:31 ` Greg Kroah-Hartman
  0 siblings, 1 reply; 22+ messages in thread
From: Hriday Hegde @ 2021-05-19  8:19 UTC (permalink / raw)
  Cc: hridayhegde1999, Greg Kroah-Hartman, Arve Hjønnevåg,
	Todd Kjos, Martijn Coenen, Joel Fernandes, Christian Brauner,
	Hridya Valsaraju, Suren Baghdasaryan, linux-kernel,
	linux-staging

Fixing following warnings found by checkpatch.pl
WARNING: struct file_operations should normally be const
380: FILE: drivers/staging/android/ashmem.c:380:
+	static struct file_operations vmfile_fops;

Signed-off-by: Hriday Hegde <hridayhegde1999@gmail.com>
---
 drivers/staging/android/ashmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/android/ashmem.c b/drivers/staging/android/ashmem.c
index 8ee4320a5dc6..8ff2794b08e3 100644
--- a/drivers/staging/android/ashmem.c
+++ b/drivers/staging/android/ashmem.c
@@ -377,7 +377,7 @@ ashmem_vmfile_get_unmapped_area(struct file *file, unsigned long addr,
 
 static int ashmem_mmap(struct file *file, struct vm_area_struct *vma)
 {
-	static struct file_operations vmfile_fops;
+	static const struct file_operations vmfile_fops;
 	struct ashmem_area *asma = file->private_data;
 	int ret = 0;
 
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread
* [PATCH] staging: android: ashmem: Declared file operation with const keyword
@ 2022-01-24  7:09 ratnesh-r1
  2022-01-24  7:39 ` Greg Kroah-Hartman
                   ` (2 more replies)
  0 siblings, 3 replies; 22+ messages in thread
From: ratnesh-r1 @ 2022-01-24  7:09 UTC (permalink / raw)
  Cc: me.ratnesh682, Greg Kroah-Hartman, Arve Hjønnevåg,
	Todd Kjos, Martijn Coenen, Joel Fernandes, Christian Brauner,
	devel, linux-kernel

warning found by checkpatch.pl script.

Signed-off-by: ratnesh-r1 <me.ratnesh682@gmail.com>
---
 drivers/staging/android/ashmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/android/ashmem.c b/drivers/staging/android/ashmem.c
index c05a214..f9cfa15 100644
--- a/drivers/staging/android/ashmem.c
+++ b/drivers/staging/android/ashmem.c
@@ -367,7 +367,7 @@ ashmem_vmfile_get_unmapped_area(struct file *file, unsigned long addr,
 
 static int ashmem_mmap(struct file *file, struct vm_area_struct *vma)
 {
-	static struct file_operations vmfile_fops;
+	static const struct file_operations vmfile_fops;
 	struct ashmem_area *asma = file->private_data;
 	int ret = 0;
 
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2022-01-24 12:27 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-28 15:15 [PATCH] staging: android: ashmem: Declared file operation with const keyword SandeshKenjanaAshok
2020-03-29  6:58 ` Greg Kroah-Hartman
2020-03-29 12:54 ` kbuild test robot
2020-12-28  5:13 jovin555
2020-12-28  6:35 ` Greg Kroah-Hartman
2021-01-05 11:52 ` Dan Carpenter
2021-02-14  2:31 Thais Camacho
2021-02-14  4:49 ` kernel test robot
2021-02-14  8:21 ` Greg Kroah-Hartman
2021-05-19  8:19 [PATCH] staging: android: ashmem: Declared file operation with 'const' keyword Hriday Hegde
2021-05-19  8:31 ` Greg Kroah-Hartman
2021-05-19  9:30   ` Hriday Hegde
2021-05-19  9:50     ` Greg Kroah-Hartman
2021-05-19 14:36       ` Hriday Hegde
2021-05-19 14:51         ` Fabio Aiuto
2021-05-19 15:54           ` Hriday Hegde
2021-05-19 14:55         ` Greg Kroah-Hartman
2021-05-19 15:56           ` Hriday Hegde
2022-01-24  7:09 [PATCH] staging: android: ashmem: Declared file operation with const keyword ratnesh-r1
2022-01-24  7:39 ` Greg Kroah-Hartman
2022-01-24 11:20 ` kernel test robot
2022-01-24 12:27 ` kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).