maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Jolla1 & TOH (https://talk.maemo.org/forumdisplay.php?f=56)
-   -   [HOWTO] Comprehensive Firmware Flashing Guide for Jolla (https://talk.maemo.org/showthread.php?t=91885)

djselbeck 2013-12-20 17:47

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Yes thats clears thing out quite nicely and I'm even more disappointed.

In fact I know now that I spend 400 bucks on a device which is hardly useable as an development unit for fun hacking. No factory images is a nogo for me and I'm evaluating right now if I won't sell the whole thing on ebay after christmas.

Perhaps you should've disclosed this information earlier. I'm really disappointed now and feel a bit ripped of because I asked this question several times and haven't got an answer until now.

But I think the 400 bucks from customers looked so nice you wouldn't bother telling the whole truth. :mad::mad::mad:

Stskeeps 2013-12-20 17:50

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399190)
Yes thats clears thing out quite nicely and I'm even more disappointed.

In fact I know now that I spend 400 bucks on a device which is hardly useable as an development unit for fun hacking. No factory images is a nogo for me and I'm evaluating right now if I won't sell the whole thing on ebay after christmas.

There's nothing whatsoever stopping you from writing the whole 'sailfish', 'boot', 'recovery' and other GPT partitions onto microSD and making a recovery image that'll restore those from a microSD card onto the main eMMC. Classic device hacking.

djselbeck 2013-12-20 17:52

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
I've already backed most of them up, but at the moment I cannot back up a running/changing volume like / , can I?

Stskeeps 2013-12-20 17:59

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399193)
I've already backed most of them up, but at the moment I cannot back up a running/changing volume like / , can I?

Fair, the way I typically do it is to write a recovery with a kernel with initrd with USB networking up, telnetd -l /bin/sh, back up from there, restore from there too.

Nothing is in recovery atm anyway.

All this is hacking advice and my personal opinion.

djselbeck 2013-12-20 18:03

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Alright, I give it a try over the next days. So just to be clear and not waste 400 bucks ;) fastboot oem unlock; fastboot flash recovery somerecovery.img won't do any harm?

shmerl 2013-12-20 18:09

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
rainisto: DRM means any kind of taking away control from the user by means of obscurity, closed encryption and so on. Locked / encrypted bootloader with no way to set your own keys or unlock it is a perfect example of DRM. That's the way I understand the term. Preventing copying media files is just one example of it.

Protecting data and security with encryption is perfectly fine, as far as the user is in control of that protection. If user isn't - that's already DRM.

Stskeeps 2013-12-20 18:10

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399197)
Alright, I give it a try over the next days. So just to be clear and not waste 400 bucks ;) fastboot oem unlock; fastboot flash recovery somerecovery.img won't do any harm?

Avoid oem unlock if possible. Stick to developer mode/root capabilities, should be enough.

djselbeck 2013-12-20 18:13

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Ok, and without unlock I can boot custom recovery?

Stskeeps 2013-12-20 18:14

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399206)
Ok, and without unlock I can boot custom recovery?

AFAIK - if it doesn't work, lemme know.

djselbeck 2013-12-20 18:19

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Thanks for your help, this was very supporting. I will see what I can do :). If I can create my own recovery images I would be perfectly pleased

shmerl 2013-12-20 18:20

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
djselbeck: If you succeed in figuring out exact steps how to back up and restore various partitions, can you please summarize them somewhere on the Mer wiki?

djselbeck 2013-12-20 18:21

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Of course ;) but no timeframe.

shmerl 2013-12-20 18:24

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Here probably is a good place: https://wiki.merproject.org/wiki/Sailfish#Jolla

djselbeck 2013-12-20 19:18

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by Stskeeps (Post 1399207)
AFAIK - if it doesn't work, lemme know.

Hello,

I tried flashing my custom recovery but failed:

Code:

fastboot -i 0x2931 flash recovery recovery.img
sending 'recovery' (5964 KB)...
OKAY [  0.375s]
writing 'recovery'...
FAILED (remote: access denied. need privilege!)
finished. total time: 0.379s


rainisto 2013-12-20 19:22

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399240)
Hello,

I tried flashing my custom recovery but failed:

Code:

fastboot -i 0x2931 flash recovery recovery.img
sending 'recovery' (5964 KB)...
OKAY [  0.375s]
writing 'recovery'...
FAILED (remote: access denied. need privilege!)
finished. total time: 0.379s


