staging/pi433: Solved some coding style issues in pi433_if.c
PATCH 1/1 staging/pi433: Solved some coding style issues in pi433_if.c
From: RishabhHardas <[email protected]>
Solved a few coding style issues, used BIT macro to set MINORBITS.
Signed-off-by RishabhHardas <[email protected]>
--- drivers/staging/pi433/pi433_if.c | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-)
drivers/staging/pi433/pi433_if.c +14 -10
@@ -47,18 +47,18 @@#include <linux/kthread.h> #include <linux/wait.h> #include <linux/spi/spi.h> +#include <linux/bitops.h> #ifdef CONFIG_COMPAT -#include <asm/compat.h> +#include <linux/compat.h> #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_DIO 2 +#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_DIO 2static 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
Reviewed-by Marcus Wolf <[email protected]>
Thank you Rishabh!
Marcus
Am Mo, 31.07.2017, 12:21 schrieb RishabhHardas:
Quoted 62 lines
From: RishabhHardas <[email protected]>
Solved a few coding style issues, used BIT macro to set MINORBITS.
Signed-off-by RishabhHardas <[email protected]>--- drivers/staging/pi433/pi433_if.c | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-)drivers/staging/pi433/pi433_if.c +14
-11@@ -47,18 +47,18 @@#include <linux/kthread.h> #include <linux/wait.h> #include <linux/spi/spi.h> +#include <linux/bitops.h> #ifdef CONFIG_COMPAT -#include <asm/compat.h> +#include <linux/compat.h> #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_DIO 2 +#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_DIO 2static 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
Greg KH
maintainerQuoted 5 lines · RishabhHardas
From: RishabhHardas <[email protected]>
Solved a few coding style issues, used BIT macro to set MINORBITS.
Signed-off-by RishabhHardas <[email protected]>
For some reason I do not think your legal name has no space in it :(
Please fix and resend.
thanks,
greg k-h