staging: vme: Fix a small coding style issue in vme_user.c
Subsystems (2)
PATCH 1/1 staging: vme: Fix a small coding style issue in vme_user.c
The checkpatch.pl complains about missing blank line after declaration. This patch silence the warning.
---
This patch is for Eudyptula Challenge task 10
drivers/staging/vme/devices/vme_user.c | 1 + 1 file changed, 1 insertion(+)
drivers/staging/vme/devices/vme_user.c +1 -0
@@ -791,6 +791,7 @@ static int vme_user_probe(struct vme_dev *vdev)/* Add sysfs Entries */ for (i =0 ; i <VME_DEVS ; i++) {int num; +switch (type[i]) {case MASTER_MINOR :sprintf (name,"bus/vme/m%%d" );
Signature · 1 line
1.9.1.286.g5172cb3
Am 03.04.2014 00:24, schrieb Bojan Prtvar:
Quoted 15 lines
The checkpatch.pl complains about missing blank line after declaration. This patch silence the warning.
Signed-off-by Bojan Prtvar <[email protected]>---
This patch is for Eudyptula Challenge task 10drivers/staging/vme/devices/vme_user.c | 1 + 1 file changed, 1 insertion(+)drivers/staging/vme/devices/vme_user.c +0
-0
drivers/staging/vme/devices/vme_user.c static int vme_user_probe(struct vme_dev *vdev) · line 797
Quoted 7 lines
drivers/staging/vme/devices/vme_user.c +1
-0@@ -791,6 +791,7 @@ static int vme_user_probe(struct vme_dev *vdev)/* Add sysfs Entries */ for (i =0 ; i <VME_DEVS ; i++) {int num; +switch (type[i]) {case MASTER_MINOR :sprintf (name,"bus/vme/m%%d" );
beside style:
that sprint looks like as it could be replaced with a
name="bus/vme/m%%d"
any takers ?
re,
wh
Quoted 9 lines · walter harms
beside style:
that sprint looks like as it could be replaced with a
name="bus/vme/m%%d"any takers ?
re,
wh
Hi Walter,
I guess you mean something like this? Please review carefully if I got right "%%d" intent.
Now a basic question. How to submit this properly? As a v2 patch with both changes taken or as a two-patch serie?
(quoted diff) +0 -0
b/drivers/staging/vme/devices/vme_user.c
index 481192a..5fa7f83 100644
drivers/staging/vme/devices/vme_user.c +4 -4
@@ -684,7 +684,7 @@ static int vme_user_match(struct vme_dev *vdev)static int vme_user_probe (struct vme_dev *vdev) {int i, err; -char name[12 ]; +char *name;/* Save pointer to the bridge device */ if (vme_user_bridge !=NULL ) {
@@ -794,13 +794,13 @@ static int vme_user_probe(struct vme_dev *vdev)switch (type[i]) {case MASTER_MINOR : -sprintf (name,"bus/vme/m%%d" ); + name ="bus/vme/m%d" ;break ;case CONTROL_MINOR : -sprintf (name,"bus/vme/ctl" ); + name ="bus/vme/ctl" ;break ;case SLAVE_MINOR : -sprintf (name,"bus/vme/s%%d" ); + name ="bus/vme/s%d" ;break ;default : err = -EINVAL ;
Regards,
Bojan
Greg KH
maintainerQuoted 12 lines · bojan prtvar
Quoted 9 lines · walter harms
beside style:
that sprint looks like as it could be replaced with a
name="bus/vme/m%%d"any takers ?
re,
wh
Quoted 6 lines
Hi Walter,
I guess you mean something like this? Please review carefully if I got right "%%d" intent.
Now a basic question. How to submit this properly? As a v2 patch with both changes taken or as a two-patch serie?
2 patch series, or just a new patch that is on top of your previous one and mention that in the line below the --- in the patch
thanks,
greg k-h