Maybe you didn't understand when Stskeeps said that stay with developer mode and root.

Did you try as root to run: "dd if=recovery.img of=/dev/disk/by-partlabel/recovery" while beeing logged inside Jolla phone shell?

djselbeck 2013-12-20 19:25

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
my mistake, sorry

I try this

nieldk 2013-12-20 19:52

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
1 Attachment(s)
Quote:

Originally Posted by Stskeeps (Post 1399188)
Okay, so, guys - here's the exact situation, with a large amount of gory technical details so you can understand what's going on too.

* Philosophy wise, we're into user privacy - protecting your private data against attackers, physical or applications - ie, not DRM (other people's rights..). When you've set a lock code, we try to protect your data as well as we can.

A way to see this is that I really wouldn't want my private conversations to be easily extractable because I put my phone into a malicious USB charger or a competitor stole my phone off the table in Amsterdam in Ruoholahti while I was getting a drink.

* The bootloader of the Jolla is 'little kernel' ("lk") which speaks the typical Android fastboot protocol, which has a open source flasher.

* There's three modes of booting:
- Normal booting - boot into 'boot' partition, which is a combined kernel + initrd + cmdline image
- Recovery booting (volume down + power on) - doesn't do anything at the moment as there's nothing in recovery but boots into 'recovery' partition (same format as boot)
- Fastboot mode (volume down + put USB in) - opens a fastboot session on USB that you can connect to with fastboot flasher

There's a few toggles in the device currently:
* Developer mode - which gives you full root on your device and it says, please note this: "this may void your warranty" - it does not say "this will void your warranty". The philosophy there is that if you break something with it, you get to keep both pieces - don't do anything stupid - like overwrite the boot loader, or use hardware parts beyond their specifications.
- It is possible to flash kernel, recovery, etc from within device as we do this in OTA updates. If you really have to hack, do it with recovery partition until the below is in place.

* OEM unlock - which determines if bootloader is open or not - no special code is required to unlock - just fastboot oem unlock, but the power comes with responsibility - and I'm not in any way as an employee recommending this.

Now - one of the things about breaking things is that you can glue things together and it's all good again - About recovery:

At an upcoming update (I cannot say which, because, until a feature is released, it can at any point be pulled and postponed), there will be a recovery partition installed that will 1) ask for your device lock code if you have one and 2) allow you to factory reset your device in case you've hacked it a bit too much ("unbootable brick" situation)

That recovery I'd like to improve in such a way that it enables users to do full system backup/restore from microSD and other useful bits that we've learnt from maemo times is just generally nice to have (BackupMenu, BootMenu, etc).

Now, about factory images.

The Jolla device has all it's system data on a eMMC, one big SD card practically. This is shared with the modem part and includes things like modem firmware and other bits (take a look at the 25+ GPT partitions!). The device factory image is a combination of SailfishOS, a Qualcomm Android hardware adaptation and modem bits. The hardware adaptation and modem bits are copyrighted by Qualcomm and are put in place by the factory partner - and Jolla cannot distribute those parts.

Due to a bit of a design flaw on my behalf that I hope to solve for future devices, our entire system is merged together in one big 'sailfish' BTRFS volume which makes it even harder to separate bad bits and 'good bits' and 'flash them seperately'

In practice, what this means, is that we cannot provide full factory images. And that sucks. But if we do a proper recovery, backup and restore possibilities, it takes care of a lot of the trouble.

I don't personally buy devices that can't be hacked. We started developing Sailfish on hackable devices - we know our roots. And I have one coming to me at full price - no rebates or special treatment.

Does this clear up the situation a bit? Device is open as is explained above, but, when you hack, you'll always want to be able to restore your device. And that's what I hope the recovery will sort out unless you really screw up the device. In which case it's your own fault.

;) working on it

Fuzzillogic 2013-12-20 20:00

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Thanks for the info. Exactly the kind of explanation which is needed, imo.

Some questions rise:
  1. There's no possibility the problem of the too intertwined volumes can be solved by a software update?
  2. How about the possibility for the end-user to create a back-up of the flash, which he then can use later to restore his otherwise FUBARred device?
  3. Isn't it kinda ignorant of qualcomm not to allow distribution of those blobs, since every Jolla owner already has access to them on device?..

Edit: I missed part of the thread. Apparently Q2 is already answered, with a "yes, you can". That's good to know. Would be nice if the process could be automated a bit, and/or have a somewhat more n00b-friendly manual.

