From cc9106247de92549e50abb0ba12d6b2fdbf0be55 Mon Sep 17 00:00:00 2001 From: Cesar Eduardo Barros Date: Sat, 17 Apr 2010 19:28:09 -0300 Subject: fs/partitions: use ADDPART_FLAG_RAID instead of magic number ADDPART_FLAG_RAID was introduced in commit d18d768, and most places were converted to use it instead of a hardcoded value. However, some places seem to have been missed. Change all of them to the symbolic names via the following semantic patch: @@ struct parsed_partitions *state; expression E; @@ ( - state->parts[E].flags = 1 + state->parts[E].flags = ADDPART_FLAG_RAID | - state->parts[E].flags |= 1 + state->parts[E].flags |= ADDPART_FLAG_RAID | - state->parts[E].flags = 2 + state->parts[E].flags = ADDPART_FLAG_WHOLEDISK | - state->parts[E].flags |= 2 + state->parts[E].flags |= ADDPART_FLAG_WHOLEDISK ) Signed-off-by: Cesar Eduardo Barros Signed-off-by: Al Viro --- fs/partitions/efi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'fs/partitions/efi.c') diff --git a/fs/partitions/efi.c b/fs/partitions/efi.c index 91babda..f5867f8 100644 --- a/fs/partitions/efi.c +++ b/fs/partitions/efi.c @@ -631,7 +631,7 @@ efi_partition(struct parsed_partitions *state, struct block_device *bdev) /* If this is a RAID volume, tell md */ if (!efi_guidcmp(ptes[i].partition_type_guid, PARTITION_LINUX_RAID_GUID)) - state->parts[i+1].flags = 1; + state->parts[i + 1].flags = ADDPART_FLAG_RAID; } kfree(ptes); kfree(gpt); -- cgit v1.1