[PATCH] dma-mapping: make variable max_segment static

From: Colin King
Date: Sat Jun 23 2018 - 17:28:54 EST


From: Colin Ian King <colin.king@xxxxxxxxxxxxx>

The variable max_segment is local to the source and
does not need to be in global scope, so make it static.

Cleans up sparse warning:
kernel/dma/swiotlb.c:91:14: warning: symbol 'max_segment' was not
declared. Should it be static?

Signed-off-by: Colin Ian King <colin.king@xxxxxxxxxxxxx>
---
kernel/dma/swiotlb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/dma/swiotlb.c b/kernel/dma/swiotlb.c
index 04b68d9dffac..c95376d53c47 100644
--- a/kernel/dma/swiotlb.c
+++ b/kernel/dma/swiotlb.c
@@ -88,7 +88,7 @@ static unsigned int io_tlb_index;
* Max segment that we can provide which (if pages are contingous) will
* not be bounced (unless SWIOTLB_FORCE is set).
*/
-unsigned int max_segment;
+static unsigned int max_segment;

/*
* We need to save away the original address corresponding to a mapped entry
--
2.17.0