rellla changed the topic of #linux-sunxi to: Allwinner/sunxi /development discussion - did you try looking at our wiki? https://linux-sunxi.org - Don't ask to ask. Just ask and wait! - https://github.com/linux-sunxi/ - Logs at http://irclog.whitequark.org/linux-sunxi - *only registered users can talk*
specing has quit [Ping timeout: 265 seconds]
specing has joined #linux-sunxi
apritzel has quit [Ping timeout: 265 seconds]
Mangy_Dog has quit [Remote host closed the connection]
vagrantc has joined #linux-sunxi
lightspot21 has quit [Ping timeout: 260 seconds]
suprothunderbolt has joined #linux-sunxi
mripard has quit [Ping timeout: 240 seconds]
mripard has joined #linux-sunxi
afaerber has quit [Ping timeout: 245 seconds]
afaerber has joined #linux-sunxi
<pnill> smaeul: Do you know if there's any more current sunxi-fel builds for windows than the one linked on the wiki
<pnill> The artifcats on appveyor get deleted after like 30 days now
<pnill> sot he link on the git doesn't have it anymore.
<pnill> *so the
<pnill> guess I could try building it
suprothunderbolt has quit [Quit: Leaving]
jstein has quit [Ping timeout: 260 seconds]
cnxsoft has joined #linux-sunxi
tllim has joined #linux-sunxi
tllim has quit [Client Quit]
lkcl has quit [Ping timeout: 252 seconds]
sunilmohan has quit [Read error: Connection reset by peer]
sunilmohan has joined #linux-sunxi
lkcl has joined #linux-sunxi
<pnill> remind me to never attempt that again..
<pnill> mingw sucks
<pnill> At least the sunxi-fel works now though on my windows stuff
<pnill> well "works"
<pnill> god knows..
<pnill> ls
<pnill> ^ wrong window...
<pnill> fail
buzzmarshall has quit [Remote host closed the connection]
victhor has quit [Ping timeout: 252 seconds]
sunshavi has quit [Read error: Connection reset by peer]
sunshavi has joined #linux-sunxi
gediz0x539 has joined #linux-sunxi
faruk has joined #linux-sunxi
<kveremitz> anyone here got experience of using NAND flash with allwinner boards? I gots an A13-Olinuxino-WiFi board with on-board NAND, but presently linux has no way to address it to read/write to/from it. I'm guessing there might not be a device-tree entry for it somewhere...
cmeerw has joined #linux-sunxi
<kveremitz> allegedly Android has some support, but I don't think I'm gonna figure out how to fudge one OS from the other... :D
reinforce has joined #linux-sunxi
gsz has joined #linux-sunxi
cmeerw has quit [Ping timeout: 260 seconds]
apritzel has joined #linux-sunxi
<KotCzarny> you should search the channel logs
<KotCzarny> and ofc wiki
<KotCzarny> but in general android's format is incompatible with alpha-maiinline nand format
<KotCzarny> and to add to the mix, bootrom uses its own format
apritzel has quit [Ping timeout: 252 seconds]
fl_0 has quit [Ping timeout: 245 seconds]
fl_0 has joined #linux-sunxi
hlauer has joined #linux-sunxi
camus has joined #linux-sunxi
kaspter has quit [Ping timeout: 240 seconds]
camus is now known as kaspter
jstein has joined #linux-sunxi
lerc has quit [Remote host closed the connection]
vagrantc has quit [Quit: leaving]
lerc has joined #linux-sunxi
<kveremitz> yeah I don't care about the flash formatting, just being able to use the damn thing :D
lerc has quit [Read error: Connection reset by peer]
<kveremitz> I've had a look at (1) olimex pages [useless] (2) sunxi wiki [negligible info on NAND] .. (3) google ..
<kveremitz> hence how/why I phrased my query how I did :)
<kveremitz> #whenrtfmdoesntappy
<kveremitz> apply* too
lerc has joined #linux-sunxi
lerc has quit [Remote host closed the connection]
lerc has joined #linux-sunxi
<libv> wasn't bootlin paid by nextthingco to implement nand for the a13 family?
\\Mr_C\\ has quit [Quit: Ping timeout: 999,999,999 years]
cnxsoft has quit [Ping timeout: 240 seconds]
warpme_ has joined #linux-sunxi
dev1990 has joined #linux-sunxi
cnxsoft has joined #linux-sunxi
\\Mr_C\\ has joined #linux-sunxi
apritzel has joined #linux-sunxi
<hlauer> did not get any comment for https://bitbucket.org/hlauer/kernel/src/master/patches/axp209-charge-current0.patchl since wednesday from the maintainers/lists - so time to submit?
\\Mr_C\\ has quit [Quit: Ping timeout: 999,999,999 years]
arnd has quit [Read error: Connection reset by peer]
lvrp16 has quit [Write error: Connection reset by peer]
\\Mr_C\\ has joined #linux-sunxi
arnd has joined #linux-sunxi
lvrp16 has joined #linux-sunxi
<wens> hlauer: replied now.
lightspot21 has joined #linux-sunxi
lightspot21 has joined #linux-sunxi
lightspot21 has quit [Changing host]
<hlauer> wens: thanks for the sysfs abi link. Is there an example of a good implementation of a writable "status" property?
<wens> hlauer: drivers/power/supply/bq24735-charger.c
<wens> AFAICT that seems to be the only one
<hlauer> thanks - will look into it
wigyori has quit [Changing host]
wigyori has joined #linux-sunxi
elros1 has joined #linux-sunxi
kaspter has quit [Ping timeout: 240 seconds]
kaspter has joined #linux-sunxi
matthias_bgg has joined #linux-sunxi
Mangy_Dog has joined #linux-sunxi
yann has quit [Ping timeout: 240 seconds]
yann has joined #linux-sunxi
victhor has joined #linux-sunxi
elros1 has quit [Remote host closed the connection]
atsampson has quit [Ping timeout: 245 seconds]
atsampson has joined #linux-sunxi
lucascastro has quit [Ping timeout: 268 seconds]
specing_ has joined #linux-sunxi
specing has quit [Ping timeout: 265 seconds]
specing_ is now known as specing
lucascastro has joined #linux-sunxi
lucascastro has quit [Remote host closed the connection]
lucascastro has joined #linux-sunxi
lucascastro has quit [Ping timeout: 268 seconds]
choozy has joined #linux-sunxi
nashpa_ has joined #linux-sunxi
nashpa has quit [Ping timeout: 268 seconds]
vagrantc has joined #linux-sunxi
lucascastro has joined #linux-sunxi
vagrantc has quit [Ping timeout: 260 seconds]
vagrantc has joined #linux-sunxi
faruk has quit [Quit: Leaving]
lucascastro has quit [Ping timeout: 245 seconds]
lightspot21 has quit [Quit: leaving]
reinforce has quit [Quit: Leaving.]
cnxsoft has quit [Quit: cnxsoft]
cmeerw has joined #linux-sunxi
prefixcactus has joined #linux-sunxi
camus has joined #linux-sunxi
kaspter has quit [Ping timeout: 252 seconds]
camus is now known as kaspter
lucascastro has joined #linux-sunxi
kaspter has quit [Ping timeout: 240 seconds]
kaspter has joined #linux-sunxi
JohnDoe_71Rus has joined #linux-sunxi
choozy has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
kaspter has quit [Ping timeout: 240 seconds]
kaspter has joined #linux-sunxi
ats_ has joined #linux-sunxi
atsampson has quit [Ping timeout: 245 seconds]
prefixcactus has quit [Ping timeout: 240 seconds]
insep_ has joined #linux-sunxi
insep_ has left #linux-sunxi ["User left"]
insep_ has joined #linux-sunxi
<insep_> did anyone try running plan9 on any allwinner device before?
<Kooda> insep_: I haven’t, but that would be neat! :)
matthias_bgg has quit [Ping timeout: 245 seconds]
matthias_bgg has joined #linux-sunxi
matthias_bgg has quit [Ping timeout: 240 seconds]
choozy has joined #linux-sunxi
<insep_> Kooda: do you have any pointers about where to start?
<insep_> besides catv
<Kooda> No idea, nope
<insep_> ok
camus has joined #linux-sunxi
kaspter has quit [Ping timeout: 240 seconds]
camus is now known as kaspter
<pnill> Is u-boot's CONFIG_USB_TTY compatible with sunxi boards?
<apritzel> pnill: I am afraid to have to give it a try, but it looks very old, it's not even in Kconfig ...
<pnill> just trying to find some non-serial way to communicate with U-Boot as the serial interface on my other board seems broken/not operational
<pnill> Was trying to test out my work with a 'stock' version of the same board
<pnill> but the end result wasn't what I'd expected
<pnill> and then serial wasn't working so not sure what's going on
<pnill> Was just now trying to get usb-ethernet support working
<apritzel> that should work
<pnill> yeah, I think the device tree is messing it up though because uboot only ever finds the controller
<pnill> and not the device
<apritzel> which device?
<pnill> The usb-ethernet adapter
<pnill> "HiRO H50224" based on google results AX88179 which should be supported by uboot
<apritzel> oh, you are talking about connecting an Ethernet adapter via USB to the board?
<apritzel> (I thought you are talking OTG here)
<pnill> yeah
<pnill> How does OTG work for that?
<pnill> would it show up as an ethernet device on my system?
<apritzel> enable CONFIG_USB_MUSB_GADGET
<apritzel> you connect port 0 to some host PC, then an USB Ethernet adapter would eventually appear
<apritzel> fastboot is another device U-Boot supports
<apritzel> bjt
JohnDoe_71Rus has quit [Quit: KVIrc 5.0.1 Aria http://www.kvirc.net/]
<apritzel> but if I were you I'd skip U-Boot
<apritzel> H6 supports HDMI in mainline Linux ...
<apritzel> if you (as a developer) need to play around with U-Boot, I'd try to get the serial fixed
<pnill> This uses some LVDS output thing
<pnill> idk if that's HDMI
<pnill> So, I think I might have fucked the pads on the other board when soldering on it awhile ago
<apritzel> so that's inside a cabinet with some custom LCD connected
<pnill> thus why serial is borked
<pnill> yeah, there's a custom LCD connected
<pnill> over a like 24~ pin connector
<apritzel> I don't think we have RGB LCD support for the H6
<pnill> reality is, I have the one working board... that I can use UART on
<pnill> and the one that was 'stock' I was trying to use to make sure my stuff would work for other people.
<pnill> that I can't use UART on
<pnill> but they're the exact same board.
<apritzel> but wasn't your goal to NOT use the UART for "other people"'s boards?
<pnill> yeah
<pnill> so, that's why it's an even better test
<pnill> lol
<pnill> just unfortunate that it did't work
<pnill> and I have no idea why now
<apritzel> we had missing transistors in serial lines on some TV boxes
<pnill> considering it's the same board, I don't think it's anything like that.
<pnill> all the components look relatively the same
<pnill> So for the usb ethernet gadget is it just this, https://i.imgur.com/PiZppXW.png
<pnill> Seems to write CONFIG_USB_MUSB_GADGET=y to the config
<pnill> I don't think that works, I end up getting musb_init_controller failed in the logs
buzzmarshall has joined #linux-sunxi
<apritzel> pnill: I think you need the right DT nodes for that
<apritzel> IIRC it works on the BananaPi M64, so you might want to have a look at that (both .dts and defconfig)
xes_ has quit [Read error: Connection reset by peer]
xes has joined #linux-sunxi
shailangsa has quit [Read error: Connection reset by peer]
Daanct12 has joined #linux-sunxi
Danct12 has quit [Ping timeout: 260 seconds]
Daanct12 has quit [Ping timeout: 252 seconds]
Daanct12 has joined #linux-sunxi
shailangsa has joined #linux-sunxi
jstein has quit [Ping timeout: 252 seconds]
lerc has quit [Ping timeout: 245 seconds]
lerc_ has joined #linux-sunxi
choozy has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
<pnill> looks like main difference in the bananaPi was dr_mode="otg"
<pnill> besides the fact that it used a different otg 'alias' I guess
<pnill> usb_otg vs usb2otg
<pnill> I guess that's because this uses usbphy2 0 vs the banana pi references usbphy 0
<pnill> I don't know what the differences are between them, but it makes me wonder if I'm setting it up for the right USB port
<pnill> looking at the h6 user manual and the address in the sunxi file it looks right... user manual has usb0(USB2.0_OTG) 0x510000 and sunxi dts has usb2otg: usb@5100000
<apritzel> pnill: remember, you don't need to invent anything: most things are already there, just in different boards
<pnill> yeah, was just verifying for sanity.
hlauer has quit [Ping timeout: 265 seconds]
<apritzel> pnill: the later Allwinner SoCs have *two* USB controllers connected to port 0: one nornmal EHCI/OHCI one (host port only), and the MUSB OTG controller
<apritzel> pnill: there is a mux connecting the two to the single set of pins
<pnill> Yeah, but I think dts dr_mode under usb2otg is supposed to define what mode it should operate in
<pnill> but have that setup to otg so maybe I have the wrong flags in the config
<apritzel> yes, we use the xHCI controller when "host" is specified, and the MUSB on "otg"
chewitt has quit [Quit: Zzz..]
<apritzel> since some boards have a type A socket connected to port 0, OTG doesn't make much sense, so we use "host" and never use the MUSB in normal operation (except for FEL, for instance)
<pnill> I think now it's getting left in OTG mode, as I can still see it in USB
<pnill> but it's not talking as an ethernet card or anything
<pnill> and if I disconnect/reconnect it windows says it malfunctioned.
<apritzel> pnill: did you add CONFIG_USB_MUSB_GADGET=y into the defconfig file?
<pnill> yeah
<apritzel> I think it triggers dependencies, which tends to not work correctly when just selected in menuconfig
<pnill> I also have CONFIG_USB_ETHER
<apritzel> pnill: on my H5 Orange Pi PC2 I see:
<apritzel> Allwinner mUSB OTG (Peripheral)
<apritzel> Net: phy interface7
<apritzel> eth0: ethernet@1c30000, eth1: usb_ether
<apritzel> with defconfig, so just CONFIG_USB_MUSB_GADGET=y
<apritzel> maybe it's something missing when using the H6 ...
<pnill> "musb_init_controller failed with status -22
<pnill> "
<pnill> not sure, but around where Net: eth0: happens
<pnill> that happens just before
<pnill> then throws no USB device found
<pnill> that's the defconfig
cmeerw has quit [Ping timeout: 250 seconds]
<pnill> and my dts, not sure what more I could add to it
<apritzel> wow, does 924 MHz work for you?
<pnill> yeah
<pnill> that's what the clock was set to on the stock config
<apritzel> I know
<pnill> Is it not supposed to? lol
<apritzel> I wasted half a year poking in all the DRAM registers, and at the end all I needed to do is to lower the DRAM frequency to make it work ...
<apritzel> the BSP driver uses different settings, so it sometimes gets to a higher frequency
<apritzel> would be good to know where the EINVAL (-22) comes from
<pnill> I uncommented the controller lines, but same thing: this is the whole log: https://pastebin.com/raw/9npNW0jz
<apritzel> pnill: can you add "#define DEBUG" as the *very first* line in drivers/usb/musb-new/sunxi.c (before all #includes), then recompile?
<pnill> apparently -22 is the result of "musb_platform_init"
<pnill> yeah.
<apritzel> yeah, I traced it down to sunxi_musb_init() in that file
<apritzel> I guess no one ever used OTG on an H6 board, so there might be some clocks or resets missing ...
camus has joined #linux-sunxi
kaspter has quit [Ping timeout: 265 seconds]
camus is now known as kaspter
<pnill> So, that didn't produce any additional output.
<pnill> with #define DEBUG
<pnill> at the top of drivers/usb/musb-new/sunxi.c
<apritzel> bummer
<pnill> musb_init_controller failed with status -22
<pnill> No USB device found
<pnill> Net: No ethernet found.
<pnill> just that.
<apritzel> let me try this here ...
<apritzel> pnill: does your board actually have a USB 3.0 socket?
<apritzel> right, I see it on the Pine H64 as well
<apritzel> -22 I mean, now for adding some printfs ...
<pnill> So, I don't know if any of them are USB 3.0/ It has 2x USB ports and 1x microusb
<pnill> and the microusb is where FEL is 'wired' to
<pnill> So I assume that's USB0
<apritzel> yes, it must be
<apritzel> was just curious, because I saw the USB 3.0 nodes in your DT ...
<apritzel> so sunxi_musb_init() is fine, it's an error triggered later, which then trickles down to the fail1: label
BenG83 has joined #linux-sunxi
<apritzel> got it: as I expected, check the definition of musb_read_configdata() ...
Daanct12 has quit [Quit: Quitting - Huong Tram IRC Client 1.54]
Daanct12 has joined #linux-sunxi
<pnill> I'm not sure what that's doing musb_readb(mbase,0x10+MUSB_CONFIGDATA)
<pnill> and it does musb_write as well
<pnill> but it also has static defs for H3_H5 and returns 0xde instead?
<pnill> is it that it needs to also return 0xde on an H6
<pnill> instead of attempting to do those writes?
warpme_ has quit [Quit: Connection closed for inactivity]
<apritzel> exactly
<apritzel> as I assumed, never tested on the H6, and U-Boot is full of those #ifdef quirks
<pnill> what actually defines "CONFIG_MACH_SUNXI_H3_H5"
<pnill> is that a def config
<apritzel> the H3 and H5 are pin compatible, and share almost everything, so this is a joint symbol to cover quirks and definitions that are true for both
<apritzel> generally there is one CONFIG_MACH_SUN?I_XX symbol per SoC
<pnill> ahh ok
<apritzel> in arch/arm/mach-sunxi/Kconfig
<pnill> I just added an #ifdef for _H6
<pnill> and before I even had my UART connected again (I forgot was messing with other board)
<pnill> saw the ethernet come up
<pnill> Allwinner mUSB OTG (Peripheral)
<pnill> Net: eth0: usb_ether
<pnill> I guess it's only showing up when I try to use the network
<pnill> then going away after
<apritzel> yes, just trying to get this actually to work
<apritzel> the timeout is ridiculously short (1 second): The remote end did not respond in time.
<apritzel> I see the device in my host's dmesg
<apritzel> (try "dhcp 0")
<pnill> musb-hdrc: peripheral reset irq lost!
<pnill> The remote end did not respond in time
<apritzel> try: setenv cdc_connect_timeout 10
<pnill> So my main system is windows and I'm trying to pass this into my ubuntu VM
<pnill> but windows just popped "device was not recognized/USB malfunction" kind of popup
<pnill> then the thing went back to saying "The remote end did not respond in time"
<pnill> but I don't actually have a dhcp server running on my system or anything..
<apritzel> it works for me with the longer timeout: on some proper OS :-D
<pnill> yeah, only other box I have is my mac laptop
<pnill> I just dunno why it disconnects
<pnill> after it connects
<pnill> repeatedly
lkcl has quit [Ping timeout: 252 seconds]
<apritzel> disconnect when?
<pnill> after the timeout
<apritzel> for me it waits, I do "ifconfig usb0 ....", then U-Boot proceeds with DHCP calls
<apritzel> U-Boot is single threaded, it does nothing in the background
<apritzel> the USB device only lives as long as a network command asks for it
<pnill> So while it's sitting there I get nothing
<pnill> oh...
<pnill> ok
<pnill> I thought it'd be active the whole time
<apritzel> once you see the prompt, U-Boot is really doing *nothing*
<pnill> heh
<pnill> that time it ended up locking up my vmware
<pnill> because of whatever the hell windows is doing to it
<apritzel> respect! ;-)
<pnill> it's weird because it worked like 1 time
<pnill> showed up as an ethernet device
<pnill> and never showed up as that again after
<pnill> lol
<pnill> guess it's time to see what the macbook does it it
<pnill> *with it
<pnill> since windows/vmware are being retarded.
<pnill> wait so if u-boot is single threaded, is this going to allow me to control u-boot in any way
<pnill> or is to just boot off of?
<pnill> The idea for this was to try to use it to get output from u-boot in some way or control it in a live fashion since I didn't have serial
<apritzel> this USB console thing is different, it's using a different driver
<apritzel> I guess that makes the difference
<apritzel> but I doubt that this old driver works, since MUSB needs SoC specific glue code, which I guess we don't have for that one
<apritzel> why do you want to control U-Boot via USB anyway?
<pnill> I don't really want to control it so much as like get feedback from it or my linux kernel
<pnill> because I lack UART on the other board
<apritzel> if you want to hack around, use serial, there is really no good alternative to it
<pnill> just trying to find a way to troubleshoot the fact that the 'hack' didn't do what I expected
<pnill> lol
<pnill> yeah, but serial literally isn't working on the other board.
<pnill> I've removed my header, re-soldered it.
lkcl has joined #linux-sunxi
<pnill> checked connectivity etc.
<apritzel> once it Linux a serial USB console should work
<pnill> Idk why it's borked.
<apritzel> s/it/in/
<pnill> the fact I understand what you mean with that means we're both nerds.
<apritzel> given you do the whole configfs rigmarole ...
<pnill> yeah never done that before, gonna have to do research on it
<pnill> My linux busybox setup wasn't even loading the mass storage last I was playing with it
<pnill> so idk how hard it'll be to get the otg stuff functioning for serial
<pnill> the linux side matters more than the u-boot side though
<pnill> because that's what's supposed to modify files on the emmc
<pnill> and it seemed as if it didn't do that.
<pnill> literally just found that via google
<pnill> lol
<apritzel> make sure to ignore most of it, only focus on configfs and friends
<apritzel> the USB_Gadget/Mass_storage page should be good, that was updated lately
<apritzel> but in general this is generic to Linux, there is really nothing deeply sunxi specific in there
<apritzel> so you can follow any USB Linux gadget tutorial out there
<apritzel> USB_Gadget/Ethernet seems to be good as well
BenG83 has quit [Quit: Leaving]
<pnill> configfs is the menuconfig stuff?
<apritzel> no, configfs is a Linux framework, where you can create USB devices like Lego, using "echo" on the shell and this special filesystem called "configfs"
<apritzel> it's a bit more involved than the old way (with fixed device configs in the kernel), but much more flexible
<apritzel> and most of it can be scripted
<apritzel> this way you can create multiple USB devices in parallel, so one serial plus Ethernet plus mass storage, for instance