[krn.modules] cifs.ko module for Galaxy S3 Stock kernel

Search This thread

jfrm

Senior Member
Feb 1, 2006
385
46
Marbella
Wow!!!

Taylor made...

Wil try right now and report.

You are so kind...

EDIT:

Already try your modules an all is workig. I Really thank you.

Just one question: is unicode charset supported? I'm finding a lot of odd characters while browsing my spanish named files ...
 
Last edited:
  • Like
Reactions: viulian

viulian

Inactive Recognized Developer
Apr 6, 2011
419
411
hex.ro
You are right, I keep all my files in with English names so I did not spot the difference. Please redownload from first post - nls_utf8.ko is now included.

Also, do not forget the iocharset=utf8 as options when you define the share in CifsManager (or you can Edit it and add the options, then remount).
 
  • Like
Reactions: jfrm

jfrm

Senior Member
Feb 1, 2006
385
46
Marbella
Again all working, even our beloved spanish "ñ" and all the accents.

You'r my hero....

If any one is using mount manager, instead of cifs manager, and want to add the new charset you will need to add a property to the share (+ button), select charset and then write utf8. The charset option don't appear by default.
 

djmwj

Member
Apr 13, 2010
18
0
Thanks for your work. I was hoping you could give a brief run through on how you compiled the modules. I have kernel 3.0.31-329968 on jellybean with sonic gs3 rom. I was hoping to build modules for it. Thanks.
 

viulian

Inactive Recognized Developer
Apr 6, 2011
419
411
hex.ro
cifs module (as well as the other 2 companions, the nls_utf8 and md4) are already part of the kernel source - so as long as you can build your kernel, you should also obtain the necessary modules.

I don't have a tutorial on how to build the kernel, but you have to start by editing the EXTRAVERSION and CROSS_COMPILE variables within the root Makefile. Please do a Google search including these two keywords, and you should be good to go.
 

viulian

Inactive Recognized Developer
Apr 6, 2011
419
411
hex.ro
On request from a fellow member - rodrimartins, I have also added build for version 3.0.31-368423 of the kernel.

Please check the first post of the thread.
 

ninocass

Member
Sep 23, 2007
34
1
EDIT: Seems to be working now, bizzare!

Thanks for building this but im having some issues the following is over adb:

Code:
[email protected]:/system/xbin/lib # id
uid=0(root) gid=0(root)

Code:
[email protected]:/system/xbin/lib # pwd
/system/xbin/lib

Code:
[email protected]:/system/xbin/lib # insmod cifs.ko
insmod cifs.ko

Code:
[email protected]:/system/xbin/lib # lsmod
lsmod
md4 3393 0 - Live 0x00000000
cifs 242799 0 - Live 0x00000000
dhd 412467 0 - Live 0x00000000
btlock 1576 0 - Live 0x00000000
exfat_fs 17079 0 - Live 0x00000000 (P)
exfat_core 59623 1 exfat_fs, Live 0x00000000 (P)

Code:
[email protected]:/system/xbin/lib # mount -t cifs //<ip>/storage/ /mnt/cifs
mount: No such file or directory

cifs manager and mount manager also fail to work :S
 
Last edited:

viulian

Inactive Recognized Developer
Apr 6, 2011
419
411
hex.ro
@ninocass

You have to specify username and password otherwise mine says Invalid Argument.
Can you please try also with -o ?

PHP:
mount -o username=XXXX,password=XXXX -t cifs //ip/share /mnt/cifs

Of course, /mnt/cifs has to exist.
 

mrmrmrmr

Senior Member
Jan 14, 2007
2,543
252
is there any compiled cifs module for kernel 3.0.31-487742 ?
can I use the closest one in OP ?

---------- Post added at 11:25 PM ---------- Previous post was at 10:39 PM ----------

is there any compiled cifs module for kernel 3.0.31-487742 ?
can I use the closest one in OP ?

I just tried it.
The module loads but does not work.
Can't mount any cifs share.
So, I guess I need a cifs module specially for kernel 3.0.31-487742
 

viulian

Inactive Recognized Developer
Apr 6, 2011
419
411
hex.ro
Is there any output in dmesg related to the module not working ?

What error do you get ? I will try to build one tonight for your version of kernel - can you please post the output of mount command above when you are trying to connect ?
 

mrmrmrmr

Senior Member
Jan 14, 2007
2,543
252
Is there any output in dmesg related to the module not working ?

What error do you get ? I will try to build one tonight for your version of kernel - can you please post the output of mount command above when you are trying to connect ?