shmerl 2013-12-20 20:03

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Kaacz: DRM is DRM. I didn't mix anything, see explanation above. For example "secure" boot in UEFI without a way to use your own keys or to disable it is DRM. Don't mix security with taking away control and choice from the user.

Quote:

Originally Posted by Fuzzillogic (Post 1399255)
  1. Isn't it kinda ignorant of qualcomm not to allow distribution of those blobs, since every Jolla owner already has access to them on device?..

Qualcomm aren't new to stupidity and nasty vendor behavior (for example this). So I wouldn't ask any questions on common sense and decency there.

Kaacz 2013-12-20 20:50

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
shmerl: Sorry, i missed some of your comments and then i missed your PoV .. now i understand to you... :)

djselbeck 2013-12-20 21:19

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
I've successfully booted my own compiled kernel right now. But at the moment I've some problems with initrd but should figure it out sooner or later

Konsta 2013-12-20 21:39

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399273)
I've successfully booted my own compiled kernel right now. But at the moment I've some problems with initrd but should figure it out sooner or later

This should be how to create a boot.img.
https://github.com/KonstaT/sailfisho...oot-img.sh#L17

Looks like there's only a dummy ramdisk inside boot.img. Have you btw dumped the original boot partition from the device? Or at least could someone upload the kernel config (/proc/config.gz) from an actual device? It should be quite close to boston_mer_defconfig but still not exactly.

According to this, there's also a tool for flashing partitions in the system.
https://github.com/KonstaT/sailfisho...bootimg-sbj.sh

Edit. Oh wow, my posts are moderated before publishing for some reason. This message appearead here several days (~week?) later. Seriously, wtf?! If I've done something to deserve a post ban - then just issue one, but this is just ridiculous.

djselbeck 2013-12-20 22:52

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
It is working now. I'm preparing an easy guide with an image.

As I'm typing this, I'm backing up my mmcblk0p* partitions.

The best thing, you don't even have to modify your recovery partition :)

I've written the guide here: https://wiki.merproject.org/wiki/Sai...prebuilt_image

As you can see I'm really not good at this kind of stuff. If some one with some skill in mediawiki wants to improve feel free. For questions use this thread or write me a pm.

Please be careful, I won't take any responsibility for your actions. This guide is for users who know what they are doing

Golden-Boy 2013-12-21 08:17

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by rainisto (Post 1399242)
Maybe you didn't understand when Stskeeps said that stay with developer mode and root.

Did you try as root to run: "dd if=recovery.img of=/dev/disk/by-partlabel/recovery" while beeing logged inside Jolla phone shell?

Hello rainisto

I am trying to contact you but do not have private message privileges on this forum for some reason. Can you please email me?

allegation at gmail.com

Thank you.

Raim 2013-12-21 16:34

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Thank you very much for the instructions. I was able to boot your image. I also added some missing details I discovered on the way to the Wiki.

For a real fastboot recovery image, I would appreciate support for ssh and also NFS. Then we could copy the files directly to the host instead of going through the SD card.

javispedro 2013-12-21 22:17

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
I was able to dualboot mine, too.
Actually I booted the stock kernel but with a different rootfs, you do not need to do any changes to the kernel configuration since you can override the command line when mkbootimg'ing.

The stock kernel image, cmdline and initramfs are stored in /boot/boot.img (this is in mkbootimg format). There are several (Android) programs around to "unmkbootimg" this and get the raw kernel images et all. Also, the format is simple enough to decode manually. The stock kernel cmdline, stored in this file, is:
Code:

