linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] partitions: fix coding style
@ 2018-12-14  7:04 jotun9935
  2018-12-14  8:47 ` Mukesh Ojha
  0 siblings, 1 reply; 4+ messages in thread
From: jotun9935 @ 2018-12-14  7:04 UTC (permalink / raw)
  To: axboe, jotun9935; +Cc: linux-block, linux-kernel

From: Sungkyung Kim <jotun9935@gmail.com>

Fix coding style of osf.c

Signed-off-by: Sungkyung Kim <jotun9935@gmail.com>
---
 block/partitions/osf.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/block/partitions/osf.c b/block/partitions/osf.c
index 4b873973d6c0..96921a1e31ce 100644
--- a/block/partitions/osf.c
+++ b/block/partitions/osf.c
@@ -22,7 +22,7 @@ int osf_partition(struct parsed_partitions *state)
 	unsigned char *data;
 	struct disklabel {
 		__le32 d_magic;
-		__le16 d_type,d_subtype;
+		__le16 d_type, d_subtype;
 		u8 d_typename[16];
 		u8 d_packname[16];
 		__le32 d_secsize;
@@ -50,8 +50,8 @@ int osf_partition(struct parsed_partitions *state)
 			u8  p_frag;
 			__le16 p_cpg;
 		} d_partitions[MAX_OSF_PARTITIONS];
-	} * label;
-	struct d_partition * partition;
+	} *label;
+	struct d_partition *partition;
 
 	data = read_part_sector(state, 0, &sect);
 	if (!data)
@@ -74,7 +74,7 @@ int osf_partition(struct parsed_partitions *state)
 	}
 	for (i = 0 ; i < npartitions; i++, partition++) {
 		if (slot == state->limit)
-		        break;
+			break;
 		if (le32_to_cpu(partition->p_size))
 			put_partition(state, slot,
 				le32_to_cpu(partition->p_offset),
-- 
2.18.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] partitions: fix coding style
  2018-12-14  7:04 [PATCH] partitions: fix coding style jotun9935
@ 2018-12-14  8:47 ` Mukesh Ojha
  0 siblings, 0 replies; 4+ messages in thread
From: Mukesh Ojha @ 2018-12-14  8:47 UTC (permalink / raw)
  To: jotun9935, axboe; +Cc: linux-block, linux-kernel



On 12/14/2018 12:34 PM, jotun9935@gmail.com wrote:
> From: Sungkyung Kim <jotun9935@gmail.com>
>
> Fix coding style of osf.c
>
> Signed-off-by: Sungkyung Kim <jotun9935@gmail.com>
> ---
>   block/partitions/osf.c | 8 ++++----
>   1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/block/partitions/osf.c b/block/partitions/osf.c
> index 4b873973d6c0..96921a1e31ce 100644
> --- a/block/partitions/osf.c
> +++ b/block/partitions/osf.c
> @@ -22,7 +22,7 @@ int osf_partition(struct parsed_partitions *state)
>   	unsigned char *data;
>   	struct disklabel {
>   		__le32 d_magic;
> -		__le16 d_type,d_subtype;
> +		__le16 d_type, d_subtype;
>   		u8 d_typename[16];
>   		u8 d_packname[16];
>   		__le32 d_secsize;
> @@ -50,8 +50,8 @@ int osf_partition(struct parsed_partitions *state)
>   			u8  p_frag;
>   			__le16 p_cpg;
>   		} d_partitions[MAX_OSF_PARTITIONS];

Also include this change as well

--- a/block/partitions/osf.c
+++ b/block/partitions/osf.c
@@ -57,7 +57,7 @@ int osf_partition(struct parsed_partitions *state)
         if (!data)
                 return -1;

-       label = (struct disklabel *) (data+64);
+       label = (struct disklabel *) (data + 64);
         partition = label->d_partitions;


would be better a bit more you add in your changelog.

