#
✕ nick:marcan
#asahi · 2021-02-11 14:37
marcanwill do
#asahi · 2021-02-11 14:37
marcanI can just pull that in if you're OK with that
#asahi · 2021-02-11 14:37
marcanarnd: I think that kind of thing would work. It's certainly simple.
#asahi · 2021-02-11 14:24
marcanrobher: sure, I'll add something :)
#asahi · 2021-02-11 14:10
marcanrobher: just as an optimization?
#asahi · 2021-02-11 14:09
marcanthought so
#asahi · 2021-02-11 14:08
marcanI don't know if mapping the same region nGnRnE and nGnRE is legal though, per spec (which would happen for keep_bootcon on other platforms)
#asahi · 2021-02-11 14:07
marcanmaz: I think kettenis said they use nGnRnE for everything by default, which is some evidence that it isn't broken on other devices
#asahi · 2021-02-11 14:07
marcanbbiab, got some takeout pizza :)
#asahi · 2021-02-11 14:06
marcanyeah, I was thinking of that
#asahi · 2021-02-11 14:04
marcanand then just open-coding it in earlycon.c
#asahi · 2021-02-11 14:04
marcanthat needs a parallel implementation of the of stuff for FDTs
#asahi · 2021-02-11 14:04
marcannot yet :)
#asahi · 2021-02-11 14:04
marcanyup, I have the binding in my TODO
#asahi · 2021-02-11 14:01
marcanpatches with more - than + are always the best kind
#asahi · 2021-02-11 14:01
marcanarnd: re-pushed
#asahi · 2021-02-11 13:59
marcana7cfaf165e changed it in 2016
#asahi · 2021-02-11 13:59
marcanha, I was wondering why all the other drivers had dummies
#asahi · 2021-02-11 13:57
marcandone. tested working fine.
#asahi · 2021-02-11 13:56
marcanarnd: I just changed it, ok to force push?
#asahi · 2021-02-11 13:55
marcanrequest_mem_region in s3c24xx_serial_request_port
#asahi · 2021-02-11 13:51
marcanso I think it should be fine
#asahi · 2021-02-11 13:51
marcanheck there are more drivers doing that than plain devm_ioremap
#asahi · 2021-02-11 13:50
marcannot just that one too
#asahi · 2021-02-11 13:50
marcanarnd: honestly I think ditching _noreq and just doing what stm32-usart does is better
#asahi · 2021-02-11 13:49
marcanthe warped logic behind them. Beware all ye who read on.
#asahi · 2021-02-11 13:49
marcanYour guide to the ancient and twisted locking policies of the tty layer and
#asahi · 2021-02-11 13:49
marcan=================
#asahi · 2021-02-11 13:49
marcanThe Lockronomicon
#asahi · 2021-02-11 13:49
marcan=================
#asahi · 2021-02-11 13:49
marcanthere's a reason for Documentation/driver-api/serial/tty.rst which starts like this:
#asahi · 2021-02-11 13:48
marcanthe whole serial API is... kind of antiquated anyway
#asahi · 2021-02-11 13:48
marcanthat approach would work
#asahi · 2021-02-11 13:48
marcanstm32-usart.c just uses dummies for request/release and devm_ioremap_resource
#asahi · 2021-02-11 13:46
marcanthe problem with the latter is we lose the flags... so that needs to be checked separately
#asahi · 2021-02-11 13:45
marcanI just bulk s/AAPL/apple/ on everything
#asahi · 2021-02-11 13:45
marcanthat one's in my TODO
#asahi · 2021-02-11 13:45
marcandhewg: yeah, I'll go through all the commit messages
#asahi · 2021-02-11 13:44
marcani.e. walk up the tree until you find a positive/negative property, or until you hit a non-translatable boundary
#asahi · 2021-02-11 13:43
marcan(as I understood it anyway)
#asahi · 2021-02-11 13:43
marcanI think I implemented what robher described
#asahi · 2021-02-11 13:43
marcanhowever, the problem with moving mapping to the reserve/release functions is that by then the uart core thinks you just provided it with an mmio base/size to be mapped
#asahi · 2021-02-11 13:43
marcanmodwizcode: I think the intent is the reserve/release functions should do the mapping too, but in the samsung driver the mapping is done ahead of time *before* reservation
#asahi · 2021-02-11 13:42
marcanok, I'll do that in a bit (dinner first :))
#asahi · 2021-02-11 13:41
marcan(if you think that makes more sense)
#asahi · 2021-02-11 13:41
marcanI wasn't sure how much individual maintainers of those bits would want it split up, but I can certainly e.g. combine the generic asm ioremap_np(), IORESOURCE_MEM_NONPOSTED, devm_ioremap_np patches into one
#asahi · 2021-02-11 13:39
marcanno, the serial core has callbacks to reserve/release the region, but the structures used just have a base/size, so it loses the attributes if any if we go through that
#asahi · 2021-02-11 13:38
marcane.g. the samsung one does it because it reserves/frees the region in other functions, though arguably it should be doing the mapping there too, but then the serial core is ancient and does not have the resource concept... so that would have to go in driver private stuff if we used that
#asahi · 2021-02-11 13:37
marcantons of drivers do it though, manually
#asahi · 2021-02-11 13:36
marcandevm_ioremap_np too

plus ›