init=/sbin/preinit root=/dev/mmcblk0p28 rootfstype=btrfs rootflags=recovery noinitrd androidboot.hardware=qcom user_debug=31 ehci-hcd.park=3 maxcpus=2
(Presumably should match what you get on a live SbJ's /proc/cmdline)

Some comments to the wiki page https://wiki.merproject.org/wiki/ind.../Backup_Device that may be interesting if creating your own bootimgs:
  • You do not really need to edit CONFIG_CMDLINE or set CONFIG_CMDLINE_FORCE. Passing a valid cmdline (via --cmdline 'init=/linuxrc ...') to mkbootimg is enough and this is the way the builtin kernel does this. However, this is mostly personal preference.
  • You can use standard Linux tools to build the initramfs such as "cpio -H newc". It can be gzipped.
  • You do need to set the same offsets the stock boot.img uses to mkbootimg, i.e. ensure you pass the following to mkbootimg (along with kernel and ramdisk options):
    Code:

    --base 0x00000000 --pagesize 2048 --kernel_offset 0x80208000 --ramdisk_offset 0x82200000 --second_offset 0x81100000 --tags_offset 0x80200100 --board ''
    " Otherwise you'll get instant reboot.

EDIT: I've now changed the above wiki page (section "Build your own image"). Waiting for feedback if you're trying to build your own images!

djselbeck 2013-12-22 11:01

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Hello,

I've tried building the bootimage with an extra ramdisk but so far only got instant reboot, so I decided to include it directly into the kernel.

Did you actually had success including a ramdisk with mkbootimg?

I think you need to specify an offset to the kernel, which declares the location of the image. Something like

Code:

initrd=0x02200000
but I had no time so far trying that out.

My first priority was to provide an fast solution to backup your device ;). Now I have some time and will look into it and include an ssh server for example.

Edit: Ramdisk inclusion with boot.img worked. I've no idea why it did'nt last time I tried. Perhaps because it was already very late and I'm tired ;) So this is clearly the preferred method over init inclusion in kernel image.

Raim 2013-12-22 14:32

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
I think it would be interesting to know whether these partitions are actually the same for all devices or if they contain anything specific for each phone. So here are SHA1 checksums of my backups.

Code:

$ sha1sum mmcblk0p{1..27}.img
edd6071d386ed1d60a541a06e0eb081c381296b7  mmcblk0p1.img
ccb9f2c0184df67deff69df328a78d04ab0fd805  mmcblk0p2.img
a07548e01946ba3490d8d0898a7f2027890f2021  mmcblk0p3.img
41e2c4bbe9433b14dfa4c95b99e09245faf0c8e7  mmcblk0p4.img
31ebbbadb5686cf54d4f3760f7f39d007e87e501  mmcblk0p5.img
e904aa58289574f74753fa5a810551676ccdaefe  mmcblk0p6.img
32507ad14ccec38defa20fa9261d9b612b6e39f9  mmcblk0p7.img
cfdf75b00346c48c7afd80647003f41e1d9fce0f  mmcblk0p8.img
0b7620536530c70d3b7f7fca794a11b3ee3b560c  mmcblk0p9.img
aff661e1c1b4b0bea1d71c6d6bc0ec67c4842d61  mmcblk0p10.img
4277b8ef0cd6e0e094b5d266a455555d56881c79  mmcblk0p11.img
e5da449e911e5109c07bd5790bba98b8e177e07d  mmcblk0p12.img
ab7066450ff20db47b84a4c04d17234f1a2ee41e  mmcblk0p13.img
4a2678e8344d53fea59bd884c5059808eff6c215  mmcblk0p14.img
9cb3b5879a41ec2807bcd348d7272b2c5810853b  mmcblk0p15.img
16b918c87b4c88caaaf4141a8e9ffa07e2619f42  mmcblk0p16.img
edb50610c434463c34d454a45cb8ce60d19cbd7b  mmcblk0p17.img
f6d80fcc3f4b0d6601c54d507e57a29a852628c1  mmcblk0p18.img
3fdbe058350c93e3f76c038f57165abb7f32f10f  mmcblk0p19.img
cbc76425d05c9725640ce16246316babf0c68212  mmcblk0p20.img
e965227e6200655f4fbde5e74df13f2e10c3bbbe  mmcblk0p21.img
5fde1cce603e6566d20da811c9c8bcccb044d4ae  mmcblk0p22.img
5fde1cce603e6566d20da811c9c8bcccb044d4ae  mmcblk0p23.img
4298f4bad2bae957adf2fe4034e82fdc85f40f77  mmcblk0p24.img
f9f05976f9056069c08c5dfca34c20f0ef69a4dd  mmcblk0p25.img
03e6fb7a7034b064a876da4d0c8c88373849f0b5  mmcblk0p26.img
723302098b1e619e83bd6726096e15fcd6bd8402  mmcblk0p27.img

I left out partition 28, the root filesystem, because everyone has definitely made their own changes on that already.

Please let me know if yours differ from mine above.

djselbeck 2013-12-22 14:35

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Yep, actually a lot differ:

Code:

