Skip to content

Commit

Permalink
UPSTREAM: fs: ext4: Do not print mount fail message when not ext4 fil…
Browse files Browse the repository at this point in the history
…esystem

Other filesystem drivers don't do this.

Signed-off-by: Marek Behun <marek.behun@nic.cz>
(cherry picked from commit 51be471)
Signed-off-by: Stephen Chen <stephen@radxa.com>
  • Loading branch information
elkablo authored and RadxaStephen committed Mar 23, 2023
1 parent 2d84e3d commit 7aea685
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fs/ext4/ext4_common.c
Expand Up @@ -2343,7 +2343,7 @@ int ext4fs_mount(unsigned part_length)

/* Make sure this is an ext2 filesystem. */
if (le16_to_cpu(data->sblock.magic) != EXT2_MAGIC)
goto fail;
goto fail_noerr;


if (le32_to_cpu(data->sblock.revision_level) == 0) {
Expand Down Expand Up @@ -2379,6 +2379,7 @@ int ext4fs_mount(unsigned part_length)
return 1;
fail:
printf("Failed to mount ext2 filesystem...\n");
fail_noerr:
free(data);
ext4fs_root = NULL;

Expand Down

0 comments on commit 7aea685

Please sign in to comment.