<wens>
MoeIcenowy: so my guess is that this pcie controller is limited to serving only one device, no IO space support
<wens>
MoeIcenowy: do you have any preliminary work for pcie?
tl_lim has quit [Ping timeout: 260 seconds]
tl_lim has joined #linux-sunxi
<MoeIcenowy>
wens: IO space is an emulation of the in/out instruction of x86
<MoeIcenowy>
translate them to a MMIO space
<MoeIcenowy>
wens: I tried to restrict the memory space to 64K
TheSeven has quit [Ping timeout: 240 seconds]
<MoeIcenowy>
but the RC itself has 64K option ROM
<MoeIcenowy>
and fills the space
<wens>
RC? raid card?
<wens>
disable option rom? :)
<MoeIcenowy>
Root Complex
<MoeIcenowy>
the root node of PCIe
<MoeIcenowy>
like the HCI of USB
<MoeIcenowy>
something to mention: SATA cards have some traditional IO
<MoeIcenowy>
maybe now the only way is to write an EL2 wrapper
<wens>
oh
<MoeIcenowy>
(but I have no AArch64 bare-metal (and even EL2) development experience
TheSeven has joined #linux-sunxi
<MoeIcenowy>
and my WLAN cards all claim MEM space > 64K
<wens>
interesting... my iwlwifi only claims 8k
<wens>
MoeIcenowy: we can choose to not support IO space
<MoeIcenowy>
wens: if the capability of a card is not fully satisfied
<MoeIcenowy>
Linux will refuse to probe it
<wens>
well, then it remains unsupported until we figure a solution for the controller issues
<MoeIcenowy>
EL2 wrapper
<MoeIcenowy>
the crazy RaspberryPiPkg has done many crazy things with EL2, but with help from EDK2
<wens>
MoeIcenowy: seems like root complex claiming the whole space is not uncommon? it is a bridge, so it is exposing the window it can provide to devices connected to it
<wens>
which is 64k
<MoeIcenowy>
but it has extra cost
<wens>
I say we might not need the wrapper
<MoeIcenowy>
no
<MoeIcenowy>
we need
<wens>
we might just have a misunderstanding about how pci works
<MoeIcenowy>
you misunderstood.
<MoeIcenowy>
See this sentence 'Region 0: Memory at f2400000 (64-bit, non-prefetchable) [size=512K]'
<MoeIcenowy>
(from lspci -vv on my PC
<MoeIcenowy>
(it's an Atheros AR9462
<MoeIcenowy>
the memory section from 0xf2400000, size 512KiB, is allocated to the card
<MoeIcenowy>
and the driver can directly access 0xf2400000 to access the registers on the card
<wens>
yeah, and the bridge on the H6 doesn't support such a large window, so you can't use such a card with it
jbrown has quit [Ping timeout: 240 seconds]
<MoeIcenowy>
no it support
<MoeIcenowy>
but it doesn't fully map it to CPU
<wens>
but you said root complex claims 64k?
<MoeIcenowy>
it's not "Memory"
<MoeIcenowy>
it's "Expansion ROM"
<wens>
can we skip the AR9462 case?
<wens>
clearly it's not going to be usable without a lot of work
<wens>
do you have any patches that simply get the pcie controller to probe
<MoeIcenowy>
wens: I have
<MoeIcenowy>
(although probe means nothing
<MoeIcenowy>
oh not only r/w IO space needs muxing
<wens>
can you provide them somewhere? I simply want to see what the root complex looks like
<MoeIcenowy>
reads cards' config space also needs muxing
<wens>
yeah, but you only read card config space at probe time, no?
<wens>
or not
<wens>
anyway, one thing at a time
<wens>
a) get the controller to probe, b) config space, c) mmio space, d) probe a card
<MoeIcenowy>
P.S. probing the controller only reads the DBI space
<MoeIcenowy>
KotCzarny: you may mean lanes or wires?
<KotCzarny>
wires
<KotCzarny>
in chip
<MoeIcenowy>
wens: ok
<MoeIcenowy>
try to bring it up!
<MoeIcenowy>
and you will get weird
<wens>
yeah. I need to compile it as a module :(
<MoeIcenowy>
and if you do inspection with devmem2 command
<MoeIcenowy>
you will know what I'm saying
<MoeIcenowy>
the 0x05e00000 and 0x05500000 spaces are not in CPU memory space
<MoeIcenowy>
but in virtual memory space of PCIe
phdeswer has joined #linux-sunxi
<MoeIcenowy>
the design is so weird that only people that discover it by themselves can understand it
<KotCzarny>
MoeIcenowy: can it be hardwired to split half of the mapping into io and rest for mem banking?
<MoeIcenowy>
KotCzarny: no
<KotCzarny>
so you can pretend io would be always mapped
<wens>
ah, I see
<MoeIcenowy>
config space / io space are both a single 64K page
<MoeIcenowy>
wens: if you want to roar, do it ;-)
<wens>
so that's what the sunxi_pcie_bus_cutpage_* functions in the BSP are for
<MoeIcenowy>
yes
<MoeIcenowy>
and please note that "cutpage" is a real Chinglish
<MoeIcenowy>
I hope you can understand it ;-)
<KotCzarny>
:)
<wens>
I actually don't :(
tl_lim has quit [Ping timeout: 240 seconds]
<MoeIcenowy>
wens: ah "cut" means “切" here, which is short for "切换", "switching"
<MoeIcenowy>
*facepalm*
<wens>
*sigh*
tl_lim has joined #linux-sunxi
<KotCzarny>
MoeIcenowy: hmm, can you map them overlapping?
<MoeIcenowy>
KotCzarny: no
<KotCzarny>
or only single mapping can be active at a time
<MoeIcenowy>
only a single page can be mapped to the window at the same time
<KotCzarny>
sucks
<MoeIcenowy>
but if a wrapper is to be writing
<KotCzarny>
any workaround will kill the performance badly
<MoeIcenowy>
it will be quite simple
<KotCzarny>
MoeIcenowy: maybe arisc could be used as a background data copier for mem mapping and just leave io mapped?
<MoeIcenowy>
KotCzarny: there
<MoeIcenowy>
's no room for data copying
<adj_>
MoeIcenowy, so every driver must be patched to use that switching hack?
<wens>
wonder where the cutpage functions get called
<MoeIcenowy>
adj_: this is what BSP does
<MoeIcenowy>
wens: if you have a newer BSP
<MoeIcenowy>
it was called in "bcmdhdpci" driver
<wens>
oh great
<MoeIcenowy>
wens: it's quite simple
<MoeIcenowy>
writel(0x5500, 0x05401020) will map the virtual space <0x55000000 0x10000> (high 16 bit according to 0x05401020) to physical space <0x05410000 0x10000> (a fixed area)
<MoeIcenowy>
P.S. the one who ported UEFI EDK2 to Lumia phones (imbushuo) recently grabbed a Orange Pi One Plus from one of his friend (also mine)
<MoeIcenowy>
maybe he will do an EDK2 port for H6 soon? ;-)
<wens>
this is so idiotic. why would you have AXI masters, only not to use them properly
<wens>
MoeIcenowy: haven't looked, but I'm guessing bcmdhdpci doesn't use standard ioremap stuff?
BenG83 has quit [Ping timeout: 256 seconds]
selfbg has joined #linux-sunxi
yann|work has joined #linux-sunxi
<wens>
can we ask them what registers 0x1030 and 0x1034 are for?
The_Loko has joined #linux-sunxi
selfbg has quit [Remote host closed the connection]
afaerber has quit [Quit: Leaving]
tom_nov has joined #linux-sunxi
<MoeIcenowy>
wens: they have no response
<MoeIcenowy>
from Chinease New Year to now
selfbg has joined #linux-sunxi
BenG83 has joined #linux-sunxi
afaerber has joined #linux-sunxi
afaerber has quit [Client Quit]
tl_lim has quit [Read error: Connection reset by peer]
matthias_bgg has joined #linux-sunxi
The_Loko has quit [Ping timeout: 264 seconds]
<wens>
:(
The_Loko has joined #linux-sunxi
GrimKriegor has quit [Read error: Connection reset by peer]
hardfalcon has quit [Ping timeout: 248 seconds]
GrimKriegor has joined #linux-sunxi
AneoX_ has joined #linux-sunxi
hlauer has joined #linux-sunxi
AneoX has quit [Ping timeout: 264 seconds]
AneoX has joined #linux-sunxi
AneoX_ has quit [Ping timeout: 240 seconds]
imcsk8 has quit [Ping timeout: 245 seconds]
GrimKriegor has quit [Read error: Connection reset by peer]
montjoie has quit [Ping timeout: 264 seconds]
montjoie has joined #linux-sunxi
imcsk8 has joined #linux-sunxi
hardfalcon has joined #linux-sunxi
GrimKriegor has joined #linux-sunxi
kaspter has quit [Read error: Connection reset by peer]
kaspter has joined #linux-sunxi
[MisbehavingOS] has quit [Quit: There are paranoid crossroads and shipwreck alleys.]
[Destabilize] has joined #linux-sunxi
montjoie has quit [Ping timeout: 276 seconds]
GrimKriegor has quit [Read error: Connection reset by peer]
montjoie has joined #linux-sunxi
BenG83 has quit [Remote host closed the connection]
GrimKriegor has joined #linux-sunxi
montjoie has quit [Ping timeout: 256 seconds]
montjoie has joined #linux-sunxi
GrimKriegor has quit [Read error: Connection reset by peer]
camh has joined #linux-sunxi
GrimKriegor has joined #linux-sunxi
montjoie has quit [Ping timeout: 256 seconds]
xerpi has quit [Remote host closed the connection]
montjoie has joined #linux-sunxi
airwind has quit [Quit: Lost sanity]
BenG83 has joined #linux-sunxi
AneoX has quit [Read error: Connection reset by peer]
montjoie has quit [Ping timeout: 245 seconds]
AneoX has joined #linux-sunxi
nuuuciano has joined #linux-sunxi
montjoie has joined #linux-sunxi
afaerber has joined #linux-sunxi
elros has joined #linux-sunxi
montjoie has quit [Ping timeout: 276 seconds]
elros has quit [Read error: Connection reset by peer]
mavkhimenia has quit [Remote host closed the connection]
mavkhimenia has joined #linux-sunxi
imcsk8 has quit [Read error: Connection reset by peer]
imcsk8 has joined #linux-sunxi
a|3x has quit [Ping timeout: 268 seconds]
mavkhimenia has quit [Remote host closed the connection]
mavkhimenia has joined #linux-sunxi
mavkhimenia has quit [Ping timeout: 240 seconds]
f0xx has quit [Ping timeout: 265 seconds]
popolon has joined #linux-sunxi
phdeswer has quit [Ping timeout: 256 seconds]
paulk-leonov has quit [Ping timeout: 240 seconds]
dddddd has quit [Ping timeout: 276 seconds]
dddddd has joined #linux-sunxi
Gerwin_J has joined #linux-sunxi
dddddd has quit [Ping timeout: 256 seconds]
dddddd has joined #linux-sunxi
<micken>
Hi
<micken>
What is "offset" in genfb (NetBSD) I guess it is same in linux
<micken>
Uboot puts fb at be000000
<micken>
seems ok
JohnDoe_71Rus has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
dc13ff has joined #linux-sunxi
LargePrime has quit [Remote host closed the connection]
paulk-leonov has joined #linux-sunxi
kaspter has quit [Ping timeout: 256 seconds]
kaspter has joined #linux-sunxi
montjoie has quit [Ping timeout: 240 seconds]
montjoie has joined #linux-sunxi
aalm has quit [Ping timeout: 268 seconds]
msimpson_ has joined #linux-sunxi
f0xx has joined #linux-sunxi
msimpson_ has quit [Ping timeout: 248 seconds]
msimpson has quit [Ping timeout: 276 seconds]
msimpson_ has joined #linux-sunxi
<jakllsch>
micken: i think it's way to hoist the beginning of the framebuffer away from the beginning of video memory... but i should probably actually check
naggety has left #linux-sunxi ["Konversation terminated!"]
<jakllsch>
or maybe it's just the framebuffer address
cnxsoft has quit [Quit: cnxsoft]
<micken>
ok
<micken>
I can write to be000000 from RISC OS
<micken>
I have other problems after that :)
mavkhimenia has joined #linux-sunxi
<jakllsch>
beware virtual/physical translation
Andy-D_ has quit [Remote host closed the connection]
montjoie has quit [Ping timeout: 240 seconds]
<micken>
jakllsch: I am mapping it (MMU) and can clear the screen , put up a bitmap etc..
<micken>
jakllsch: the problems are later on,,, feels like RO writes outside teh screen
<micken>
:D
<hlauer>
wens: thanks for the info to 4.18 banana mmc pm issues. Is a patch somewhere/what to watch for ?
jbrown has joined #linux-sunxi
JohnDoe_71Rus has joined #linux-sunxi
msimpson_ has quit [Remote host closed the connection]
msimpson_ has joined #linux-sunxi
msimpson__ has joined #linux-sunxi
msimpson_ has quit [Ping timeout: 256 seconds]
BenG83 has quit [Remote host closed the connection]
kaspter has quit [Quit: kaspter]
reinforce has quit [Quit: Leaving.]
tom_nov has quit [Quit: Leaving]
phdeswer has joined #linux-sunxi
AneoX has quit [Ping timeout: 240 seconds]
AneoX has joined #linux-sunxi
Gerwin_J has quit [Quit: Gerwin_J]
phdeswer has quit [Ping timeout: 260 seconds]
msimpson__ has quit [Quit: Leaving]
IgorPec has quit [Ping timeout: 260 seconds]
montjoie has joined #linux-sunxi
hlauer has quit [Ping timeout: 276 seconds]
<wens>
hlauer: "mmc: sunxi: Disable irq during pm_suspend"
<wens>
on LAKML, discussion ongoing
Gerwin_J has joined #linux-sunxi
pmpp has quit [Ping timeout: 268 seconds]
montjoie has quit [Ping timeout: 240 seconds]
rexxster_ has joined #linux-sunxi
netlynx has joined #linux-sunxi
netlynx has quit [Changing host]
netlynx has joined #linux-sunxi
montjoie has joined #linux-sunxi
reinforce has joined #linux-sunxi
reinforce has quit [Quit: Leaving.]
f0xx has quit [Ping timeout: 268 seconds]
diego_r has quit [Ping timeout: 260 seconds]
mavkhimenia has quit [Remote host closed the connection]
mavkhimenia has joined #linux-sunxi
elros has quit [Remote host closed the connection]
aalm has joined #linux-sunxi
Gerwin_J has quit [Quit: Gerwin_J]
dc13ff has quit [Quit: Connection closed for inactivity]
clemens3 has quit [Remote host closed the connection]
AneoX_ has joined #linux-sunxi
AneoX has quit [Ping timeout: 264 seconds]
return0e has quit [Remote host closed the connection]
tllim has joined #linux-sunxi
afaerber has quit [Quit: Leaving]
tl_lim has joined #linux-sunxi
IgorPec has joined #linux-sunxi
scream has joined #linux-sunxi
tllim has quit [Ping timeout: 245 seconds]
yann|work has quit [Ping timeout: 260 seconds]
vagrantc has joined #linux-sunxi
a|3x has joined #linux-sunxi
Mandragor has quit [Ping timeout: 276 seconds]
popolon has quit [Ping timeout: 265 seconds]
f0xx has joined #linux-sunxi
montjoie has quit [Ping timeout: 265 seconds]
Mandragor has joined #linux-sunxi
matthias_bgg has quit [Ping timeout: 245 seconds]
leviathan has joined #linux-sunxi
hardfalcon has joined #linux-sunxi
leviathan has quit [Read error: Connection reset by peer]
montjoie has joined #linux-sunxi
leviathan has joined #linux-sunxi
mavkhimenia has quit [Remote host closed the connection]
freemangordon has joined #linux-sunxi
montjoie has quit [Ping timeout: 264 seconds]
dc13ff has joined #linux-sunxi
f0xx has quit [Ping timeout: 265 seconds]
AneoX has joined #linux-sunxi
scream has quit [Remote host closed the connection]
AneoX_ has quit [Ping timeout: 256 seconds]
scream has joined #linux-sunxi
anarsoul|3 has joined #linux-sunxi
tl_lim has quit [Ping timeout: 256 seconds]
AneoX_ has joined #linux-sunxi
tl_lim has joined #linux-sunxi
AneoX has quit [Ping timeout: 260 seconds]
aalm has quit [Ping timeout: 256 seconds]
yann|work has joined #linux-sunxi
IgorPec has quit [Ping timeout: 256 seconds]
hardfalcon has quit [Ping timeout: 256 seconds]
nemunaire has quit [Ping timeout: 256 seconds]
JohnDoe9 has joined #linux-sunxi
JohnDoe_71Rus has quit [Ping timeout: 245 seconds]