fd13511082820e36c0cada61862457152bc8483c  mmcblk0p1
9fe01a1d7b38c861a80a5d4d9b583c3b83c35efc  mmcblk0p2
f7f47d862fb74e4f955c0746f13e2ee585a02763  mmcblk0p3
e3d31adfd70df23fc32f464a5a60f34e59996e40  mmcblk0p4
82b5c51a77de9d7e10daae5eb8095d760dc5739e  mmcblk0p5
e904aa58289574f74753fa5a810551676ccdaefe  mmcblk0p6
32507ad14ccec38defa20fa9261d9b612b6e39f9  mmcblk0p7
0a2d9e671eb8d04994e76d31456262f12130304b  mmcblk0p8
1a54de676c5131972d85a43e8c741805e0d40f37  mmcblk0p9
458b24477074c08ca267c1f7d0f7352373a7b5b7  mmcblk0p10
64accf1c268db9329c53641417c132cc45d5b343  mmcblk0p11
e5da449e911e5109c07bd5790bba98b8e177e07d  mmcblk0p12
ab7066450ff20db47b84a4c04d17234f1a2ee41e  mmcblk0p13
4a2678e8344d53fea59bd884c5059808eff6c215  mmcblk0p14
9cb3b5879a41ec2807bcd348d7272b2c5810853b  mmcblk0p15
16b918c87b4c88caaaf4141a8e9ffa07e2619f42  mmcblk0p16
edb50610c434463c34d454a45cb8ce60d19cbd7b  mmcblk0p17
f6d80fcc3f4b0d6601c54d507e57a29a852628c1  mmcblk0p18
342de6a26abfe7e09545f73d6aeba44d3e04cc53  mmcblk0p19
cbc76425d05c9725640ce16246316babf0c68212  mmcblk0p20
3ad9c7b30a8843f7bb40529f5ba648d821485599  mmcblk0p21
5fde1cce603e6566d20da811c9c8bcccb044d4ae  mmcblk0p22
5fde1cce603e6566d20da811c9c8bcccb044d4ae  mmcblk0p23
04d6bd9172e1885430fb533d6caf089a322df5c6  mmcblk0p24
c196035601266d43bf8dcb7f3d4add13fe58af99  mmcblk0p25
03e6fb7a7034b064a876da4d0c8c88373849f0b5  mmcblk0p26
f2434a34119e15865d101a350ae0da24216c4448  mmcblk0p27


nieldk 2013-12-22 14:55

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
So dissapointed with the wireless support (no monitor mode/injection)
Does anyone have a clue to which card is in the device ?

Code:

[nemo@localhost ~]$ sudo iw list
Wiphy phy0
        Band 1:
                Capabilities: 0x9030
                        HT20
                        Static SM Power Save
                        RX Greenfield
                        RX HT20 SGI
                        No RX STBC
                        Max AMSDU length: 3839 bytes
                        DSSS/CCK HT40
                        L-SIG TXOP protection
                Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
                Minimum RX AMPDU time spacing: 16 usec (0x07)
                HT TX/RX MCS rate indexes supported: 0-7
                Frequencies:
                        * 2412 MHz [1] (30.0 dBm)
                        * 2417 MHz [2] (30.0 dBm)
                        * 2422 MHz [3] (30.0 dBm)
                        * 2427 MHz [4] (30.0 dBm)
                        * 2432 MHz [5] (30.0 dBm)
                        * 2437 MHz [6] (30.0 dBm)
                        * 2442 MHz [7] (30.0 dBm)
                        * 2447 MHz [8] (30.0 dBm)
                        * 2452 MHz [9] (30.0 dBm)
                        * 2457 MHz [10] (30.0 dBm)
                        * 2462 MHz [11] (30.0 dBm)
                        * 2467 MHz [12] (30.0 dBm)
                        * 2472 MHz [13] (30.0 dBm)
                        * 2484 MHz [14] (30.0 dBm)
                Bitrates (non-HT):
                        * 1.0 Mbps
                        * 2.0 Mbps
                        * 5.5 Mbps
                        * 11.0 Mbps
                        * 6.0 Mbps
                        * 9.0 Mbps
                        * 12.0 Mbps
                        * 18.0 Mbps
                        * 24.0 Mbps
                        * 36.0 Mbps
                        * 48.0 Mbps
                        * 54.0 Mbps
        max # scan SSIDs: 9
        max scan IEs length: 200 bytes
        Coverage class: 0 (up to 0m)
        Supported Ciphers:
                * WEP40 (00-0f-ac:1)
                * WEP104 (00-0f-ac:5)
                * TKIP (00-0f-ac:2)
                * CCMP (00-0f-ac:4)
                * WPI-SMS4 (00-14-72:1)
        Available Antennas: TX 0 RX 0
        Supported interface modes:
                * IBSS
                * managed
                * AP
                * P2P-client
                * P2P-GO
        software interface modes (can always be added):
        interface combinations are not supported
        Supported commands:
                * new_interface
                * set_interface
                * new_key
                * new_beacon
                * new_station
                * set_bss
                * join_ibss
                * set_pmksa
                * del_pmksa
                * flush_pmksa
                * remain_on_channel
                * action
                * frame_wait_cancel
                * set_channel
                * connect
                * disconnect
        Supported TX frame types:
                * managed: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                * AP: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                * P2P-client: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                * P2P-GO: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
        Supported RX frame types:
                * managed: 0x40 0xd0
                * AP: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
                * P2P-client: 0x40 0xd0
                * P2P-GO: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
        Device supports roaming.


