xfs
[Top] [All Lists]

Re: DMAPI as module (kernel compilation failure).

To: Paul Blazejowski <paulb@xxxxxxxxxxxxxxxxxxx>
Subject: Re: DMAPI as module (kernel compilation failure).
From: Keith Owens <kaos@xxxxxxx>
Date: Mon, 20 May 2002 12:00:53 +1000
Cc: linux-xfs@xxxxxxxxxxx, roehrich@xxxxxxx
In-reply-to: Your message of "19 May 2002 12:01:33 -0400." <1021824094.1955.15.camel@blaze>
Sender: owner-linux-xfs@xxxxxxxxxxx
On 19 May 2002 12:01:33 -0400, 
Paul Blazejowski <paulb@xxxxxxxxxxxxxxxxxxx> wrote:
>I'm not sure if this has been answered on the list.Sorry if it was.
>CONFIG_XFS_FS=y
>CONFIG_XFS_RT=y
>CONFIG_XFS_QUOTA=y
>CONFIG_XFS_DMAPI=m
>CONFIG_HAVE_XFS_DMAPI=y

Originally sent April 19, 2002.  I don't recall getting a definitive
answer on whether we want to support XFS built in with DMAPI as a
module or not.  Dean?

From: Keith Owens <kaos@xxxxxxx>
To: matthew@xxxxxxxxxxxxxxxx
Cc: linux-xfs@xxxxxxxxxxx, roehrich@xxxxxxx
Subject: Re: Can't build kernal with DMAPI as a module in 2.4 CVS 
In-reply-to: Your message of "Fri, 19 Apr 2002 10:36:52 +1000."
             <1019176612.3cbf66a453076@xxxxxxxxxxxxxxxxxxxxxx> 
Date: Fri, 19 Apr 2002 12:02:42 +1000

On Fri, 19 Apr 2002 10:36:52 +1000, 
matthew@xxxxxxxxxxxxxxxx wrote:
> Not sure why you would want to - but I accidently selected DMAPI m instead of 
> n
>and the resulting kernel would not link due to what appeared to be missing 
>DMAPI
>function calls.
>
> I guess some one should get into kbuild and remove the option to build it as a
>module ?

Dean, as currently coded XFS has unconditional calls to DMAPI.  This
means that when XFS is built in then DMAPI cannot be a module.  The
patch below enforces this rule but I am not going to check it in until
you decide if the code is correct or not.

If XFS built in with DMAPI in a module is desirable then forget this
patch, the DMAPI code has to be changed to use a register function and
XFS to make conditional calls to DMAPI via the registered data.

===========================================================================
Index: linux/fs/Config.in
===========================================================================

--- /usr/tmp/TmpDir.27777-0/linux/fs/Config.in_1.77     Fri Apr 19 11:58:11 2002
+++ linux/fs/Config.in  Fri Apr 19 11:50:22 2002
@@ -100,8 +100,16 @@
 dep_mbool    '  Enable XFS Realtime support' CONFIG_XFS_RT $CONFIG_XFS_FS
 dep_mbool    '  Enable XFS Quota' CONFIG_XFS_QUOTA $CONFIG_XFS_FS
 if [ "$CONFIG_XFS_FS" != "n" ]; then
+    # Current DMAPI code has calls from XFS to DMAPI.  This requires that
+    # DMAPI be built in if selected and XFS is built in.  Valid combinations
+    #   XFS=n, DMAPI=n
+    #   XFS=y, DMAPI=[yn]
+    #   XFS=m, DMAPI=[mn]
     dep_tristate '  Enable XFS DMAPI' CONFIG_XFS_DMAPI $CONFIG_XFS_FS
     if [ "$CONFIG_XFS_DMAPI" != "n" ]; then
+       if [ "$CONFIG_XFS_FS" = "y" ]; then
+          define_tristate CONFIG_XFS_DMAPI y
+       fi        
        define_bool CONFIG_HAVE_XFS_DMAPI y
     fi
 fi



<Prev in Thread] Current Thread [Next in Thread>