XFS support for pygrub patch

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

XFS support for pygrub patch

Marco Nenciarini-2

Hi,
I've ported the xfs code from grub to pygrub for our company internal use.

If you find it useful fell free to merge with main code.

Regards,
Marco

--
Marco Nenciarini - System manager @ Devise.IT
[hidden email] | http://www.devise.it

_______________________________________________
Xen-devel mailing list
[hidden email]
http://lists.xensource.com/xen-devel

pygrub-xfs-support.patch (35K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: XFS support for pygrub patch

Stefano Stabellini-3
On Fri, 26 Nov 2010, Marco Nenciarini wrote:
>
> Hi,
> I've ported the xfs code from grub to pygrub for our company internal use.
>
> If you find it useful fell free to merge with main code.

Can anybody test this patch and confirm it works properly?

_______________________________________________
Xen-devel mailing list
[hidden email]
http://lists.xensource.com/xen-devel
Reply | Threaded
Open this post in threaded view
|

Re: XFS support for pygrub patch

Marco Nenciarini-2
On 13/12/2010 18:06, Stefano Stabellini wrote:
> On Fri, 26 Nov 2010, Marco Nenciarini wrote:
>>
>> Hi,
>> I've ported the xfs code from grub to pygrub for our company internal use.
>>
>> If you find it useful fell free to merge with main code.
>
> Can anybody test this patch and confirm it works properly?

To help you testing the patch and auditing the code, I've attached to
this message the diff against xfs code in grub-0.97.

As stated before, the resulting fsimage.so works perfectly for me when
installed in XCP-0.5 as /usr/lib/fs/xfs/fsimage.so

Actually I've 3 Debian Squeeze machines and one Ubuntu 10.10 machine in
our testing environment booting from xfs with pygrub.

The only problem I've found is that the module doesn't compile on Debian
based system due to some bug in gcc code optimizer. On such a systems
the compiler returns the following error:

gcc  -DPIC -O2 -fomit-frame-pointer -m64 -fno-strict-aliasing -std=gnu99
-Wall -Wstrict-prototypes -Wno-unused-value
-Wdeclaration-after-statement  -D__XEN_TOOLS__ -MMD -MF .fsys_xfs.opic.d
 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
-I../../../tools/libfsimage/common/ -Werror -fPIC -c -o fsys_xfs.opic
fsys_xfs.c
fsys_xfs.c: In function ‘next_dentry’:
fsys_xfs.c:409: error: extended registers have no high halves
fsys_xfs.c:409: error: extended registers have no high halves

The problem disappear if you turn off optimization with -O0

Regards,
Marco

--
Marco Nenciarini - System manager @ Devise.IT
[hidden email] | http://www.devise.it

_______________________________________________
Xen-devel mailing list
[hidden email]
http://lists.xensource.com/xen-devel

fsys_xfs.c.diff (9K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: XFS support for pygrub patch

Marco Nenciarini-2
On 14/12/2010 23:23, Marco Nenciarini wrote:

> On 13/12/2010 18:06, Stefano Stabellini wrote:
>> On Fri, 26 Nov 2010, Marco Nenciarini wrote:
>>>
>>> Hi,
>>> I've ported the xfs code from grub to pygrub for our company internal use.
>>>
>>> If you find it useful fell free to merge with main code.
>>
>> Can anybody test this patch and confirm it works properly?
>
> To help you testing the patch and auditing the code, I've attached to
> this message the diff against xfs code in grub-0.97.
>
> As stated before, the resulting fsimage.so works perfectly for me when
> installed in XCP-0.5 as /usr/lib/fs/xfs/fsimage.so
>
> Actually I've 3 Debian Squeeze machines and one Ubuntu 10.10 machine in
> our testing environment booting from xfs with pygrub.
>
> The only problem I've found is that the module doesn't compile on Debian
> based system due to some bug in gcc code optimizer. On such a systems
> the compiler returns the following error:
>
> gcc  -DPIC -O2 -fomit-frame-pointer -m64 -fno-strict-aliasing -std=gnu99
> -Wall -Wstrict-prototypes -Wno-unused-value
> -Wdeclaration-after-statement  -D__XEN_TOOLS__ -MMD -MF .fsys_xfs.opic.d
>  -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
> -I../../../tools/libfsimage/common/ -Werror -fPIC -c -o fsys_xfs.opic
> fsys_xfs.c
> fsys_xfs.c: In function ‘next_dentry’:
> fsys_xfs.c:409: error: extended registers have no high halves
> fsys_xfs.c:409: error: extended registers have no high halves
>
> The problem disappear if you turn off optimization with -O0
>

I've solved the compilation error on Ubuntu/Debian x86_64 (sed
s/"=q"/"=Q"/), but the resulting libary doesn't works (it doesn't even
recognize the XFS partition). I'll debug it during the next week.