djselbeck 2013-12-22 14:57

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
I think it is some kind of Qualcomm Prima WCNSS module

nieldk 2013-12-22 15:03

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399682)
I think it is some kind of Qualcomm Prima WCNSS module

kinda thought so, but

Code:

sudo dmesg | grep wcnss
doesnt reveal any outcome

and lsmod
Code:

[nemo@localhost ~]$ sudo lsmod
Module                  Size  Used by
mysatroker            57477  2
wlan                2592759  0
cfg80211              144263  1 wlan


nieldk 2013-12-22 15:09

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
I upgraded, I guess thus two modules directories

/lib/modules/3.4.0.20131115.2/kernel/net/wireless
is empty

/lib/modules/3.4.0.20131118.1/kernel/net/wireless
contains cfg80211.ko and wlan.ko

javispedro 2013-12-22 15:52

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399623)
Did you actually had success including a ramdisk with mkbootimg?

Yes, the default offset is OK. Actually I should try which one of the "offsets" is actually mandatory, because them being mandatory makes no sense (but nothing on Android does, tbh).

Also, enabling NFS client is easy enough: just copy nfs.ko from rootfs (or enable as builtin if building your own kernel). Busybox's default mount is enough to connect to NFS as long as you pass -o nolock to disable dependency on localhost lockd/portmapper.


Quote:

Originally Posted by nieldk (Post 1399687)
/lib/modules/3.4.0.20131118.1/kernel/net/wireless
contains cfg80211.ko and wlan.ko

Seems like tis may be similar to this other, freely licensed module. Maybe you should open a new thread and try to figure out how to make that module work.

BTW. Another disappointment is that the stock kernel is tainted propietary by this module.

djselbeck 2013-12-22 16:06

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by javispedro (Post 1399692)
Yes, the default offset is OK. Actually I should try which one of the "offsets" is actually mandatory, because them being mandatory makes no sense (but nothing on Android does, tbh).

Also, enabling NFS client is easy enough: just copy nfs.ko from rootfs (or enable as builtin if building your own kernel). Busybox's default mount is enough to connect to NFS as long as you pass -o nolock to disable dependency on localhost lockd/portmapper.




Seems like tis may be similar to this other, freely licensed module. Maybe you should open a new thread and try to figure out how to make that module work.

BTW. Another disappointment is that the stock kernel is tainted propietary by this module.

Yes thats right. Im trying to build prima module.

EDIT: I've build a version of prima wlan driver which seems to work which is good news I think. Needs to clean it all a bit up though.

nieldk 2013-12-23 08:10

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by djselbeck (Post 1399694)
Yes thats right. Im trying to build prima module.

EDIT: I've build a version of prima wlan driver which seems to work which is good news I think. Needs to clean it all a bit up though.

Good news indeed.
Did you check if monitor mode is working with your port?

djselbeck 2013-12-23 09:51

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Quote:

Originally Posted by nieldk (Post 1399844)
Good news indeed.
Did you check if monitor mode is working with your port?

Does not seems so:

Code:

iw list
Wiphy phy0
        Band 1:
                Capabilities: 0x9030
                        HT20
                        Static SM Power Save
                        RX Greenfield
                        RX HT20 SGI
                        No RX STBC
                        Max AMSDU length: 3839 bytes
                        DSSS/CCK HT40
                        L-SIG TXOP protection
                Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
                Minimum RX AMPDU time spacing: 16 usec (0x07)
                HT TX/RX MCS rate indexes supported: 0-7
                Frequencies:
                        * 2412 MHz [1] (20.0 dBm)
                        * 2417 MHz [2] (20.0 dBm)
                        * 2422 MHz [3] (20.0 dBm)
                        * 2427 MHz [4] (20.0 dBm)
                        * 2432 MHz [5] (20.0 dBm)
                        * 2437 MHz [6] (20.0 dBm)
                        * 2442 MHz [7] (20.0 dBm)
                        * 2447 MHz [8] (20.0 dBm)
                        * 2452 MHz [9] (20.0 dBm)
                        * 2457 MHz [10] (20.0 dBm)
                        * 2462 MHz [11] (20.0 dBm)
                        * 2467 MHz [12] (20.0 dBm)
                        * 2472 MHz [13] (20.0 dBm)
                        * 2484 MHz [14] (disabled)
                Bitrates (non-HT):
                        * 1.0 Mbps
                        * 2.0 Mbps
                        * 5.5 Mbps
                        * 11.0 Mbps
                        * 6.0 Mbps
                        * 9.0 Mbps
                        * 12.0 Mbps
                        * 18.0 Mbps
                        * 24.0 Mbps
                        * 36.0 Mbps
                        * 48.0 Mbps
                        * 54.0 Mbps
        Band 2:
                Capabilities: 0x9072
                        HT20/HT40
                        Static SM Power Save
                        RX Greenfield
                        RX HT20 SGI
                        RX HT40 SGI
                        No RX STBC
                        Max AMSDU length: 3839 bytes
                        DSSS/CCK HT40
                        L-SIG TXOP protection
                Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
                Minimum RX AMPDU time spacing: 16 usec (0x07)
                HT TX/RX MCS rate indexes supported: 0-7
                Frequencies:
                        * 4920 MHz [-16] (disabled)
                        * 4940 MHz [-12] (disabled)
                        * 4960 MHz [-8] (disabled)
                        * 4980 MHz [-4] (disabled)
                        * 5040 MHz [8] (disabled)
                        * 5060 MHz [12] (disabled)
                        * 5080 MHz [16] (disabled)
                        * 5180 MHz [36] (disabled)
                        * 5200 MHz [40] (disabled)
                        * 5220 MHz [44] (disabled)
                        * 5240 MHz [48] (disabled)
                        * 5260 MHz [52] (disabled)
                        * 5280 MHz [56] (disabled)
                        * 5300 MHz [60] (disabled)
                        * 5320 MHz [64] (disabled)
                        * 5500 MHz [100] (disabled)
                        * 5520 MHz [104] (disabled)
                        * 5540 MHz [108] (disabled)
                        * 5560 MHz [112] (disabled)
                        * 5580 MHz [116] (disabled)
                        * 5600 MHz [120] (disabled)
                        * 5620 MHz [124] (disabled)
                        * 5640 MHz [128] (disabled)
                        * 5660 MHz [132] (disabled)
                        * 5680 MHz [136] (disabled)
                        * 5700 MHz [140] (disabled)
                        * 5745 MHz [149] (disabled)
                        * 5765 MHz [153] (disabled)
                        * 5785 MHz [157] (disabled)
                        * 5805 MHz [161] (disabled)
                        * 5825 MHz [165] (disabled)
                Bitrates (non-HT):
                        * 6.0 Mbps
                        * 9.0 Mbps
                        * 12.0 Mbps
                        * 18.0 Mbps
                        * 24.0 Mbps
                        * 36.0 Mbps
                        * 48.0 Mbps
                        * 54.0 Mbps
        max # scan SSIDs: 9
        max scan IEs length: 255 bytes
        Coverage class: 0 (up to 0m)
        Supported Ciphers:
                * WEP40 (00-0f-ac:1)
                * WEP104 (00-0f-ac:5)
                * TKIP (00-0f-ac:2)
                * CCMP (00-0f-ac:4)
                * WPI-SMS4 (00-14-72:1)
        Available Antennas: TX 0 RX 0
        Supported interface modes:
                * IBSS
                * managed
                * AP
                * P2P-client
                * P2P-GO
        software interface modes (can always be added):
        valid interface combinations:
                * #{ managed } <= 3, #{ AP } <= 1, #{ P2P-client, P2P-GO } <= 1,
                  total <= 3, #channels <= 2
        Supported commands:
                * new_interface
                * set_interface
                * new_key
                * new_beacon
                * new_station
                * set_bss
                * join_ibss
                * set_pmksa
                * del_pmksa
                * flush_pmksa
                * remain_on_channel
                * action
                * frame_wait_cancel
                * set_channel
                * Unknown command (82)
                * Unknown command (81)
                * Unknown command (75)
                * connect
                * disconnect
        Supported TX frame types:
                * managed: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                * AP: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                * P2P-client: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
                * P2P-GO: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 0xe0 0xf0
        Supported RX frame types:
                * managed: 0x40 0xd0
                * AP: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
                * P2P-client: 0x40 0xd0
                * P2P-GO: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
        Device supports roaming

Another problem is that alien dalvik VM seems to need some kernel support. With opensource version it goes nuts with "alien_init" because it cannot open /dev/mysatrokerServer. And crashes and reloads all the time :(.

Looks like the mysatroker module is missing:

Code:

filename:      /lib/modules/3.4.0.20131118.1/kernel/mysatroker.ko
license:        Proprietary.Copyright 2012-2013 Myriad Group AG. All Rights Reserved.
author:        Myriad Group AG
description:    MYriad Share Anything TROugh KERnel
depends:       
vermagic:      3.4.0.20131118.1 SMP preempt mod_unload modversions ARMv7

The description alone gives me goose bumps as an engineer :/

nieldk 2013-12-23 10:24

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
@djselbeck

Well, the mysatroker module seems to be some myriad implementation of /dev/binder. Yet another propriatrairy implementation :(

(http://talk.maemo.org/showpost.php?p...&postcount=718)

As for the wireless driver.
Wow, there are at least some points interresting there:

Code:

                HT TX/RX MCS rate indexes supported: 0-7
                Frequencies:
                        * 4920 MHz [-16] (disabled)
                        * 4940 MHz [-12] (disabled)
                        * 4960 MHz [-8] (disabled)
                        * 4980 MHz [-4] (disabled)
                        * 5040 MHz [8] (disabled)
                        * 5060 MHz [12] (disabled)
                        * 5080 MHz [16] (disabled)
                        * 5180 MHz [36] (disabled)
                        * 5200 MHz [40] (disabled)
                        * 5220 MHz [44] (disabled)
                        * 5240 MHz [48] (disabled)
                        * 5260 MHz [52] (disabled)
                        * 5280 MHz [56] (disabled)
                        * 5300 MHz [60] (disabled)
                        * 5320 MHz [64] (disabled)
                        * 5500 MHz [100] (disabled)
                        * 5520 MHz [104] (disabled)
                        * 5540 MHz [108] (disabled)
                        * 5560 MHz [112] (disabled)
                        * 5580 MHz [116] (disabled)
                        * 5600 MHz [120] (disabled)
                        * 5620 MHz [124] (disabled)
                        * 5640 MHz [128] (disabled)
                        * 5660 MHz [132] (disabled)
                        * 5680 MHz [136] (disabled)
                        * 5700 MHz [140] (disabled)
                        * 5745 MHz [149] (disabled)
                        * 5765 MHz [153] (disabled)
                        * 5785 MHz [157] (disabled)
                        * 5805 MHz [161] (disabled)
                        * 5825 MHz [165] (disabled)

As well as a couple of unidentified function calls:

Code:

                * Unknown command (82)
                * Unknown command (81)
                * Unknown command (75)

I call this improvement - despite that Myriad c.....

djselbeck 2013-12-23 10:50

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
I doubt that the 5GHz channels can be activated.

But nevertheless it is good to have an own kernel running.

Hope an open whatsapp will be ported soon, so I can remove the alien piece of junk.

djselbeck 2013-12-24 11:05

Re: [HOWTO] Comprehensive Firmware Flashing Guide for Jolla
 
Hello again,

I've uploaded the updated kernel sources with integrated prima wlan driver. If someone wants to try it you should know that it currently doesn't read the correct MAC adress and generates an automatic one.

https://github.com/djselbeck/sailfis..._jolla_msm8930

Also you can prevent alien_init from going crazy if you replace

/opt/alien/system/genv/bin/{mysatroker_ressource_manager_server,mysatroker_au dio_server} with following bash script

Code:

#!/bin/bash
echo "DUMMY"
while :
do
        sleep 3600
done

You loose audio support with that but at least you can use whatsapp with own kernel. PLEASE BACKUP YOUR OLD BINARIES


All times are GMT. The time now is 09:14.

vBulletin® Version 3.8.8