I don't get any error when I introduce the module with insmod.
And after that I can see the module added in "lsmod" output.
On dmesg, I grep "cifs" and nothing shows up.

So there is no problem in adding the module.

But when I try to use it with cifs manager, I get error "mount: No such file or directory"

Prior to 4.1.2 rom, I was able to use same app with SiyahKernel and its cifs module.

p.s:if I don't insmod the module I get a different error on cifs manager : "mount: No such device"

thx.

---------- Post added at 10:15 PM ---------- Previous post was at 10:04 PM ----------

oops, I've found the problem.

if I insmod also md4.ko and nls_utf8.ko, then it works !

but with the 4.1.1 rom and SiyahKernel, I didn't need that.
What's the difference ?

And how can I force insmodding other modules with cifs manager ?
(normally, cifs manager insmods cifs.ko automatically)
 
Last edited:

viulian

Inactive Recognized Developer
Apr 6, 2011
419
411
hex.ro
Excellent :)

About CIFS manager, it is not obvious that it can load multiple modules, but it can:

On the "Path to cifs.ko" when you edit it, you CAN actually add more modules if you separate them with semicolons like the label of the popup indicates:

/module1.ko:/module2.ko etc.

Please make sure md4 and nls come first, before cifs and that you use full paths just to be sure (but you can test if you want).
 

mrmrmrmr

Senior Member
Jan 14, 2007
2,543
252
ok; I've found the way for adding 2 module in cifs manager
entered " /mnt/sdcard/cifs/md4.ko;insmod /mnt/sdcard/cifs/cifs.ko" in cifs manager and now it's working.

But I still wonder how it was working in previous rom/kernel pair...
 

viulian

Inactive Recognized Developer
Apr 6, 2011
419
411
hex.ro
Well, it worked probably because the ROM was built in such a way that the /lib/modules had the correct paths containing the kernel versions (Linux like, but not the way it is on most Android phones) and then the modules could actually "ask" for their dependencies to be loaded so it was transparent for you.

One explanation. Maybe there are others, I don't know the ROM so it is just guess..

About CIFS, you don't need to have insmod command, just the path to each module separated by ':' Also you need nls if you have UTF8 characters in your shares names.
 

ercanmetin

Member
Mar 31, 2011
49
4
Fairfield, CT
Pls.. Guide me thru

Hi, I will be very happy if someone guides me thru this.
I am on N7100
Which of the files I should download and which folder to put them in.
I am trying to mount smb (DNS-323 is my NAS if needed)
My kernel information;

Board: smdk4x12
Product: t03gxx
Model: GT-N7100
Device: t03g
Build: JRO03C.N7100XXALJ1
samsung/t03gxx/t03g:4.1.1/JRO03C/N7100XXALJ1:user/release-keys
Manufacturer: samsung
Brand: samsung
CPU ABI: armeabi-v7a

Kernel
Linux version 3.0.31-259982 ([email protected]) (gcc version 4.4.3 (GCC) ) #1 SMP PREEMPT Tue Oct 2 02:04:58 KST 2012
 

xgutterratx

Senior Member
Sep 27, 2010
75
5
Since I have received the JB update, I have rebuilt the cifs.ko module for my kernel version 3.0.31-256827 as well as 3.0.31-204919
If you have other kernel versions, please let me know and I will try to build the modules for that specific version.

Good news is that patchs3k is not needed anymore! Samsung did the right thing and we don't need to patch the kernel at runtime.

Per @jfrm request, UTF-8 module is now included but DO NOT FORGET to add iocharset=utf8 as options when defining the share in CifsManager.

Screenshot_2012-06-07-21-01-56.png


Download

Use at your own risk!

For JB Kernel 3.0.31-368423

cifs_md4-368423.tar.gz

For JB Kernel 3.0.31-256827:

cifs_md4-256827.tar.gz

For JB Kernel 3.0.31-204919

cifs_md4-204919.tar.gz

------
Old topic below, related to the 4.0.1 versions / firmware

Attached you will find a bundle (including the cifs.ko module) that allows you to mount Samba shares on your Galaxy S3 phone. md4.ko module is also included.
You do not need to flash a different kernel, it works with the stock one!

Supported firmwares: XXALE8, XXALEF, ZSALED

Install

a) copy cifs_s3.tar.gz to your /sdcard folder
a) create folder /system/xbin/lib (after you remount your /system as read/write)
b) unpack the tar into that folder
c) execute script load_cifs.sh

