Signed-off-by: Xiao Ni <xni@xxxxxxxxxx> --- super-ddf.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/super-ddf.c b/super-ddf.c index c095e8a..49f7d94 100644 --- a/super-ddf.c +++ b/super-ddf.c @@ -3469,6 +3469,9 @@ validate_geometry_ddf_container(struct supertype *st, dev, strerror(errno)); return 0; } + if (test_partition(fd)) + /* DDF is not allowed on partitions */ + return 1; if (!get_dev_size(fd, dev, &ldsize)) { close(fd); return 0; -- 2.7.5