Linux kernel staging patches
 help / color / mirror / Atom feed
* [PATCH] staging: vme_user: Added static to image_desc and vme_user_vma_priv struct
@ 2024-08-25  3:55 Riyan Dhiman
  2024-08-25  8:13 ` Nam Cao
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Riyan Dhiman @ 2024-08-25  3:55 UTC (permalink / raw)
  To: gregkh; +Cc: linux-kernel, linux-staging, Riyan Dhiman

struct image_desc and vme_user_vma_priv are used only in vme_user.c file.
Added keyword static to these struct definition to limit its scope and
potentially allow for compiler optimizations.

Signed-off-by: Riyan Dhiman <riyandhiman14@gmail.com>
---
 drivers/staging/vme_user/vme_user.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/vme_user/vme_user.c b/drivers/staging/vme_user/vme_user.c
index 5829a4141561..fe1026857710 100644
--- a/drivers/staging/vme_user/vme_user.c
+++ b/drivers/staging/vme_user/vme_user.c
@@ -88,7 +88,7 @@ static unsigned int bus_num;
 /*
  * Structure to handle image related parameters.
  */
-struct image_desc {
+static struct image_desc {
 	void *kern_buf;	/* Buffer address in kernel space */
 	dma_addr_t pci_buf;	/* Buffer address in PCI address space */
 	unsigned long long size_buf;	/* Buffer size */
@@ -114,7 +114,7 @@ static const int type[VME_DEVS] = {	MASTER_MINOR,	MASTER_MINOR,
 					CONTROL_MINOR
 				};
 
-struct vme_user_vma_priv {
+static struct vme_user_vma_priv {
 	unsigned int minor;
 	refcount_t refcnt;
 };
-- 
2.46.0


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

end of thread, other threads:[~2024-08-26 22:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-25  3:55 [PATCH] staging: vme_user: Added static to image_desc and vme_user_vma_priv struct Riyan Dhiman
2024-08-25  8:13 ` Nam Cao
2024-08-26 22:17 ` kernel test robot
2024-08-26 22:38 ` 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