[PATCH] opal: prd_info: make a couple of functions static to reduce global scope

Colin King colin.king at canonical.com
Mon Jan 30 16:49:49 UTC 2017


From: Colin Ian King <colin.king at canonical.com>

prd_present and prd_dev_query are currently in global scope and don't
need to be. Make them static.  Also make the fwts_prd_flags const.

Signed-off-by: Colin Ian King <colin.king at canonical.com>
---
 src/opal/prd_info.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/opal/prd_info.c b/src/opal/prd_info.c
index 2a762dd..04e0f4a 100644
--- a/src/opal/prd_info.c
+++ b/src/opal/prd_info.c
@@ -33,12 +33,13 @@
 
 static const char *prd_devnode = "/dev/opal-prd";
 
-bool prd_present(int fwts_prd_flags) {
+static bool prd_present(const int fwts_prd_flags)
+{
 	return !access(prd_devnode, fwts_prd_flags);
 }
 
 #ifdef HAVE_ASM_OPAL_PRD_H
-int prd_dev_query(fwts_framework *fw)
+static int prd_dev_query(fwts_framework *fw)
 {
 
 	int fd = 0;
-- 
2.10.2




More information about the fwts-devel mailing list