Regards,
Marco

--
Marco Nenciarini - System manager @ Devise.IT
[hidden email] | http://www.devise.it

_______________________________________________
Xen-devel mailing list
[hidden email]
http://lists.xensource.com/xen-devel
Reply | Threaded
Open this post in threaded view
|

Re: XFS support for pygrub patch

Marco Nenciarini-2
Attached there is the version of pygrub xfs support patch.

I've tested it against XCP, CentOS and latest Debian Unstable i386/amd64.

There is also my git patch queue against original grub code to show what
I've done.

Regards,
Marco

--
Marco Nenciarini - System manager @ Devise.IT
[hidden email] | http://www.devise.it

_______________________________________________
Xen-devel mailing list
[hidden email]
http://lists.xensource.com/xen-devel

pygrub-xfs-support.patch (35K) Download Attachment
0001-Original-grub-0.97-code.patch (34K) Download Attachment
0002-Initial-porting-to-libfsimage-s-devread.patch (9K) Download Attachment
0003-Fix-offsetof-macro-on-64-bit-systems.patch (658 bytes) Download Attachment
0004-Add-missing-xfs_read-prototype.patch (623 bytes) Download Attachment
0005-Fix-assumtion-that-chars-are-unsigned.patch (727 bytes) Download Attachment
0006-Fix-inline-asm-code-to-work-on-64-bit-patforms.patch (828 bytes) Download Attachment
0007-fix-warning-type-qualifiers-ignored-on-function-retu.patch (1K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: XFS support for pygrub patch

Ian Jackson-2
Marco Nenciarini writes ("Re: [Xen-devel] XFS support for pygrub patch"):
> Attached there is the version of pygrub xfs support patch.
> I've tested it against XCP, CentOS and latest Debian Unstable i386/amd64.
>
> There is also my git patch queue against original grub code to show what
> I've done.

Thanks for your contribution.

I'm afraid that the 4.1 tree is currently in feature code freeze so
normally we wouldn't accept it.

However, having said that, it does look very self-contained and it
might be appropriate to grant a freeze exception in this case.

Stefano, what do you think ?

Ian.

_______________________________________________
Xen-devel mailing list
[hidden email]
http://lists.xensource.com/xen-devel
Reply | Threaded
Open this post in threaded view
|

Re: XFS support for pygrub patch

Stefano Stabellini-3
On Thu, 20 Jan 2011, Ian Jackson wrote:

> Marco Nenciarini writes ("Re: [Xen-devel] XFS support for pygrub patch"):
> > Attached there is the version of pygrub xfs support patch.
> > I've tested it against XCP, CentOS and latest Debian Unstable i386/amd64.
> >
> > There is also my git patch queue against original grub code to show what
> > I've done.
>
> Thanks for your contribution.
>
> I'm afraid that the 4.1 tree is currently in feature code freeze so
> normally we wouldn't accept it.
>
> However, having said that, it does look very self-contained and it
> might be appropriate to grant a freeze exception in this case.
>
> Stefano, what do you think ?

It would be nice if somebody could confirm that it works properly.
If you get a couple of people confirming that it works I would consider
applying it.

_______________________________________________
Xen-devel mailing list
[hidden email]
http://lists.xensource.com/xen-devel
Reply | Threaded
Open this post in threaded view
|

Re: XFS support for pygrub patch

alxgomz
tested on a Debian Squeeze amd64 dom0 with the xen packages as shipped by Squeeze (Xen 4.0.1)
I just added the patch to the debian sources of Xen and rebuild a deb packages using the debian framework.
I can now boot PVMs using pygrub even on machines with xfs boot/rootfs.