Skip to contentSkip to conversation

Corrected two type checkpatch.pl space errors.

PATCH In review Gulsah Kose 2 participants 4 messages Feb 21, 2015 Alpha port

lore
Share & tools
lore
#0 lore raw

cover Corrected two type checkpatch.pl space errors.

This patch fixes following checkpatch.pl errors in mkbb.c
ERROR: space required before the open parenthesis '('
ERROR: foo ** bar" should be "foo **bar

Gülşah Köse (2):
staging: arch: alpha: boot: tools: Deleted unnecessary space.
staging: arch: alpha: boot: tools: Added missing spaces after brackets.

 arch/alpha/boot/tools/mkbb.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)
Signature · 1 line
1.9.1
#1 lore raw

PATCH 1/2 staging: arch: alpha: boot: tools: Deleted unnecessary space.

This patch fixes "foo ** bar" should be "foo **bar" checkpatch.pl error in mkbb.c

---
 arch/alpha/boot/tools/mkbb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/alpha/boot/tools/mkbb.c +1 -1
index 1185778..05a9d24 100644
@@ -82,7 +82,7 @@ typedef union __bootblock {
 #define	bootblock_label		__u1.__label
 #define bootblock_checksum	__u2.__checksum
 
-int main(int argc, char ** argv)
+int main(int argc, char **argv)
 {
     bootblock		bootblock_from_disk;
     bootblock		bootloader_image;
Signature · 1 line
1.9.1
#2 lore raw

PATCH 2/2 staging: arch: alpha: boot: tools: Added missing spaces after brackets.

In reply to Gulsah Kose

This patch fixes "space required before the open parenthesis '('" checkpatch.pl errors in mkbb.c

---
 arch/alpha/boot/tools/mkbb.c | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
arch/alpha/boot/tools/mkbb.c +7 -7
index 05a9d24..44ba020 100644
@@ -91,21 +91,21 @@ int main(int argc, char **argv)
     int			nread;
 
     /* Make sure of the arg count */
-    if(argc != 3) {
+    if (argc != 3) {
 	fprintf(stderr, "Usage: %s device lxboot\n", argv[0]);
 	exit(0);
     }
 
     /* First, open the device and make sure it's accessible */
     dev = open(argv[1], O_RDWR);
-    if(dev < 0) {
+    if (dev < 0) {
 	perror(argv[1]);
 	exit(0);
     }
 
     /* Now open the lxboot and make sure it's reasonable */
     fd = open(argv[2], O_RDONLY);
-    if(fd < 0) {
+    if (fd < 0) {
 	perror(argv[2]);
 	close(dev);
 	exit(0);
@@ -113,7 +113,7 @@ int main(int argc, char **argv)
 
     /* Read in the lxboot */
     nread = read(fd, &bootloader_image, sizeof(bootblock));
-    if(nread != sizeof(bootblock)) {
+    if (nread != sizeof(bootblock)) {
 	perror("lxboot read");
 	fprintf(stderr, "expected %zd, got %d\n", sizeof(bootblock), nread);
 	exit(0);
@@ -121,7 +121,7 @@ int main(int argc, char **argv)
 
     /* Read in the bootblock from disk. */
     nread = read(dev, &bootblock_from_disk, sizeof(bootblock));
-    if(nread != sizeof(bootblock)) {
+    if (nread != sizeof(bootblock)) {
 	perror("bootblock read");
 	fprintf(stderr, "expected %zd, got %d\n", sizeof(bootblock), nread);
 	exit(0);
@@ -132,14 +132,14 @@ int main(int argc, char **argv)
 
     /* Calculate the bootblock checksum */
     bootloader_image.bootblock_checksum = 0;
-    for(i = 0; i < 63; i++) {
+    for (i = 0; i < 63; i++) {
 	bootloader_image.bootblock_checksum += 
 			bootloader_image.bootblock_quadwords[i];
     }
 
     /* Write the whole thing out! */
     lseek(dev, 0L, SEEK_SET);
-    if(write(dev, &bootloader_image, sizeof(bootblock)) != sizeof(bootblock)) {
+    if (write(dev, &bootloader_image, sizeof(bootblock)) != sizeof(bootblock)) {
 	perror("bootblock write");
 	exit(0);
     }
Signature · 1 line
1.9.1
#3 lore raw
In reply to Gulsah Kose
Quoted 9 lines · Gulsah Kose

This patch fixes following checkpatch.pl errors in mkbb.c
ERROR: space required before the open parenthesis '('
ERROR: foo ** bar" should be "foo **bar

Gülşah Köse (2):
staging: arch: alpha: boot: tools: Deleted unnecessary space.
staging: arch: alpha: boot: tools: Added missing spaces after brackets.

 arch/alpha/boot/tools/mkbb.c | 16 ++++++++--------

As for the other series of patches, you should not be working on files in this directory.

julia

Quoted 12 lines
 1 file changed, 8 insertions(+), 8 deletions(-)
Signature · 8 lines
1.9.1

-- 
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/cover.1424548101.git.gulsah.1004%40gmail.com.
For more options, visit https://groups.google.com/d/optout.