[krn.modules] cifs.ko module for Galaxy S3 Stock kernel - Galaxy S III Original Android Development

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.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
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

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)

@vasha100 - thanks for letting me know. I tested only on European one, XXALE8 ...
I will send you a PM and I can get it to run for your firmware too, not the module - the module stays as it is, but I will post another patchs3k file.

on firmwares: XXALEF works,
Thank you so much!

Thanks for the feedback, I have updated the main post - so that people could see what firmwares are supported. If the exact kernel image is used, chances are that the patchs3k will work.

thanks!

Nice work!

Thank you,
With help from fellow member vasha100 - I was able to test the release for ZSALED and confirmed it working too. Everything had to be recompiled, since the kernel is not exactly what runs on the other firmwares ..

Could you build tun.ko module? That will be great if you do this.

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.

updated the fw to XXALF5, the last official update for Russia (it is on wi-fi, accidentally pressed the install)
method of root CF-Root v6.3
Сopy cifs_s3.tar.gz - all the instructions ... execute script load_cifs.sh, restart your phone....
Сopy cifs_s3.ZSALED.tar.gz, execute script load_cifs.sh, wrote the script is executed ...
I go to the cifsmanager, run a share, write error (mount no such device)
need your help)

I have kernel XALEB
what can I do ?

Hello guys,
I will shortly put a tutorial on how you can send me the details which would help create the patch.

mrmrmrmr said:
I have kernel XALEB
what can I do ?
Click to expand...
Click to collapse
this has worked on my kernel XALEB when I run patchs3k.
But I really wonder the affect of patchs3k on the kernel. What does it really do ?
it doesn't modify the kernel but changes a parameter in /proc ?
now , I need to run this in each boot.
how can we automize it ?

@mrmrmrmr
The effects of patchs3k is that it cancels the checksum verifications of module symbols. This is done within the kernel and it can't be done just by changes within /proc filesystem.
As for adding support of other kernels not already supported, please do the following and post here the values as well as your firmware:
Code:
cat /proc/kallsyms | grep -A 1 check_version
and
Code:
uname -a
I will get them done in few days ...

Hi,
My baseband: I9300XXLE8
Build: IMM76D.I9300XXALEB
cat /proc/kallsyms | grep -A 1 check_version
Code:
c00b5200 t check_version
c00b52d0 t get_modinfo
--
c03cd0b0 t picolcd_check_version
c03cd188 t picolcd_probe
uname -a :
Code:
Linux localhost 3.0.15-554452-user #1 SMP PREEMPT Fri May 18 00:04:22 KST 2012 armv71 GNU/Linux
if you prepare a cifs.ko for these values, I assume I will not need to run patchs3k at every boot.
am I correct ?
Btw, I have a linux box with armv7 compiler. Can you tell me how to prepare the setup for compiling a kernel (or modules) for Galaxy S3 ?
is there a quick guide ?
Thanks.

Baseband: I9300XXLF5
Build: IMM76D.I9300XXALF5
uname -a
Code:
linux localhost 3.0.15-686526-user #1 SMP PREEMPT Thu Jun 7 20:04:56 kst 2012 armv71 GNU/Linux
cat /proc/kallsyms | grep -A 1 check_version
Code:
c00b5248 t check_version
c00b5318 t get_modinfo
--
c03cd574 t picolcd_check_version
c03cd64c t pricolcd_probe

mrmrmrmr said:
Hi,
My baseband: I9300XXLE8
Build: IMM76D.I9300XXALEB
cat /proc/kallsyms | grep -A 1 check_version
Code:
c00b5200 t check_version
c00b52d0 t get_modinfo
--
c03cd0b0 t picolcd_check_version
c03cd188 t picolcd_probe
uname -a :
Code:
Linux localhost 3.0.15-554452-user #1 SMP PREEMPT Fri May 18 00:04:22 KST 2012 armv71 GNU/Linux
if you prepare a cifs.ko for these values, I assume I will not need to run patchs3k at every boot.
am I correct ?
Btw, I have a linux box with armv7 compiler. Can you tell me how to prepare the setup for compiling a kernel (or modules) for Galaxy S3 ?
is there a quick guide ?
Thanks.
Click to expand...
Click to collapse
I'd appreciate an answer

wow how many kernels are out there ??
Kidding I will do them this weekend..

Hi,
can you give me a more detailed description how to do this? Is it done via file explorer and terminal app on the phone itself? Because i tried it this way and cant create the required folder.
Sorry for the stupid question, but Im quit new to this stuff.

Related

[Q] Need help compiling / building own kernel (zImage)