Code:
cd /system/xbin/lib
tar xf /sdcard/cifs_s3.tar.gz 
./load_cifs.sh

The archive includes the patchs3k executable I have created that changes the live stock kernel to accept any module.
Without running the patchs3k file, no modules can be inserted ...
It means that you cannot use tools that insert the modules at reboot since they will fail if patchs3k is not executed before that.

For this, you will find the load_cifs.sh which is already written so that it can be executed from Script Manager at boot / as super user.

Then you need to use CifsManager (or other mount managers) to mount everything you want

Download

Use at your own risk!

For firmware: XXALE8, XXALEF

cifs_s3.tar.gz

For firmware: ZSALED

cifs_s3.ZSALED.tar.gz

will the is work with kernel 3.0.31-Siyah-1.8.4+
 

chriv

Senior Member
Mar 16, 2010
61
16
Charlotte, NC
Since I have received the JB update, I have rebuilt the cifs.ko module for my kernel version 3.0.31-256827 as well as 3.0.31-204919
If you have other kernel versions, please let me know and I will try to build the modules for that specific version

I have a Tab 2 10.1" running stock rooted JB (4.1.1).

The kernel is 3.0.31-523998:
Code:
[email protected]:/ $ uname -a
Linux localhost 3.0.31-523998 #1 SMP PREEMPT Thu Nov 29 14:35:14 KST 2012 armv7l GNU/Linux
[email protected]:/ $

Are you able to compile cifs.ko for that kernel? I'm not certain, but I don't think the device matters if the CPU, kernel version, and ABI are the same.

Either way, thanks. :confused:
 

Top Liked Posts

  • There are no posts matching your filters.
  • 10
    Since I have received the JB update, I have rebuilt the cifs.ko module for my kernel version 3.0.31-256827 as well as 3.0.31-204919
    If you have other kernel versions, please let me know and I will try to build the modules for that specific version.

    Good news is that patchs3k is not needed anymore! Samsung did the right thing and we don't need to patch the kernel at runtime.

    Per @jfrm request, UTF-8 module is now included but DO NOT FORGET to add iocharset=utf8 as options when defining the share in CifsManager.

    Screenshot_2012-06-07-21-01-56.png


    Download

    Use at your own risk!

    For JB Kernel 3.0.31-368423

    cifs_md4-368423.tar.gz

    For JB Kernel 3.0.31-256827:

    cifs_md4-256827.tar.gz

    For JB Kernel 3.0.31-204919

    cifs_md4-204919.tar.gz

    For JB Kernel 3.0.31-566833

    cifs_md4-566833.tar.gz

    For JB Kernel 3.0.31-742798

    cifs_md4-742798.tar.gz


    ------
    Old topic below, related to the 4.0.1 versions / firmware

    Attached you will find a bundle (including the cifs.ko module) that allows you to mount Samba shares on your Galaxy S3 phone. md4.ko module is also included.
    You do not need to flash a different kernel, it works with the stock one!

    Supported firmwares: XXALE8, XXALEF, ZSALED

    Install

    a) copy cifs_s3.tar.gz to your /sdcard folder
    a) create folder /system/xbin/lib (after you remount your /system as read/write)
    b) unpack the tar into that folder
    c) execute script load_cifs.sh

    Code:
    cd /system/xbin/lib
    tar xf /sdcard/cifs_s3.tar.gz 
    ./load_cifs.sh

    The archive includes the patchs3k executable I have created that changes the live stock kernel to accept any module.
    Without running the patchs3k file, no modules can be inserted ...
    It means that you cannot use tools that insert the modules at reboot since they will fail if patchs3k is not executed before that.

    For this, you will find the load_cifs.sh which is already written so that it can be executed from Script Manager at boot / as super user.

    Then you need to use CifsManager (or other mount managers) to mount everything you want

    Download

    Use at your own risk!

    For firmware: XXALE8, XXALEF

    cifs_s3.tar.gz

    For firmware: ZSALED

    cifs_s3.ZSALED.tar.gz
    1
    ZSALED can't use it.
    Unfortunatly, when I try to run insmod, I get this: insmod: init_module '/system/xbin/lib/cifs.ko' failed (Exec format error)
    1
    on firmwares: XXALEF works,
    Thank you so much!
    1
    tun.ko was my first choice before starting :) but I was surprised to see that is already precompiled in the stock kernel.

    You can just install the OpenVPN installer and Settings apps, copy over your certificates and so on and it will work.
    1
    Hello guys,

    I will shortly put a tutorial on how you can send me the details which would help create the patch.
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone