Patch "partitions/msdos: FreeBSD UFS2 file systems are not recognized" has been added to the 4.9-stable tree
Subsystems (2)
This is a note to let you know that I've just added the patch titled
partitions/msdos: FreeBSD UFS2 file systems are not recognized
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
partitions-msdos-freebsd-ufs2-file-systems-are-not-recognized.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
223220356d5ebc05ead9a8d697abb0c0a906fc81Mon Sep 17 00:00:00 2001
From: Richard <[email protected]>
Date: Sun, 21 May 2017 12:27:00 -0700
Subject: partitions/msdos: FreeBSD UFS2 file systems are not recognized
From: Richard <[email protected]>
commit 223220356d5ebc05ead9a8d697abb0c0a906fc81 upstream.
The code in block/partitions/msdos.c recognizes FreeBSD, OpenBSD and NetBSD partitions and does a reasonable job picking out OpenBSD and NetBSD UFS subpartitions.
But for FreeBSD the subpartitions are always "bad".
Kernel: <bsd:bad subpartition - ignored
Though all 3 of these BSD systems use UFS as a file system, only FreeBSD uses relative start addresses in the subpartition declarations.
The following patch fixes this for FreeBSD partitions and leaves the code for OpenBSD and NetBSD intact:
--- block/partitions/msdos.c | 2 ++ 1 file changed, 2 insertions(+)
block/partitions/msdos.c +2 -0
@@ -300,6 +300,8 @@ static void parse_bsd(struct parsed_partcontinue ; bsd_start =le32_to_cpu (p->p_offset); bsd_size =le32_to_cpu (p->p_size); +if (memcmp (flavour,"bsd\0" ,4 ) ==0 ) + bsd_start += offset;if (offset == bsd_start && size == bsd_size)/* full parent partition, we have it already */ continue ;
Patches currently in stable-queue which might be from [email protected] are
queue-4.9/partitions-msdos-freebsd-ufs2-file-systems-are-not-recognized.patch