Re: ConfigFS + Target Mode Engine API discussion

Joel Becker
2008-09-13T04:50:21Z

On Fri, Sep 12, 2008 at 03:27:57PM -0700, Nicholas A. Bellinger wrote:
> On Fri, 2008-09-12 at 13:15 -0700, Joel Becker wrote:
> > No, you don't do this. Like I said, configfs clients let
> > userspace create and destroy items. Not kernelspace. Do not call
> > sys_mkdir()/sys_rmdir() from your modules.
>
> Well, the startup 'fabric registration' is only case where I figured
> vfs_mkdir($CONFIGFS/target/$FABRIC) being called in order to have the
> fabric struct config_item appear at modprobe $FABRIC_MOD *BEFORE* the
> user did anything would be beneficial at all. If vfs_mkdir() was not
> called from transport_fabric_register_configfs(), it only means user
> would have call mkdir $CONFIGFS/target/$FABRIC and/or mkdir -p
> $CONFIGFS/target/$FABRIC/endpoint to kick off one common make_group()
> for $FABRIC (that lives in target_core_configfs.c) and then make_group()
> that likes inside of $FABRIC_MOD who's parent is $CONFIGFS/target. In
> LIO-Target's case, this would be creating a new iSCSI Qualified Name
> with mkdir $CONFIGFS/target/iscsi/iqn.superturobdiskarry

I'm still totally unclear as to why $FABRIC has to live under
target/. I'm not clear if there can be more than one $FABRIC at a time.
etc. That's what I'm trying to understand so I can help you out.

Joel

--

Life's Little Instruction Book #20

"Be forgiving of yourself and others."

Joel Becker
Principal Software Developer
Oracle
E-mail: joel.becker@oracle.com
Phone: (650) 506-8127