Hello dev community
I am currently trying to build my own kernel / zImage, but for some reason it doesn't work, when I flash my zImage the SGS2 crashs at the bootscreen with the yellow triangle.
Not even the battery animation when charging while off works anymore *lol*
Here is what I did so far:
extracted a stock initramfs from a samsung stock kernel
got the Samsung kernel sources and extracted on my PC
got the codesourcery toolchain and installed it
edited the path to the toolchain into kernel/Makefile
ran
make c1_rev02_defconfig (as stated in the readme.txt of the src download)
set the path to the extracted iniramfs files in the config
ran
make zImage
It eventually tells me "kernel zImage ready at ...."
padded with 0x00s to the 8MiB size, .tar'ed and flashed via Odin
But it doesn't boot.
When I throw my zImage at the initramfs extractor script, I get the proper initramfs files dumped, so they seem to be fine.
Searched around this forums for two days now, found a few "zImage repacker scripts" but none work or clear up any of my questions.
Any hints on what I missed or did wrong are appreciated
And while we're at it, another question:
At new FW builds, does the actual kernel itself change too, or is it only changes in the initramfs? Because there is only one set of sources from Samsung.... so I assume the actual kernel stays the same and using the initramfs of the targetted FW will suufice?
Why did you pad it up to 8mb?
also, when setting the initramfs source, did you set these to you uid you are compiling with?
CONFIG_INITRAMFS_ROOT_UID=1000
CONFIG_INITRAMFS_ROOT_GID=1000
Hm, padded to 8MB as all kernels are (padded to) 8MB, aren't they?
Tried flashing an unpadded version too, still no go.
And yes, UID and GID are set to the ones my user is running as....
Close to the end of the compiler run, I get a "found 14 module section missmatches" kind of message - could that have something to do with my zImage not working? And how would I fix that?
Oh c'mon, it can't be that hard, so many people are making their own zImages.... what am I missing here.... :-/
First of all, you cant just use a stock initramfs image, shove it into another kernel and expect it to work. There are kernel modules in there which need to be updated first before you do the last "make zImage".
Try this:
0. make sure your config is correct. you should copy c1_rev02_defconfig from inside arm/ to source_root/.config and do a "make oldconfig". Then adjust your configs as necessary ("make menuconfig" etc)
1. "make modules"
2. "INSTALL_MOD_PATH=~ make modules_install"
3. goto your home dir and pick out the modules and put them into the path of your initramfs files (/lib)
4. finally, make zImage.
5. theres no need to pad to 8mb. that is an urban legend
OK, did all that.... still no go.... :-/
Try this script:
Code:
#!/bin/bash
# Set Default Path
TOP_DIR=$PWD
KERNEL_PATH=/home/neophyte-x360/kernel/GALAXYS2/2.6.35.7
# TODO: Set toolchain and root filesystem path
TAR_NAME=zImage.tar
TOOLCHAIN="/home/neophyte-x360/android/system/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/arm-eabi-"
# TOOLCHAIN="/home/neophyte-x360/toolchain/bin/arm-none-eabi-"
ROOTFS_PATH="/home/neophyte-x360/kernel/GALAXYS2/initramfs-SGS2"
echo "Cleaning latest build"
make ARCH=arm CROSS_COMPILE=$TOOLCHAIN -j`grep 'processor' /proc/cpuinfo | wc -l` clean
cp -f $KERNEL_PATH/arch/arm/configs/c1_rev02_defconfig $KERNEL_PATH/.config
make -j4 -C $KERNEL_PATH oldconfig || exit -1
make -j4 -C $KERNEL_PATH ARCH=arm CROSS_COMPILE=$TOOLCHAIN || exit -1
cp drivers/bluetooth/bthid/bthid.ko $ROOTFS_PATH/lib/modules/
cp drivers/net/wireless/bcm4330/dhd.ko $ROOTFS_PATH/lib/modules/
cp drivers/samsung/j4fs/j4fs.ko $ROOTFS_PATH/lib/modules/
cp drivers/samsung/fm_si4709/Si4709_driver.ko $ROOTFS_PATH/lib/modules/
cp drivers/scsi/scsi_wait_scan.ko $ROOTFS_PATH/lib/modules/
cp drivers/samsung/vibetonz/vibrator.ko $ROOTFS_PATH/lib/modules/
make -j4 -C $KERNEL_PATH ARCH=arm CROSS_COMPILE=$TOOLCHAIN || exit -1
# Copy Kernel Image
cp -f $KERNEL_PATH/arch/arm/boot/zImage .
cd arch/arm/boot
tar cf $KERNEL_PATH/arch/arm/boot/$TAR_NAME zImage && ls -lh $TAR_NAME
And try with other initramfs, maybe could be this.
PD: I forgot that with my script you have to select your initramfs inside .config
Very interesting thread!
Im about to study computer science and software engineering for 3 years in august.
Hoping/wishing/expecting to get into this eventually!
put this in your build script:-
export LOCALVERSION="-I9100XWKE7-CL215725"
this is just an example set its value to the same as the initramfs you used, e.g. the magicver in the modules.
sounds like your initramfs are incomplete...or more likely your toolchain is not quite right. even without recovery, your zimage should be 6-7mb...(no padding, and there is no need to)
OK, done a clean rebuild, taking care of everything you guys said:
made new initramfs dump from a stock zImage
make mrproper
make c1_rev02_defconfig
make menuconfig - set the paths/prefixes for toolchain, localversion and initramfs (also set my users UID and GID for mapping to UID/GUI 0) there, left everything else untouched and at defaults
make
copied the freshly built modules into my initramfs dir (checked with a hexeditor for the proper versionmagic, looks OK)
make zImage
resulting zImake size: ~5.7MB and no go, still doesn't boot.
I'll try now with another toolchain (using the last one available for d/l so far, just got the 2009-something one mentioned in the sources readme and going to try to use that one now) as well as different initramfs dumper....
I have not much hope this will change the outcome, but it's at least worth a try....
// EDIT (a few hours later xD)
SUCCESS
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
(anyone knows what the #9 is? where it comes from, what it says?)
I *finally* managed to get a completely self built kernel to boot \o/
So, what was it that played showstopper the whole time: THE TOOLCHAIN!
I had the latest (2011-something) version of the CodeSourcery toolchain installed - that does not seem to be a good idea.
Did exactely what I did before, but now with the 2009q3 version installed (like the readme of the source states) - and tadaa, it works!
// EDIT 2
Figured out the #9 as well, it's the build number / version; how many times I ran "make" since the last "make mrproper"
LET THE MODDING BEGIN (now the fun starts)
Glad to see someone's happy. I'm also trying to compile a kernel from source. However, mine's an I9100G. Managed to compile, flash and boot up my phone, but battery status and Wifi don't work. After looking through the dmesg log, apparently the battery driver is not being initialised. I wonder if anyone can help me? Maybe someone with knowledge of the OMAP platform?
aidfarh said:
Glad to see someone's happy. I'm also trying to compile a kernel from source. However, mine's an I9100G. Managed to compile, flash and boot up my phone, but battery status and Wifi don't work. After looking through the dmesg log, apparently the battery driver is not being initialised. I wonder if anyone can help me? Maybe someone with knowledge of the OMAP platform?
Click to expand...
Click to collapse
You can give me initramfs?
I cqn give it a try.
Sent from my GT-I9100
How to
HellcatDroid said:
Hello dev community
I am currently trying to build my own kernel / zImage, but for some reason it doesn't work, when I flash my zImage the SGS2 crashs at the bootscreen with the yellow triangle.
Not even the battery animation when charging while off works anymore *lol*
Click to expand...
Click to collapse
Could you please give a few mn to write a min How To? I would like to build my own, but as a noob, I am a litle lost in all the info I gathered.
It would be nice to profit from your experience.
Or maybe do you have any good links?
TY
netchip said:
You can give me initramfs?
I cqn give it a try.
Sent from my GT-I9100
Click to expand...
Click to collapse
Well, if you think it can help, here's the download link for my initramfs:
http://dl.dropbox.com/u/13796854/initramfs.zip
It's for an I9100G, though. Do you have one to test with?
aidfarh said:
Well, if you think it can help, here's the download link for my initramfs:
http://dl.dropbox.com/u/13796854/initramfs.zip
It's for an I9100G, though. Do you have one to test with?
Click to expand...
Click to collapse
I haven't one for testing.
I am a kernel developer here for SGS2, check the development part.

[modules][play??][fw:4.0.a.2.368] usb-otg {doesnt work... Sorry...}

for now it seems this will not be possible for Xperia Play... SE kernel sources are incomplete/broken for Xperia Play to support FULL USB-OTG...
since i dont have this device i will not be working on fixing the SE sources for this...
may be someone with the device can get it working with lots of fixes & testing...
sorry to disappoint u guys... i tried...
[ screenshots ]
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
[ requirements ]
Xperia Arc (Neo?/Play?) on FW: 4.0.A.2.368
preferably rooted + busybox installed
USB-OTG hardware cable
Terminal Emulator app
[OPTIONAL] adb Wireless app
[ tested on ]
Xperia Arc Stock FW: 4.0.A.2.368 with DooMKernel v08
[ how to ] (general instructions for modules)
download the modules and push the modules to /system/lib/modules/
use adb shell or terminal emulator to enter following code/commands
Code:
su
cd/system/lib/modules/
busybox insmod usbhid.ko
busybox insmod usbmouse.ko
busybox insmod usbkbd.ko
busybox insmod usb-storage.ko
check if all modules are live are not:
Code:
lsmod
done the modules are LIVE!
[IMP] u will have to manually reload the modules on EVERY boot... unless u use start-up scripts which will take care of this!
[ how to ] (instructions for usb-storage) [simpler way]
download app: http://android.gval.biz/download/Q5_USB_Memory_Manager.apk
follow instructions: http://android.gval.biz/Q5_USB_Menory_Manager.php
the usb storage device should now be mounted to /usb_storage/
u will need to use RootExplorer for this to work
[ how to ] (instructions for usb-storage) [manual way]
before u begin/connect device there are few things which need to be done
creating necessary directory structure
Code:
su
cd /sdcard/
mkdir usbStorage
now connect the usb storage device via usb-otg cable to phone
now enter the following command:
Code:
dmesg
at the last part u will see some info of connected device (an if it was rejected due to power issues)
now enter
Code:
ls -l /dev/block/sd*
u will get output similar to the one posted below
note if the last part: /dev/block/sda1
finally mount this device
Code:
mount /dev/block/sda1 /sdcard/usbStorage
if u get no error then enjoy usb storage is now mounted
to unmount usbstorage
Code:
umount /dev/block/sda1
[ donations ]
if u feel that this work has helped u OR u think that the work i put into making this is worthy of donations, then click on the following link for buying me some coffee/beer/etc
PAYPAL DONATION LINK
[ download links ]
USB-STORAGE
USB-HID
USB-KEYBOARD
USB-MOUSE
[ known issues ]
usb mouse works but there is no cursor... but u can move around and select (left click on stuff)
when using usb-storage mode some devices will not be mountable if:
they require more power (u can check this in dmesg)
they have filesystem not supported by ur current kernel
sometimes the mounted usb-storage files wont appear using some apps... i have tested it to be wrking using RootExplorer... though it will work in adb shell/terminal emulator also...
[ troubleshooting ]
when u post any error/issue please include the full output of dmesg command (adb shell dmesg > dmesg_log.txt) OR (dmesg > /sdcard/dmesg_log.txt)
P.S.: all these features will be included in next version of DooMKernel for all supported Xperia 2011 devices
enjoy!
reserved reserved
Woow!! very nice.
Thank you very much for your work doom. I ll test this when I get a cable
I have downloaded the files on my phone by long pressing and the save link. It downloaded as txt files. Then I simply renamed the files to .ko is that the correct way? I moved the files with rootexplorer and set permissions as the bcm4329.ko. But when using terminal emu it won't insmod it says:
export PATH=/data/local/bin:$PATH
$ export PATH=/data/local/bin:$PATH
$su
# cd /system/lib/modules
# ls
usbmouse.ko
usbkbd.ko
usbhid.ko
usb-storage.ko
bcm4329.ko
# busybox insmod usbhid.ko
insmod: can't insert '/system/lib/modules/usbhid.ko': unknown symbol in module or invalid parameter
#
Regards Dousan...
e: re-downloaded the files on my laptop and they downloaded as .ko files. Then pushed them with adb but i still get the same error?
I have busybox installed in /system/xbin and it's 1.18.4. The newest fw .368 and your kernel.
Dousan said:
I have downloaded the files on my phone by long pressing and the save link. It downloaded as txt files. Then I simply renamed the files to .ko is that the correct way? I moved the files with rootexplorer and set permissions as the bcm4329.ko. But when using terminal emu it won't insmod it says:
export PATH=/data/local/bin:$PATH
$ export PATH=/data/local/bin:$PATH
$su
# cd /system/lib/modules
# ls
usbmouse.ko
usbkbd.ko
usbhid.ko
usb-storage.ko
bcm4329.ko
# busybox insmod usbhid.ko
insmod: can't insert '/system/lib/modules/usbhid.ko': unknown symbol in module or invalid parameter
#
Regards Dousan...
Click to expand...
Click to collapse
try all the others too... if all give same error i will compile again...
DooMLoRD said:
try all the others too... if all give same error i will compile again...
Click to expand...
Click to collapse
The same error on all 4.
Regards Dousan...
Dousan said:
The same error on all 4.
Regards Dousan...
Click to expand...
Click to collapse
ok... i will reupload all those specifically compiled for Play...
Great
Will you post, when at some point, they're re-uploaded?
Regards Dousan.
Dousan said:
Great
Will you post, when at some point, they're re-uploaded?
Regards Dousan.
Click to expand...
Click to collapse
i am at work mate
will try to compile it here and see if i can upload it
DooMLoRD said:
i am at work mate
will try to compile it here and see if i can upload it
Click to expand...
Click to collapse
No hurry mate, if you can that's great but no sweat if you can't
Regards Dousan...
Dousan said:
No hurry mate, if you can that's great but no sweat if you can't
Regards Dousan...
Click to expand...
Click to collapse
in anycase i will re-compile & upload it once i get back home...
Another great work Doom
seems SE kernel sources are incomplete for Xperia Play to support FULL USB-OTG...
since i dont have this device i will not be working on fixing the SE sources for this...
may be someone with the device can get it working with lots of fixes & testing...
sorry to disappoint u guys... i tried...
No worries. you've done a great job anyways, and hopefully you've learnt things. that is what counts
I'm sure Blagus will benefit from this, too.
Logseman said:
No worries. you've done a great job anyways, and hopefully you've learnt things. that is what counts
I'm sure Blagus will benefit from this, too.
Click to expand...
Click to collapse
ya i have talked to him about this... so may be he can get it working...
thanks for the support!
No worries mate You did try and it's fully understandable you won't develop any further. Thanks for the effort and it might be that blagus can carry on, would be great
Regards Dousan...
DooMLoRD said:
seems SE kernel sources are incomplete for Xperia Play to support FULL USB-OTG...
since i dont have this device i will not be working on fixing the SE sources for this...
may be someone with the device can get it working with lots of fixes & testing...
sorry to disappoint u guys... i tried...
Click to expand...
Click to collapse
Don't worry Doom,you're great
apparently Xperia Play is not supported by official SE dock
http://www.sonyericsson.com/cws/pro...w/livedock?cc=gb&lc=en#view=compatible_phones
The Play has its own dock, the DK300. I have one, if you want I can use the Play plugged in if you need any data.
Any chance of a retry on this Doom, now you have the device?

Kernel Modules for Xperia 2011 ICS v4.1.B.0.587: fuse.ko,usb-storage,cifs,ntfs,ext4..

Information and Modules description
I was in the need to add some missing kernel modules to my Xperia Mini Pro sk17i with v4.1.B.0.587, and I couldn't find modules compiled for that ICS kernel version, so I decided to build them myself.
All modules have been compiled from official sony Xperia v4.1.B.0.587 kernel sources, using Android NDK r5, and they should be fine with any ICS based Xperia 2011 device (with that kernel version).
This is the list of modules, with some interesting programs using them:
fuse.ko: Cryptonite (used to create encrypted EncFS or Truecrypt volumes, adds support to mount drives so that are visibile to the whole Android system. Note: Cryptonite is not currently able to load the module automatically, you need to load it from Terminal Emulator..se more below)
usb-storage.ko, nls_utf8.ko, ntfs.ko (compiled with write support, currently untested): USB OTG Helper (used to mount external USB drives with USB On The Go cables).
cifs.ko, slow-work.ko, md4.ko: CifsManager (used to mount network shares)
ext4.ko, jbd2.ko: if you wish to use the EXT4 filesystem
Installation Instructions
Attached to this post you will find a ZIP that can be used along with CWM Recovery to install the modules in system.
Download the module, put it inside you SD card, reboot your phone in CWM (which you can install with the Xperia CWM Auto-Installer) and select install zip from sdcard, and browsed to the ZIP. Reboot your phone when install finishes.
Loading Modules
No module is automatically loaded at system startup: this saves your memory and battery (some of those modules are known to drain your battery if always loaded).
To manually load a module you have to open the Android Terminal Emulator and tap:
Code:
su
insmod /system/lib/modules/MODULENAME.ko
where MODULENAME is the name of the module you want to load.
Other useful commands:
Code:
lsmod
to see currently running commands
Code:
rmmod MODULENAME.ko
to unload a module.
If you wish to manually load a module at phone startup you should use init.rd or any other method (?) to run custom scripts at startup.
Load Order
Some modules need to be loaded in a specific order:
slow-work.ko must be loaded before cisf.ko
jbd2.ko must be loaded before ext4.ko
Other Firmware Versions
I've released the same package for other firmware versions, click on the firmware version to go to the specific thread:
GB v4.0.2.A.0.58 Kernel Modules package by zxp
Changes
v1 - 2012.10.04
============
- First release
Terminal emulator says cannot allocate memory.
Oh god, why??
Sent from my Nokia 3310 using Tapatalk 2
chepoz said:
Terminal emulator says cannot allocate memory.
Oh god, why??
Sent from my Nokia 3310 using Tapatalk 2
Click to expand...
Click to collapse
Terminal emulator doesn't start? Or is the "insmod" command output telling you that it cannot allocate memory? Either way it seems like your RAM is full and there is not enough space to load the module(s) you want to load.
zxp said:
Terminal emulator doesn't start? Or is the "insmod" command output telling you that it cannot allocate memory? Either way it seems like your RAM is full and there is not enough space to load the module(s) you want to load.
Click to expand...
Click to collapse
No, it says like that after I install some modules. Some of them running well, n some says like that.
So maybe my ram not much left to run those modules. Thanx for answering. :thumbup:
Sent from my Nokia 3310 using Tapatalk 2
Works on Sony wt19i
Thank you,,,
I've successfully accessed the usb pendrive using this simple method. It worked for Sandisk Cruzer Blade pendrives.....
But I can not access my transcend jetflash 700 16 GB pendrive...
If there any solution for this....then reply...
is the slow-work.ko still needed for ICS? from what I searcher it was needed for froyo (2.2)
Warl0rd said:
is the slow-work.ko still needed for ICS? from what I searcher it was needed for froyo (2.2)
Click to expand...
Click to collapse
It's a while since I compiled those modules and I may recall wrong, but...as far as I can remember it was related to the Linux Kernel version on which our Android OS ROM is based. That is, the Xperia 2011 lineup uses Kernel 2.6 (both on Android 2.3 and 4.0), which requires slow-work to be compiled; if it was based on Linux Kernel v3.x then slow-work.ko wouldn't be needed.
i have an error
when im going to load modules,this is what's happening
export PATH=/data/local/bin:$PATH
a/local/bin:$PATH <
[email protected]:/ $ su
ib/modules/usb-storage.ko <
insmod: init_module '/system/lib/modules/usb-storage.ko' failed (File exists)
/lib/modules/ntfs.ko <
insmod: init_module '/system/lib/modules/ntfs.ko' failed (File exists)
255|[email protected]:/ #
please help me
i'm getting the same error
i'm on .587 stock kernel & rom. cant load modules
fixed!
sorry for disturbing u guys. I figured it. that message appears because the module is running. its my fault that I didn't check whether its running or not.
tharu_roxx said:
when im going to load modules,this is what's happening
export PATH=/data/local/bin:$PATH
a/local/bin:$PATH <
[email protected]:/ $ su
ib/modules/usb-storage.ko <
insmod: init_module '/system/lib/modules/usb-storage.ko' failed (File exists)
/lib/modules/ntfs.ko <
insmod: init_module '/system/lib/modules/ntfs.ko' failed (File exists)
255|[email protected]:/ #
please help me
Click to expand...
Click to collapse
It seems like those modules are already loaded in memory, as it happened to RavinduSha.
Try lsmod: if usb-storage.ko and ntfs.ko are listed by lsmod, they are already loaded, and that's why you get those errors.
Can anyone compile modules for dvb-t dongle rtl2832u like those available here?
http://forum.xda-developers.com/showthread.php?t=1841759
Or at least point me in the right direction
btw modules are working fine
Problem Solved!!!
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Yep...these modules work fine!!!! But i couldn't mount usb storage device using the OTG Helper app.so I tried stick mount pro(with above modules,no need to load them) It worked!!!! [this happened when I'm using the stock rom & the kernel,but now my kernel supports them by default ,so no worries!! ]
Current Device : MT11i Xperia Neo V
ROM : Xperia Ultimate HD ™
Build Number : 2.0.3
Kernel : Suave Kernel
Root Status : Rooted
Bootloader : Unlocked
Previous Devices : Samsung Galaxy Y
GT-5360(Sold)
Sent from my MT11i using XDA Premium HD app
Hello zxp,
I want to learn to build some modules by myself because I want to try to build some drivers for cameras, scanner, etc... Can you tell me about where you've got the source code to build or the way to build it?
I've downloaded source code of my android on developer.sonymobile.com. When I extracted it I saw the folder structure like "kernel/drivers/usb". Did you build the modules from source code of that folder?
When i type insmod in the terminal
It said invaild file format can anyone help,please??
Sent from my SK17i using xda premium
zack871024 said:
When i type insmod in the terminal
It said invaild file format can anyone help,please??
Sent from my SK17i using xda premium
Click to expand...
Click to collapse
What?? It's impossible,:-o
Sent from my MT11i using Tapatalk 2
I dont know why either
Anyone help?? Thanks
postimage.org/image/x33tabkc5
Sent from my SK17i using xda app-developers app
zack871024 said:
I dont know why either
Anyone help?? Thanks
postimage.org/image/x33tabkc5
Sent from my SK17i using xda app-developers app
Click to expand...
Click to collapse
Have you rooted ur phone?
Sent from my MT11i using Tapatalk 2
tharu_roxx said:
Have you rooted ur phone?
Sent from my MT11i using Tapatalk 2
Click to expand...
Click to collapse
Are you kidding??I'm not that stupid=) Of courseHelp me!! By the way,i got my bravia engine 2 working again cheers!!
Sent from my SK17i using xda app-developers app