Cheers,
Mukesh
> -	} * label;
> -	struct d_partition * partition;
> +	} *label;
> +	struct d_partition *partition;
>   
>   	data = read_part_sector(state, 0, &sect);
>   	if (!data)
> @@ -74,7 +74,7 @@ int osf_partition(struct parsed_partitions *state)
>   	}
>   	for (i = 0 ; i < npartitions; i++, partition++) {
>   		if (slot == state->limit)
> -		        break;
> +			break;
>   		if (le32_to_cpu(partition->p_size))
>   			put_partition(state, slot,
>   				le32_to_cpu(partition->p_offset),


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] partitions: fix coding style
  2018-12-14 10:19 jotun9935
@ 2018-12-14 10:56 ` Mukesh Ojha
  0 siblings, 0 replies; 4+ messages in thread
From: Mukesh Ojha @ 2018-12-14 10:56 UTC (permalink / raw)
  To: jotun9935, axboe; +Cc: linux-block, linux-kernel

Please read the guideline as well before sending patch.

you need to maintain patchset version as well, e.g: in which patchset 
what is changed on whose comments.


-Mukesh


On 12/14/2018 3:49 PM, jotun9935@gmail.com wrote:
> From: Sungkyung Kim <jotun9935@gmail.com>
>
> Fix coding style of osf.c
>
> Signed-off-by: Sungkyung Kim <jotun9935@gmail.com>
> ---
>   block/partitions/osf.c | 10 +++++-----
>   1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/block/partitions/osf.c b/block/partitions/osf.c
> index 4b873973d6c0..19f8e91979f0 100644
> --- a/block/partitions/osf.c
> +++ b/block/partitions/osf.c
> @@ -22,7 +22,7 @@ int osf_partition(struct parsed_partitions *state)
>   	unsigned char *data;
>   	struct disklabel {
>   		__le32 d_magic;
> -		__le16 d_type,d_subtype;
> +		__le16 d_type, d_subtype;
>   		u8 d_typename[16];
>   		u8 d_packname[16];
>   		__le32 d_secsize;
> @@ -50,14 +50,14 @@ int osf_partition(struct parsed_partitions *state)
>   			u8  p_frag;
>   			__le16 p_cpg;
>   		} d_partitions[MAX_OSF_PARTITIONS];
> -	} * label;
> -	struct d_partition * partition;
> +	} *label;
> +	struct d_partition *partition;
>   
>   	data = read_part_sector(state, 0, &sect);
>   	if (!data)
>   		return -1;
>   
> -	label = (struct disklabel *) (data+64);
> +	label = (struct disklabel *) (data + 64);
>   	partition = label->d_partitions;
>   	if (le32_to_cpu(label->d_magic) != DISKLABELMAGIC) {
>   		put_dev_sector(sect);
> @@ -74,7 +74,7 @@ int osf_partition(struct parsed_partitions *state)
>   	}
>   	for (i = 0 ; i < npartitions; i++, partition++) {
>   		if (slot == state->limit)
> -		        break;
> +			break;
>   		if (le32_to_cpu(partition->p_size))
>   			put_partition(state, slot,
>   				le32_to_cpu(partition->p_offset),


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH] partitions: fix coding style
@ 2018-12-14 10:19 jotun9935
  2018-12-14 10:56 ` Mukesh Ojha
  0 siblings, 1 reply; 4+ messages in thread
From: jotun9935 @ 2018-12-14 10:19 UTC (permalink / raw)
  To: axboe, jotun9935; +Cc: linux-block, linux-kernel

From: Sungkyung Kim <jotun9935@gmail.com>

Fix coding style of osf.c

Signed-off-by: Sungkyung Kim <jotun9935@gmail.com>
---
 block/partitions/osf.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/block/partitions/osf.c b/block/partitions/osf.c
index 4b873973d6c0..19f8e91979f0 100644
--- a/block/partitions/osf.c
+++ b/block/partitions/osf.c
@@ -22,7 +22,7 @@ int osf_partition(struct parsed_partitions *state)
 	unsigned char *data;
 	struct disklabel {
 		__le32 d_magic;
-		__le16 d_type,d_subtype;
+		__le16 d_type, d_subtype;
 		u8 d_typename[16];
 		u8 d_packname[16];
 		__le32 d_secsize;
@@ -50,14 +50,14 @@ int osf_partition(struct parsed_partitions *state)
 			u8  p_frag;
 			__le16 p_cpg;
 		} d_partitions[MAX_OSF_PARTITIONS];
-	} * label;
-	struct d_partition * partition;
+	} *label;
+	struct d_partition *partition;
 
 	data = read_part_sector(state, 0, &sect);
 	if (!data)
 		return -1;
 
-	label = (struct disklabel *) (data+64);
+	label = (struct disklabel *) (data + 64);
 	partition = label->d_partitions;
 	if (le32_to_cpu(label->d_magic) != DISKLABELMAGIC) {
 		put_dev_sector(sect);
@@ -74,7 +74,7 @@ int osf_partition(struct parsed_partitions *state)
 	}
 	for (i = 0 ; i < npartitions; i++, partition++) {
 		if (slot == state->limit)
-		        break;
+			break;
 		if (le32_to_cpu(partition->p_size))
 			put_partition(state, slot,
 				le32_to_cpu(partition->p_offset),
-- 
2.18.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-12-14 10:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-14  7:04 [PATCH] partitions: fix coding style jotun9935
2018-12-14  8:47 ` Mukesh Ojha
2018-12-14 10:19 jotun9935
2018-12-14 10:56 ` Mukesh Ojha

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).