]> git.baikalelectronics.ru Git - kernel.git/commit
fs/partitions: use ADDPART_FLAG_RAID instead of magic number
authorCesar Eduardo Barros <cesarb@cesarb.net>
Sat, 17 Apr 2010 22:28:09 +0000 (19:28 -0300)
committerAl Viro <viro@zeniv.linux.org.uk>
Fri, 21 May 2010 22:31:21 +0000 (18:31 -0400)
commit1204e704a4b8ba095fe101c9bfb7ba1bfffd5d6d
treef0e76e94e4b0041c255b9f3d4f3e5217b37951d2
parentc78a7a85ab7a6b79f7d6c3f103717b1a423865b5
fs/partitions: use ADDPART_FLAG_RAID instead of magic number

ADDPART_FLAG_RAID was introduced in commit 7cdfadf, 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 <cesarb@cesarb.net>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/partitions/efi.c
fs/partitions/mac.c
fs/partitions/msdos.c