[Q] Can't compile Heimdall

Hello, I'm trying to follow Cyanogen's wiki to install CWM.
The steps are: 1) download zImage, 2) download heimdall, 3) flash zImage. I'm stuck at number 2.
I tried with the suggested heimdall_v1.4rc1_mac.zip (sorry I can't post outside links), but the kext inside does not load correctly.
So now I'm trying to compile it myself. I git cloned the repo, installed dependencies, successfully made libpit. Going on with Heimdall.
Code:
cd heimdall
./configure
make
[...]
cc1plus: error: unrecognized command line option "-std=c++0x"
I don't know exactly what this means, but I edited Makefile and substituted every g++ (i686-apple-darwin11-llvm-g++-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00)) occurrency with clang -v.
Now I'm stuck on:
Code:
[...]
Undefined symbols for architecture x86_64:
"std::string::find_first_of(char const*, unsigned long, unsigned long) const", referenced from:
[...]
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [heimdall] Error 1
make: *** [all] Error 2
If it helps you, there are a lot of:
Code:
ignoring nonexistent directory "/usr/include/c++/4.2.1/i686-apple-darwin10/x86_64"
ignoring nonexistent directory "/usr/include/c++/4.0.0"
ignoring nonexistent directory "/usr/include/c++/4.0.0/i686-apple-darwin8/"
ignoring nonexistent directory "/usr/include/c++/4.0.0/backward"
Running on MacBookPro7,1, Lion 10.7.5, Xcode 4.5.1
EDIT: I also tried installing heimdall 1.3.1 dmg, but installation failed (kernel module couldn't be installed).
bump
bump
bump
what compiler are you using? If GCC what version of GCC are you using? c++0x / c++11 support has only been added starting with gcc v4.3
Plod72 said:
what compiler are you using? If GCC what version of GCC are you using? c++0x / c++11 support has only been added starting with gcc v4.3
Click to expand...
Click to collapse
GCC appears only in CCDEPMODE and CXXDEPMODE. For the rest I'm using clang.
i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00)
Click to expand...
Click to collapse
Apple clang version 4.1 (tags/Apple/clang-421.11.66) (based on LLVM 3.1svn)
Target: x86_64-apple-darwin11.4.2
Thread model: posix
Click to expand...
Click to collapse
bump
bump
bump
Why dont you flash a custom kernel? They have cwm preinstalled... or.. maybe im missing something?
Sent from my GT-I9100 using xda app-developers app
Spiralzz said:
Why dont you flash a custom kernel? They have cwm preinstalled... or.. maybe im missing something?
Click to expand...
Click to collapse
Don't I need heimdall to flash a kernel?
vipervault said:
Don't I need heimdall to flash a kernel?
Click to expand...
Click to collapse
Use odin. Very easy and simple.
Sent from my GT-I9100 using xda app-developers app
Lol, you guys been at it since 1/25.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Sent from the little guy
I can't use odin, I don't have Windows.
vipervault said:
I can't use odin, I don't have Windows.
Click to expand...
Click to collapse
No need to compile heimdall.
Download heimdall from here: http://www.glassechidna.com.au/products/heimdall/
The normal heimdall uses a terminal I believe. The frontend one has a gui like Odin and should be easy to use.
Edit: Don't download the latest (1.3.2). Download the previous version, since it is stated that the latest one broke compatibility. Ive never used heimdall though, so I cant guide you further.
Sent from my GT-I9100 using xda app-developers app
I know there are prebuilt heimdall but the kernel module inside does not work.
That's why I'm compiling it. Is there anybody that can help me on that?
vipervault said:
I know there are prebuilt heimdall but the kernel module inside does not work.
That's why I'm compiling it. Is there anybody that can help me on that?
Click to expand...
Click to collapse
Just use another PC. You're going through a lot of hassle. Or simply download Mobile Odin (pro) app to flash. That's easiest and safe to use.
Sent from my GT-I9100 using xda app-developers app
Thank you guys I know how to flank this problem. I'd just like to receive your help to solve this compilation issue.
vipervault said:
Hello, I'm trying to follow Cyanogen's wiki to install CWM.
The steps are: 1) download zImage, 2) download heimdall, 3) flash zImage. I'm stuck at number 2.
I tried with the suggested heimdall_v1.4rc1_mac.zip (sorry I can't post outside links), but the kext inside does not load correctly.
So now I'm trying to compile it myself. I git cloned the repo, installed dependencies, successfully made libpit. Going on with Heimdall.
Code:
cd heimdall
./configure
make
[...]
cc1plus: error: unrecognized command line option "-std=c++0x"
I don't know exactly what this means, but I edited Makefile and substituted every g++ (i686-apple-darwin11-llvm-g++-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.11.00)) occurrency with clang -v.
Now I'm stuck on:
Code:
[...]
Undefined symbols for architecture x86_64:
"std::string::find_first_of(char const*, unsigned long, unsigned long) const", referenced from:
[...]
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [heimdall] Error 1
make: *** [all] Error 2
If it helps you, there are a lot of:
Code:
ignoring nonexistent directory "/usr/include/c++/4.2.1/i686-apple-darwin10/x86_64"
ignoring nonexistent directory "/usr/include/c++/4.0.0"
ignoring nonexistent directory "/usr/include/c++/4.0.0/i686-apple-darwin8/"
ignoring nonexistent directory "/usr/include/c++/4.0.0/backward"
Running on MacBookPro7,1, Lion 10.7.5, Xcode 4.5.1
EDIT: I also tried installing heimdall 1.3.1 dmg, but installation failed (kernel module couldn't be installed).
Click to expand...
Click to collapse
Hi,
you have probably solved it already, but when I got such error messages the solution was to set certain environment variables before calling ./configure
export CC=clang
export CXX=clang++
export CFLAGS="-I/usr/include/ -I/sw/include/"
export LDFLAGS="-L/usr/lib -L/sw/lib/"
I used fink to download and compile libusb1 (with version 1.0.8) prior to compile heimdall. In case you use macports, use the correct include and lib dirs instead of /sw/include and /sw/lib. In my case I didn't have to change anything in the original Makefile.
The only frustration with this heimdall was that the --primary-boot option did not work properly, so I had to skip --repartition and rewriting the primary boot partition with boot.bin.
you need a newer GCC to get it use Macports. if you do not have it install it. after that the command for the newer version is
Code:
sudo port install gcc47
if you want gcc 4.7
after you have the new version you need to set it to default and hope that heimdall compiler choose it! to do so you have to do so:
Code:
port select --list gcc
Available versions for gcc:
gcc42
llvm-gcc42
mp-gcc47
none (active)
if you have more than one gcc then you have more then one version of gcc from xcode. the mp-gccxx is the macports version. now we will set itto default:
Code:
sudo port select --set gcc mp-gcc47
Password:
Selecting 'mp-gcc47' for 'gcc' succeeded. 'mp-gcc47' is now active.
now you should had setted as default the gcc47 and compiling heimdall should work!
edit: i tried. i get all the way to
Code:
sudo make install
but then get:
Code:
cc1plus: error: unrecognized command line option "-std=c++0x"
probably benjamin setted the source to always use xcodes version of gcc that do not suport it.

problem with Wiko Sunset after flashing kernel

Hi,
I am a new user and I have a problem flashing kernel to my phone;I have a Wiko Sunset Phone:
Hardware : MT6572
Model : SUNSET
Build number : ALPS.KK1.MP6.V1
Build date UTC : 20150316-123627
Android v : 4.4.2
Baseband v: MOLY.WR8.W1315.MD.WG.MP.V36, 2014/03/29 17:48
Kernel v : 3.4.67 ([email protected]) (gcc version 4.7 (GCC) ) #1 SMP Mon Mar 16 20:33:28 CST 2015
I have recompiled kernel present in package SUNSET_OpenSource56465.zip with the command: ./mk wiko n k;the kernel is compiled without error but when I flash it, the phone display a white screen and then reboot continuously;I'm using as ramdisk that present in stock firmware
Any idea?
Thank you
Hello Biasi,
Your kernel work with little modification :
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Let me 10 min to go home, i will explain you what i do.
Bye
PS : it's not very good to build as root but it's not the problem
Biasi,
I found a bug in MTKIMG, i try to repack your kernel and the Sunset reboot continously, so i try to repack my own compiler kernel "kernel_wiko.bin" and Arg...:crying: Sunset reboot continously too.... But i run my own kernel for a while so i'm very confused !
So I remove the MTK header of my kernel and YipHa, Sunset boot is OK , i do the same with your kernel, and hurray, Suset boot OK too !
Here is the detailled procedure :
I dump my ROM with SPFlashTools
I unpack my original boot.img with MTKIMG
Code:
./mtkimg.exe unpack myboot.img
I copy/paste your kernel "kernel_wiko.bin" in to the directory
I remove the first 512 bytes (MTK header)
I repack the boot.img with MTKIMG
Code:
./mtkimg.exe repack boot.img -k kernel_wiko.bin
I reflash only the boot partition with the new boot.img
The Sunset boot well, enjoy !
This mean MTKIMG not handle well a kernel that already got MTK header but handle well a "Linux ARM zImage".
Thanks to point me this problem, i will investigate and correct the MTKIMG immediately.
Could you try to repack your kernel with the zImage directly not the kernel_wiko.bin (zImage is in you OBJ directory of your kernel build tree i dont remember the exact directory name) and let me know if this work.
Hop this help
I have repacked my kernel following your instructions and then flashed it with SP Flash Tool but the phone continue to reboot;can you attach your boot.img with my kernel? so I try it on my phone
Ok i will do now
Here you can find :
Your kernel without MTK header
View attachment biasi_kernel_without_header.zip
Working boot.img packed with your kernel
View attachment biasi_kernel_boot_img.zip
Hop this help
PS1 : Don't forget to click on Thanks button on my post(s)
PS: What mean "mao1" ?
I flashed it but phone continue to reboot with a white screen,very strange.
I'm using SPFlashTool 5.1516 to flash the boot.img
mao1 is a short name of invention that I have assigned to my development server
I use SPFlashTool v5.1516 too.
Did you flash only the BOOTIMG partition or the wall ROM ?
What is the version of your actual ROM ? (Wiko parameters version sucks, enter to phone : *#563412*# to get right version).
My Sunset come with V11 (4.4.2) after i download the offical ROM on Wikomobile site and flash it, i'm now on V17 (4.4.2).
I see uboot difference, preloader, etc... Be sure the rest of your ROM is in V17 accordly to your kernel build
I forgot to update firmware to new version, I did not know that it was necessary for kernel flash thanks a lot and sorry if I wasted your time
now I'm downloading the update and I'll tell you something as soon as I finished
No problem for time, you help me to find a bug in MTKIMG
And dont forget to dump your original ROM (SPFlashTool do it well)
Exemple of the "version suck" on Wiko, this is the same Sunset without modification :
From parameters :
From *#563412*# call
PS: In my country MAO mean "Music assisted by computer" so i think you are a music composer
Ok,
I correct the bug on MTKIMG, now you can repack a kernel and ramdisk with or without MTK header.
Could your try the MTKIMG V0.42 and tell me in the official thread (http://forum.xda-developers.com/android/development/tools-unpack-repack-boot-img-utility-t3154621) if all work correctly now ?
Thanks in advance
I had the version 15 before the update
now I have update to 17 and I have flashed kernel but continue to reboot with white image :crying:
Did you try the "biasi_kernel_boot_img.zip" from previous post ?
Did you do a wipe cache and wipe data ?
Could you post the scatter file you use ?
I tried to flash "biasi_kernel_boot_img.zip" and to do wipe cache and wipe data but with no success
Your scatter file is strictly identical of my scatter file.
I repack your kernel_wiko.bin with MTKIMG 0.42 and it work well !
Try this :
1 - Reflash the whole official ROM partition V17
2 - Be sure Sunset boot OK
3 - Load the scatter into SpFlashTool
4 - Uncheck ALL except BOOTIMG partition
5 - UNZIP biasi_kernel_boot_img.zip
6 - Click on the file at right of BOOTIMG, offset, etc... and be sure biasi_kernel_boot.img is selected
7 - Click on download
8 - Plug our cable
9 - Wait for transfet
10 - unplug the cable
11 - Check if it's boot
I will do exactly the same procedure now and i tell you the result
---------- Post added at 03:14 ---------- Previous post was at 03:04 ----------
Whole official ROM flashed : Kernel version 3.4.67 [email protected] #1 Wed Apr 22 14:44:08 CST 2015
I will flash the biasi_kernel_boot.img only and let you known...
All is OK !
Sunset boot OK !
I'm going to sleep, it's 3n28 in my country, i'm tired and have no more idea for instance.
Try to unpack your working boot.img and repack it with MTKIMG 0.42, if the boot is ok, replace with your kernel_wiko.bin and repack. This ensure you there is no ID verification/collision or something like that... (Be sure you use V0.42)
I have done the same procedure with no success;now I go to sleep and tomorrow I will continue to debug the problem
thanks for your help
Ok, i will take a look here tomorrow, and i sleep on it
I have formatted the whole flash and then I have flashed the preload.bin,lk.bin and boot.img but the phone continue to reboot
Can you attach your preload.bin (PRELOADER) and lk.bin (UBOOT)?
Hello Biasi,
Here is the uboot and preloader.
View attachment lk.zip
View attachment preloader_wiko.zip
Are you electronic hackers ? Did you have a RS232 to USB converter (3V3) ?
On Sunset, if you unmount you can find TX/RX and TX2/RX2 pin easily available.
You can plug adaptor on TX and see uboot logs in real time and what append during boot.
Courrage

Categories

Resources