From: Shinnosuke Yagi <yagi.shinnosuke-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
To: Steve French <smfrench-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: Suresh Jayaraman <sjayaraman-l3A5Bk7waGM@public.gmane.org>,
linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: Source code of SMB2 Kernel module
Date: Wed, 10 Nov 2010 16:48:44 +0900 [thread overview]
Message-ID: <4CDA4E5C.90004@nttcom.co.jp> (raw)
In-Reply-To: <AANLkTikeNCCoMTsnaMMs6jqivgbke9hTUx_25hosM=-9@mail.gmail.com>
I added some logging messages.
====================================================
# git diff fs/smb2/smb2fs.c
diff --git a/fs/smb2/smb2fs.c b/fs/smb2/smb2fs.c
index aa550a3..52c9f35 100644
--- a/fs/smb2/smb2fs.c
+++ b/fs/smb2/smb2fs.c
@@ -57,7 +57,7 @@ static struct quotactl_ops smb2_quotactl_ops;
/* Definitions of various global variables follow */
-int smb2FYI;
+int smb2FYI = 1;
int smb2ERROR = 1;
int trace_SMB2;
@@ -1059,14 +1059,19 @@ init_smb2(void)
goto out_destroy_inodecache;
rc = smb2_init_request_bufs();
- if (rc)
+ sFYI(1, "smb2_init_request_bufs %d", rc);
+ if (rc){
goto out_destroy_mids;
+ }
rc = register_filesystem(&smb2_fs_type);
- if (rc)
+ sFYI(1, "register_filesystem %d", rc);
+ if (rc){
goto out_destroy_request_bufs;
+ }
rc = register_key_type(&smb2_spnego_key_type);
+ sFYI(1, "register_key_type %d", rc);
if (rc)
goto out_unregister_filesystem;
====================================================
I got following logs on dmesg.
====================================================
FS-Cache: Netfs 'smb2' registered for caching
fs/smb2/smb2fs.c: SMB2_max_buf_size 0x4000
fs/smb2/smb2fs.c: smb2_init_request_bufs 0
fs/smb2/smb2fs.c: register_filesystem 0
fs/smb2/smb2fs.c: register_key_type -17
FS-Cache: Netfs 'smb2' unregistered from caching
====================================================
register_key_types returned -17 (EEXIST)
key "smb2" has already registered?
What should I do?
(2010/11/09 13:05), Steve French wrote:
> On Mon, Nov 8, 2010 at 9:49 PM, Shinnosuke Yagi
> <yagi.shinnosuke-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org> wrote:
>> Thank you, Suresh and Steve.
>>
>>
>> Fscache was loaded, but smb2 module was not loaded successfully.
>> Nothing was displayed when I did
>>>
>>> lsmod | grep smb2
>>
>> From Dmesg, following messages were displayed.
>> ====================================================
>> FS-Cache: Netfs 'smb2' registered for caching
>> FS-Cache: Netfs 'smb2' unregistered from caching
>> ====================================================
>>
>> Does this means FS-Cache on this kernel doesn't support smb2?
>
> That is probably not the problem. Seems like init_smb2 is failing.
> Perhaps a problem registering the required key types.
>
> You could enable debug messages to see if additional info is logged
> to dmesg
>
> e.g.
>
> stevef@stevef-laptop:~/smb2$ git diff -a
> diff --git a/fs/smb2/smb2fs.c b/fs/smb2/smb2fs.c
> index aa550a3..8cc1245 100644
> --- a/fs/smb2/smb2fs.c
> +++ b/fs/smb2/smb2fs.c
> @@ -57,7 +57,7 @@ static struct quotactl_ops smb2_quotactl_ops;
>
> /* Definitions of various global variables follow */
>
> -int smb2FYI;
> +int smb2FYI = 1;
> int smb2ERROR = 1;
> int trace_SMB2;
>
>
>
> Alternatively you could add some logging (e.g. printk statements)
> to the error goto statements in this section of smb2fs.c (smb2_init)
>
> rc = smb2_fscache_register();
> if (rc)
> goto out_clean_proc;
>
> rc = smb2_init_inodecache();
> if (rc)
> goto out_unregister_fsc;
>
> rc = smb2_init_mids();
> if (rc)
> goto out_destroy_inodecache;
>
> rc = smb2_init_request_bufs();
> if (rc)
> goto out_destroy_mids;
>
> rc = register_filesystem(&smb2_fs_type);
> if (rc)
> goto out_destroy_request_bufs;
>
> rc = register_key_type(&smb2_spnego_key_type);
>
>
>
---------
next prev parent reply other threads:[~2010-11-10 7:48 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-26 4:26 Source code of SMB2 Kernel module Shinnosuke Yagi
[not found] ` <4CC65859.7040100-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
2010-10-26 5:16 ` Suresh Jayaraman
[not found] ` <4CC6642F.2040401-l3A5Bk7waGM@public.gmane.org>
2010-10-29 6:55 ` Shinnosuke Yagi
[not found] ` <4CCA6FD3.4060907-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
2010-10-29 7:02 ` Suresh Jayaraman
[not found] ` <4CCA7177.40303-l3A5Bk7waGM@public.gmane.org>
2010-11-02 0:40 ` Shinnosuke Yagi
[not found] ` <4CCF5DF8.9030809-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
2010-11-03 9:02 ` Suresh Jayaraman
[not found] ` <4CD12521.2020708-l3A5Bk7waGM@public.gmane.org>
2010-11-05 1:13 ` Shinnosuke Yagi
[not found] ` <4CD35A27.4050605-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
2010-11-05 1:49 ` Steve French
[not found] ` <AANLkTinm718oZX2Qc4++W_CYkv0+RZRwr09Uzu4zcDn0-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-11-08 2:58 ` Shinnosuke Yagi
[not found] ` <4CD76751.8010700-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
2010-11-08 4:53 ` Steve French
[not found] ` <AANLkTimx3ukvAjmuf5KQ3dSLVhpaF51pXcOfS1E_iFhY-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-11-08 5:03 ` Suresh Jayaraman
[not found] ` <4CD784AB.3040805-l3A5Bk7waGM@public.gmane.org>
2010-11-09 3:49 ` Shinnosuke Yagi
[not found] ` <4CD8C4E6.5080603-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
2010-11-09 4:05 ` Steve French
2010-11-10 7:48 ` Shinnosuke Yagi [this message]
[not found] ` <4CDA4E5C.90004-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
2010-11-10 8:04 ` Suresh Jayaraman
[not found] ` <4CDA5225.8000309-l3A5Bk7waGM@public.gmane.org>
2010-11-10 8:35 ` Shinnosuke Yagi
[not found] ` <4CDA5955.50409-o7dWnD6vFTHqq2nvvmkE/A@public.gmane.org>
2010-11-12 5:16 ` Shinnosuke Yagi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4CDA4E5C.90004@nttcom.co.jp \
--to=yagi.shinnosuke-o7dwnd6vfthqq2nvvmke/a@public.gmane.org \
--cc=linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=sjayaraman-l3A5Bk7waGM@public.gmane.org \
--cc=smfrench-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox