Skip to contentSkip to conversation

dm-zoned: add SPDX identifiers

PATCH In review Dmitry Fomichev 2 participants 5 messages Aug 2, 2019 Device mapper

lore
Share & tools
lore
#0 lore raw

cover dm-zoned: add SPDX identifiers

The first patch adds SPDX IDs to all dm-zoned source files.

The second patch fixes a few typos.

No functional change.

Dmitry Fomichev (2):
dm-zoned: add SPDX license identifiers
dm-zoned: fix a few typos

 drivers/md/dm-zoned-metadata.c | 9 +++++----
 drivers/md/dm-zoned-reclaim.c  | 3 ++-
 drivers/md/dm-zoned-target.c   | 1 +
 drivers/md/dm-zoned.h          | 1 +
 4 files changed, 9 insertions(+), 5 deletions(-)
Signature · 1 line
2.21.0
#1 lore raw

PATCH 1/2 dm-zoned: add SPDX license identifiers

---
 drivers/md/dm-zoned-metadata.c | 1 +
 drivers/md/dm-zoned-reclaim.c  | 1 +
 drivers/md/dm-zoned-target.c   | 1 +
 drivers/md/dm-zoned.h          | 1 +
 4 files changed, 4 insertions(+)
drivers/md/dm-zoned-metadata.c +1 -0
index 8545dcee9fd0..23e9a6d9350b 100644
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-only
 /*
  * Copyright (C) 2017 Western Digital Corporation or its affiliates.
  *
drivers/md/dm-zoned-reclaim.c +1 -0
index edf4b95eb075..387894e2add1 100644
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-only
 /*
  * Copyright (C) 2017 Western Digital Corporation or its affiliates.
  *
drivers/md/dm-zoned-target.c +1 -0
index 51d029bbb740..1bf6e6eebee1 100644
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-only
 /*
  * Copyright (C) 2017 Western Digital Corporation or its affiliates.
  *
drivers/md/dm-zoned.h +1 -0
index ed8de49c9a08..1a3b06de2c00 100644
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
 /*
  * Copyright (C) 2017 Western Digital Corporation or its affiliates.
  *
Signature · 1 line
2.21.0
Reviewed-by on v1 1/2
#2 lore raw

Re: [PATCH 1/2] dm-zoned: add SPDX license identifiers

Quoted 41 lines · Dmitry Fomichev
---
 drivers/md/dm-zoned-metadata.c | 1 +
 drivers/md/dm-zoned-reclaim.c  | 1 +
 drivers/md/dm-zoned-target.c   | 1 +
 drivers/md/dm-zoned.h          | 1 +
 4 files changed, 4 insertions(+)
drivers/md/dm-zoned-metadata.c +1 -0
index 8545dcee9fd0..23e9a6d9350b 100644
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-only
 /*
  * Copyright (C) 2017 Western Digital Corporation or its affiliates.
  *
drivers/md/dm-zoned-reclaim.c +1 -0
index edf4b95eb075..387894e2add1 100644
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-only
 /*
  * Copyright (C) 2017 Western Digital Corporation or its affiliates.
  *
drivers/md/dm-zoned-target.c +1 -0
index 51d029bbb740..1bf6e6eebee1 100644
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-only
 /*
  * Copyright (C) 2017 Western Digital Corporation or its affiliates.
  *
drivers/md/dm-zoned.h +0 -0
index ed8de49c9a08..1a3b06de2c00 100644

drivers/md/dm-zoned.h line 4

Quoted 4 lines
drivers/md/dm-zoned.h +1 -0
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
 /*
  * Copyright (C) 2017 Western Digital Corporation or its affiliates.
  *
Signature · 2 lines
Damien Le Moal
Western Digital Research
#3 lore raw

PATCH 2/2 dm-zoned: fix a few typos

In reply to Dmitry Fomichev
---
 drivers/md/dm-zoned-metadata.c | 8 ++++----
 drivers/md/dm-zoned-reclaim.c  | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)
drivers/md/dm-zoned-metadata.c +4 -4
index 23e9a6d9350b..ded4984d18c9 100644
@@ -35,7 +35,7 @@
  *    (1) Super block (1 block)
  *    (2) Chunk mapping table (nr_map_blocks)
  *    (3) Bitmap blocks (nr_bitmap_blocks)
- * All metadata blocks are stored in conventional zones, starting from the
+ * All metadata blocks are stored in conventional zones, starting from
  * the first conventional zone found on disk.
  */
 struct dmz_super {
@@ -234,7 +234,7 @@ void dmz_unlock_map(struct dmz_metadata *zmd)
  * Lock/unlock metadata access. This is a "read" lock on a semaphore
  * that prevents metadata flush from running while metadata are being
  * modified. The actual metadata write mutual exclusion is achieved with
- * the map lock and zone styate management (active and reclaim state are
+ * the map lock and zone state management (active and reclaim state are
  * mutually exclusive).
  */
 void dmz_lock_metadata(struct dmz_metadata *zmd)
@@ -1629,7 +1629,7 @@ struct dm_zone *dmz_get_chunk_mapping(struct dmz_metadata *zmd, unsigned int chu
 		if (op != REQ_OP_WRITE)
 			goto out;
 
-		/* Alloate a random zone */
+		/* Allocate a random zone */
 		dzone = dmz_alloc_zone(zmd, DMZ_ALLOC_RND);
 		if (!dzone) {
 			dmz_wait_for_free_zones(zmd);
@@ -1726,7 +1726,7 @@ struct dm_zone *dmz_get_chunk_buffer(struct dmz_metadata *zmd,
 	if (bzone)
 		goto out;
 
-	/* Alloate a random zone */
+	/* Allocate a random zone */
 	bzone = dmz_alloc_zone(zmd, DMZ_ALLOC_RND);
 	if (!bzone) {
 		dmz_wait_for_free_zones(zmd);
drivers/md/dm-zoned-reclaim.c +1 -1
index 387894e2add1..260e3598199e 100644
@@ -428,7 +428,7 @@ static bool dmz_should_reclaim(struct dmz_reclaim *zrc)
 		return false;
 
 	/*
-	 * If the percentage of unmappped random zones is low,
+	 * If the percentage of unmapped random zones is low,
 	 * reclaim even if the target is busy.
 	 */
 	return p_unmap_rnd <= DMZ_RECLAIM_LOW_UNMAP_RND;
Signature · 1 line
2.21.0
Reviewed-by on v1 2/2
#4 lore raw

Re: [PATCH 2/2] dm-zoned: fix a few typos

Quoted 52 lines · Dmitry Fomichev
---
 drivers/md/dm-zoned-metadata.c | 8 ++++----
 drivers/md/dm-zoned-reclaim.c  | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)
drivers/md/dm-zoned-metadata.c +4 -4
index 23e9a6d9350b..ded4984d18c9 100644
@@ -35,7 +35,7 @@
  *    (1) Super block (1 block)
  *    (2) Chunk mapping table (nr_map_blocks)
  *    (3) Bitmap blocks (nr_bitmap_blocks)
- * All metadata blocks are stored in conventional zones, starting from the
+ * All metadata blocks are stored in conventional zones, starting from
  * the first conventional zone found on disk.
  */
 struct dmz_super {
@@ -234,7 +234,7 @@ void dmz_unlock_map(struct dmz_metadata *zmd)
  * Lock/unlock metadata access. This is a "read" lock on a semaphore
  * that prevents metadata flush from running while metadata are being
  * modified. The actual metadata write mutual exclusion is achieved with
- * the map lock and zone styate management (active and reclaim state are
+ * the map lock and zone state management (active and reclaim state are
  * mutually exclusive).
  */
 void dmz_lock_metadata(struct dmz_metadata *zmd)
@@ -1629,7 +1629,7 @@ struct dm_zone *dmz_get_chunk_mapping(struct dmz_metadata *zmd, unsigned int chu
 		if (op != REQ_OP_WRITE)
 			goto out;
 
-		/* Alloate a random zone */
+		/* Allocate a random zone */
 		dzone = dmz_alloc_zone(zmd, DMZ_ALLOC_RND);
 		if (!dzone) {
 			dmz_wait_for_free_zones(zmd);
@@ -1726,7 +1726,7 @@ struct dm_zone *dmz_get_chunk_buffer(struct dmz_metadata *zmd,
 	if (bzone)
 		goto out;
 
-	/* Alloate a random zone */
+	/* Allocate a random zone */
 	bzone = dmz_alloc_zone(zmd, DMZ_ALLOC_RND);
 	if (!bzone) {
 		dmz_wait_for_free_zones(zmd);
drivers/md/dm-zoned-reclaim.c +0 -0
index 387894e2add1..260e3598199e 100644

drivers/md/dm-zoned-reclaim.c static bool dmz_should_reclaim(struct dmz_reclaim *zrc) · line 434

Quoted 8 lines
drivers/md/dm-zoned-reclaim.c +1 -1
@@ -428,7 +428,7 @@ static bool dmz_should_reclaim(struct dmz_reclaim *zrc)
 		return false;
 
 	/*
-	 * If the percentage of unmappped random zones is low,
+	 * If the percentage of unmapped random zones is low,
 	 * reclaim even if the target is busy.
 	 */
 	return p_unmap_rnd <= DMZ_RECLAIM_LOW_UNMAP_RND;
Signature · 2 lines
Damien Le Moal
Western Digital Research