[PATCH] staging/ccree: Declare compiled out fuctions static inline

2017-07-31 Thread RishabhHardas
From: RishabhHardas 

Sparse was giving out a warning for symbols 'cc_set_ree_fips_status' and 
'fips_handler'
that they were not declared and need to be made static. This patch makes both 
the symbols
static inline, to remove the warnings.

Signed-off-by: RishabhHardas 
---
 drivers/staging/ccree/ssi_fips.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/ccree/ssi_fips.h b/drivers/staging/ccree/ssi_fips.h
index 369ddf9..63bcca7 100644
--- a/drivers/staging/ccree/ssi_fips.h
+++ b/drivers/staging/ccree/ssi_fips.h
@@ -40,1 +40,1 @@ static inline int ssi_fips_init(struct ssi_drvdata *p_drvdata)
 }

 static inline void ssi_fips_fini(struct ssi_drvdata *drvdata) {}
-void cc_set_ree_fips_status(struct ssi_drvdata *drvdata, bool ok) {}
-void fips_handler(struct ssi_drvdata *drvdata) {}
+static inline void cc_set_ree_fips_status(struct ssi_drvdata *drvdata, bool 
ok) {}
+static inline void fips_handler(struct ssi_drvdata *drvdata) {}

 #endif /* CONFIG_CRYPTO_FIPS */

--
1.9.1

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH] staging/pi433: Solved some coding style issues in pi433_if.c

2017-07-31 Thread RishabhHardas
From: RishabhHardas 

Solved a few coding style issues, used BIT macro to set MINORBITS.

Signed-off-by: RishabhHardas 
---
 drivers/staging/pi433/pi433_if.c | 24 ++--
 1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/drivers/staging/pi433/pi433_if.c b/drivers/staging/pi433/pi433_if.c
index d9328ce..f10ffc3 100644
--- a/drivers/staging/pi433/pi433_if.c
+++ b/drivers/staging/pi433/pi433_if.c
@@ -47,18 +47,18 @@
 #include 
 #include 
 #include 
+#include 
 #ifdef CONFIG_COMPAT
-#include 
+#include 
 #endif

 #include "pi433_if.h"
 #include "rf69.h"

-
-#define N_PI433_MINORS (1U << MINORBITS) /*32*//* ... 
up to 256 */
-#define MAX_MSG_SIZE   900 /* min: FIFO_SIZE! */
-#define MSG_FIFO_SIZE  65536   /* 65536 = 2^16  */
-#define NUM_DIO2
+#define N_PI433_MINORS BIT(MINORBITS) /*32*/ /* ... up to 256 */
+#define MAX_MSG_SIZE   900 /* min: FIFO_SIZE! */
+#define MSG_FIFO_SIZE  65536   /* 65536 = 2^16  */
+#define NUM_DIO2

 static dev_t pi433_dev;
 static DEFINE_IDR(pi433_idr);
@@ -66,10 +66,14 @@

 static struct class *pi433_class; /* mainly for udev to create /dev/pi433 */

-/* tx config is instance specific
-   so with each open a new tx config struct is needed */
-/* rx config is device specific
-   so we have just one rx config, ebedded in device struct */
+/*
+ * tx config is instance specific
+ * so with each open a new tx config struct is needed
+ */
+/*
+ * rx config is device specific
+ * so we have just one rx config, ebedded in device struct
+ */
 struct pi433_device {
/* device handling related values */
dev_t   devt;
--
1.9.1

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel