ChanServ changed the topic of #linux-rockchip to: Rockchip development discussion | IRC log http://irclog.whitequark.org/linux-rockchip | Community GH https://github.com/linux-rockchip | Rockchip GH https://github.com/rockchip-linux | ML https://groups.google.com/group/linux-rockchip
vagrantc has quit [Quit: leaving]
nighty- has quit [Quit: Disappears in a puff of smoke]
nighty- has joined #linux-rockchip
tllim has quit [Quit: Leaving]
anarsoul|2 has quit [Ping timeout: 248 seconds]
cnxsoft has joined #linux-rockchip
lurchi_ is now known as lurchi__
<lvrp16> mfny: emmc has a standard bga but no standard in terms of a connector system
<MoeIcenowy> and I think mainly SBC use eMMC-as-a-module
nots has quit [Quit: Page closed]
<wens> that's the part that isn't standardized
lurchi_ has joined #linux-rockchip
lurchi__ has quit [Ping timeout: 245 seconds]
vstehle has joined #linux-rockchip
return0e has quit [Ping timeout: 240 seconds]
return0e has joined #linux-rockchip
mmind00 has quit [Remote host closed the connection]
mmind00 has joined #linux-rockchip
hanetzer has quit [Quit: WeeChat 2.1]
hanetzer has joined #linux-rockchip
Omegamoon has joined #linux-rockchip
Omegamoon has quit [Remote host closed the connection]
Omegamoon has joined #linux-rockchip
BenG83 has quit [Ping timeout: 256 seconds]
yann|work has quit [Ping timeout: 265 seconds]
wadim_ has joined #linux-rockchip
matthias_bgg has joined #linux-rockchip
afaerber has quit [Quit: Leaving]
afaerber has joined #linux-rockchip
Aussie_matt has joined #linux-rockchip
nighty- has quit [Quit: Disappears in a puff of smoke]
Omegamoon has left #linux-rockchip [#linux-rockchip]
ameel has joined #linux-rockchip
<ameel> Hello guys
<ameel> I got myself a rock960
<ameel> having a minor issue and a major issue
<ameel> minor issue: apple/mac keyboard doesn't work on debian/linux image, but works on android
<ameel> major issue: rock960 won't boot from sd. tested with ubuntu and debian image, but neither work
<ameel> i'm not fussed about the keyboard, but could anyone please assist with the sd?
<ameel> sd boot
yann|work has joined #linux-rockchip
<ameel> hello yann?
<Ke> ameel: you want to boot a kernel from SD or the bootloader?
<ameel> from sd Ke
<ameel> from eMMC it's working fine
Aussie_matt has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
<ameel> @Ke now that I have installed ubuntu on the eMMC, it's bypassing sdcard completely
hanetzer has quit [Ping timeout: 260 seconds]
Aussie_matt has joined #linux-rockchip
hanetzer has joined #linux-rockchip
<ccaione> ameel: the bootrom code checks eMMC before SD, so the SD contains already a valid bootloader you wont't be able to boot from SD
yann|work has quit [Ping timeout: 256 seconds]
yann|work has joined #linux-rockchip
yann|work has quit [Ping timeout: 248 seconds]
<ameel> [21:03] <ccaione> ameel: the bootrom code checks eMMC before SD, so the SD contains already a valid bootloader you wont't be able to boot from SD
<ameel> i don't get it
<ameel> if SD contains valid bootloader, it won't be able to boot from SD?
<Ke> ameel: that is right, unless the bootloader on the eMMC chainloads it, mostly in these cases the only chainload protocol is EFI
<ccaione> there is a valid bootloader also on the eMMC?
<ameel> i don't know :(
<ameel> i followd the instructions here
<Ke> well I guess there are non-efi chainload options for at least u-boot
<ameel> I followed instructions here: https://www.96boards.org/documentation/consumer/rock960/installation/windows-sd.md.html but that did not boot anything after the sd card is inserted. screen remained black
<ameel> booting into ubuntu works
<ameel> however, when i insert sd card, it just boots into ubuntu anyway (sd card is flashed with the debian image)
<ccaione> I'm just saying that if there is a valid bootloader still present in the eMMC then that could explain why you are not able to boot from SD because (at least on the rk3288) the eMMC has higher priority
<ameel> oh ki see
<ameel> i'm not sure :/
<ameel> how would i check?
<Ke> haha, someone uses oflag=sync that's really worth a shame cubge
<Ke> cube
<Ke> always conv=fsync, almost never oflag=sync
nighty- has joined #linux-rockchip
<ameel> hello ccaione or ke?
<ameel> what can i do?
nighty- has quit [Max SendQ exceeded]
<Ke> ameel: the documentation is not clear on, what you are trying to do on a level that I can understand
<ccaione> ameel: erase the first emmc sectors and good luck
afaerber has quit [Read error: Connection reset by peer]
<ameel> how would i do that?
afaerber has joined #linux-rockchip
<ameel> mmcblk1rpmb 179:128 0 4M 0 disk mmcblk1boot0 179:64 0 4M 1 disk mmcblk1boot1 179:96 0 4M 1 disk mmcblk0 179:0 0 119.3G 0 disk |-mmcblk0p1 179:1 0 3.9M 0 part |-mmcblk0p2 179:2 0 4M 0 part |-mmcblk0p3 179:3 0 4M 0 part |-mmcblk0p4 179:4 0 112M 0 part `-mmcblk0p5 179:5 0 2.2G 0 part mmcblk1 179:32 0 14.3G 0 disk |-mmcblk1p1 179:33 0 3.9M 0 part |
<ameel> oops
<Ke> what ccaione said, but I am not sure that is safe to to extent you are comfortable with
<ccaione> no time to explain every single step, sorry
<Ke> notably you may have to do even more complicated steps to recover, if the assumptions made are wrong
<ameel> hmm
<Ke> as in assumptions that the SD image contains a bootloader and not just a kernel
<Ke> or not a chainloadable bootloader
<ameel> yes
<ameel> so delete the first partition on the eMMC?
<Ke> just erasing your emmc will not damage the hw though
<ccaione> not the first partition, the first sectors
<Ke> ameel: note you need to erase the contents, not just the partition entry
<ameel> ok ill try that
<Ke> like dd if=/dev/zero of=/dev/mmcblk1 count=whatever bs=1M conv=fsync
<Ke> would erase n first megabytes of mmcblk1
<ameel> btw, do you guys know any guide on getting ST7735 to work on ubuntu
nighty- has joined #linux-rockchip
astralix has joined #linux-rockchip
astralix_ has joined #linux-rockchip
astralix has left #linux-rockchip [#linux-rockchip]
astralix_ has left #linux-rockchip [#linux-rockchip]
astralix has joined #linux-rockchip
<astralix> Nice to see that my account is still active after all those years ;) Greetings to everyone!
<ameel> Ke ccaoine it doesn't boot after i delet ethe it
<ameel> delete/erase the sectors
<Ke> ameel: does it still boot from the eMMC or not at all
<ameel> it does not boot anything anymore
<ameel> I put the sd card in and it boots again, but from eMMC, not from the sdcard
<Ke> =D
<Ke> it's always such a mess
<ameel> so the sdcard is telling it to boot from eMMC
<Ke> you can always erase more of the eMMC
<ameel> lol
<ameel> i don't know how
<Ke> dd if=/dev/zero of=/dev/mmcblk1 count=whatever bs=1M conv=fsync
<ameel> surely i can't do a full erase from ubuntu?
<ameel> count i put =4
<ameel> how do i determine count?
<Ke> or blkdiscard /dev/mmcblk1
<ameel> also, i don't think that's the problem, if the sdcard is telling the system to boot from eMMC?
<Ke> where 1 is the eMMC
<Ke> can't help you there, as I have no idea what is happening
<ameel> hmmm
<Ke> might be that the images contain filesystems that have the same UUID
<Ke> mostly I would just kill the whole eMMC
<ameel> doing it
<ameel> finger scrossed
<ameel> it's taking its sweet time
<Ke> what are you doing then?
<ameel> killing the whole eMMC
<ameel> blkdiscard
<Ke> good
<ameel> does that usually take long?
<ameel> does it matter that ubuntu is mounted on that while i'm trying to discar dit?
<Ke> it depends on the device, not usually
yann|work has joined #linux-rockchip
<ameel> oh lol
<ameel> that worked
<ameel> booted from sdcard
<Ke> good thing with the blkdiscard is that it will leave your card to a state that is least harmful to the hw
<Ke> though it's not guaranteed to work by the spec
<ameel> hmm
<ameel> kk
<ameel> cheers for that
<ameel> (y)
<ameel> can you help me with something else?
<ameel> i'm looking at a ST77335 display
<Ke> no idea about that
<ameel> haha, ok nw
<ameel> thanks anyway
<Ke> you can grep kernel sources for the compatible string for starters
<Ke> probably under drivers/graphics or something
<Ke> perhaps something like panel
<ameel> mmm
<ameel> kk
<ameel> cheers
<ameel> i guess it's still a little annoying
<ameel> i'd like to be able to boot from eMMC
<ameel> or sd card if that's connected
<ameel> but doesn't seem to work that way :/
<Ke> no and it's a hw thing so you can't fix it
<Ke> you can use chainloading though or boot kernel from SD card using the bootloader of the eMMC
<ameel> yeah
<ameel> i saw there're are 2 sets of files actually
<ameel> but installation guide for both eMMC and sdcard use the same one set of file
<ameel> maybe the other will work properly? i'll try it out
<Ke> I would urge you to stay clear of the eMMC, until you know, what you are doing
<ameel> hmm kk
<Ke> if you put the eMMC to a bad state, recovery may be hard
<Ke> leaving it blank for now, may be a good idea
<ameel> i see
<Ke> SD you can always detach and restore to a known good state on another system
<ameel> alright
afaerber has quit [Quit: Leaving]
afaerber has joined #linux-rockchip
lurchi_ is now known as lurchi__
yann|work has quit [Ping timeout: 256 seconds]
yann|work has joined #linux-rockchip
<ameel> hmm actually it's not booting from sd card anymore :/
<ameel> it's stuck on a black screen
<ameel> like wayyyy back when i first tried to run off sdcard
<ameel> ok so turns out debian can boot from sdcard when eMMC is empty
<ameel> whereas ubuntu can't
<astralix> isn't it that you can transfer the bootloader to eMMC? So you can add a script to first check the SD and if that is found, you boot from there. If not fall back to eMMC
<ameel> yeah, i don't know how to do any of tha
<ameel> that
<Ke> astralix: yes, u-boot at least can do this
<Ke> astralix: but not the first level bootloader though
<ameel> label kernel-4.4 kernel /Image fdt /rock960-linux.dtb append earlyprintk console=ttyFIQ0,1500000n8 rw root=/dev/mmcblk1p5 rootfstype=ext4 init=/sbin/init rootwait
<astralix> Are you debugging uboot?
<ameel> that's in an extlinux.conf file i found when i extracted the boot.img
<ameel> i've got serial console hooked up
<ameel> i'll see what happens when i try booting ubuntu from sdcard
<astralix> If you have a serial line running, are you able to see uboot or are you only get some cryptical messages and then linux is started right away?
<ameel> ** No partition table - mmc 0 ** switch to partitions #0, OK mmc1 is current device Scanning mmc 1:4...
yann|work has quit [Ping timeout: 248 seconds]
<ameel> also, can't boot ubuntu: [ 24.253270] [<ffffff8008160d18>] panic+0x228/0x234 [ 24.253697] [<ffffff8008fa1244>] [ 24.254620] [<ffffff8008fa1550>] prepare_namespace+0x168/0x1b0 [ 24.255139] [<ffffff8008fa0dec>] kernel_init_freeablebe4>] kernel_init+0x18/0x100 [ 24.256133] [<ffffff80080826c0>] ret_from_fork+0x10/0x50
<astralix> Hmm... When I left the RK android hobby project, there where two loaders. One crypto uboot that had only fixed and limited options and one open source uboot that was not complete.
<astralix> But the opne source uboot had scripting enabled and you could change parameters. In your case please test if you can modify root=/dev/mmcblkXpY to the right values, where X is the correct id of your SD Card (0 or 1) and Y is the right partition number on your SD (usually 0 or 1)
<ameel> yup fair enough
<ameel> same here
<ameel> there are some stuff i can access
<ameel> and others encrypted
<astralix> If you can't do that, use gparted to shift the ubuntu partition to the end (may be shrink it a bit) and add another few partitions in front of it, so the index is 5
<ameel> hmm
<ameel> i think its the X that i need to force
<astralix> Actually I am thinking about getting back to some linux and uboot dev for my RK based boards. However I need to finish some other stuff before.
<ameel> cool
<astralix> If you have the encrypted loader, there was a tool to fetch the script part of the uboot and you could modify it and upload it again
<ameel> switch to partitions #0, OK mmc0(part 0) is current device Scanning mmc 0:4... Found /extlinux/extlinux.conf Retrieving file: /extlinux/extlinux.conf reading /extlinux/extlinux.conf
<ameel> this is booting without sdcard on, and eMMC contains debian partition
<ameel> i guess i could mount that partition (if at all possible) and edit extlinux.conf
<ameel> how would i go about to make it boot from mmc1 and if not present, boot from mmc0
<ameel> append earlyprintk console=ttyFIQ0,1500000n8 rw root=/dev/mmcblk1p5 rootfstype=ext4 init=/sbin/init rootwait
<ameel> then again it does state mmcblk1p5 <-- but that's the file that I don't use at all
<astralix> I don't know by heart what the RK numbering was. So if mmcblk1 is SD then modify it to mmcblk1p1.
<ameel> i cant mount it
<ameel> wrong fs type
yann|work has joined #linux-rockchip
<ameel> FAT-fs (mmcblk1p1): utf8 is not a recommended IO charset for FAT filesystems, filesystem will be case sensitive!
<astralix> I don't know the layout of your debian SD card. So it might be mmcblk1p2 or mmcblk1p4... Depends.
<astralix> you can't run debian from a FAT device
<ameel> what fs should i mlount it as?
<ameel> actually nvm
<ameel> its on partition4
<ameel> which mounts fine
<ameel> ah it boots by UUID
<astralix> Ok, will be off for 2h, have to watch some TV ;)
cnxsoft has quit [Quit: cnxsoft]
JohnDoe_71Rus has joined #linux-rockchip
matthias_bgg has quit [Ping timeout: 256 seconds]
matthias_bgg has joined #linux-rockchip
Aussie_matt has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
<ameel> hello
<ameel> anyone around?
<ameel> how the hell do i figure out which gpio corresponds to what pin
matthias_bgg has quit [Quit: Leaving]
<ameel> freak sake
<ameel> this is ridiculous
<ameel> for file in gpio*; do echo -n "$file - ";cat $file/label; done
<ameel> get the labels
<ameel> cat gpicocat gpiochip1000/base
<ameel> get the base to be sure
<ameel> then count
<ameel> ~_~
tllim has joined #linux-rockchip
<ameel> alright off to bed
astralix has quit [Quit: Verlassend]
gab has quit [Quit: leaving]
yann|work has quit [Ping timeout: 256 seconds]
LargePrime has joined #linux-rockchip
anarsoul|2 has joined #linux-rockchip
vagrantc has joined #linux-rockchip
anarsoul|3 has joined #linux-rockchip
anarsoul|2 has quit [Ping timeout: 240 seconds]
aalm has quit [Ping timeout: 260 seconds]
return0e_ has joined #linux-rockchip
return0e has quit [Ping timeout: 256 seconds]
return0e_ has quit [Read error: No route to host]
return0e has joined #linux-rockchip
JohnDoe_71Rus has quit [Quit: KVIrc 5.0.0 Aria http://www.kvirc.net/]
nots has joined #linux-rockchip
lkcl has quit [Read error: Connection reset by peer]
tl_lim has joined #linux-rockchip
stone has joined #linux-rockchip
BenG83 has joined #linux-rockchip
tllim has quit [Ping timeout: 264 seconds]
tl_lim has quit [Ping timeout: 264 seconds]
tl_lim has joined #linux-rockchip
lkcl has joined #linux-rockchip
aalm has joined #linux-rockchip
yann|work has joined #linux-rockchip
return0e has quit [Read error: No route to host]
return0e has joined #linux-rockchip
fischerm has quit [Quit: ZNC 1.6.2 - http://znc.in]
afaerber has quit [Quit: Leaving]
anarsoul|3 has quit [Remote host closed the connection]
anarsoul|2 has joined #linux-rockchip
stone has quit [Quit: Page closed]
afaerber has joined #linux-rockchip
lurchi__ is now known as lurchi_
tl_lim has quit [Ping timeout: 265 seconds]
tl_lim has joined #linux-rockchip
anarsoul|3 has joined #linux-rockchip
anarsoul|2 has quit [Ping timeout: 256 seconds]
vstehle has quit [Ping timeout: 248 seconds]
nighty- has quit [Quit: Disappears in a puff of smoke]
vagrantc has quit [Quit: leaving]
tl_lim has quit [Remote host closed the connection]
tl_lim has joined #linux-rockchip