ChanServ changed the topic of #asahi-dev to: Asahi Linux: porting Linux to Apple Silicon macs | Non-development talk: #asahi | General development | GitHub: https://alx.sh/g | Wiki: https://alx.sh/w | Logs: https://alx.sh/l/asahi-dev
raveling has joined #asahi-dev
amw has joined #asahi-dev
raveling has quit [Ping timeout: 480 seconds]
amw has quit [Ping timeout: 480 seconds]
raveling has joined #asahi-dev
gabuscus has quit []
raveling has quit [Ping timeout: 480 seconds]
gabuscus has joined #asahi-dev
A_L_I_C_E has joined #asahi-dev
A_L_I_C_E has quit [Remote host closed the connection]
crabbedhaloablut has quit [Ping timeout: 480 seconds]
yuyichao has quit [Quit: Konversation terminated!]
crabbedhaloablut has joined #asahi-dev
chadmed_ has quit [Remote host closed the connection]
crabbedhaloablut has quit []
A_L_I_C_E has joined #asahi-dev
crabbedhaloablut has joined #asahi-dev
raveling has joined #asahi-dev
raveling has quit [Ping timeout: 480 seconds]
newiz has joined #asahi-dev
A_L_I_C_E has quit [Read error: Connection reset by peer]
chadmed_ has joined #asahi-dev
yuyichao has joined #asahi-dev
A_L_I_C_E has joined #asahi-dev
raveling has joined #asahi-dev
raveling has quit [Ping timeout: 480 seconds]
raveling has joined #asahi-dev
A_L_I_C_E has quit [Ping timeout: 480 seconds]
A_L_I_C_E has joined #asahi-dev
raveling has quit [Ping timeout: 480 seconds]
raveling has joined #asahi-dev
raveling has quit [Ping timeout: 480 seconds]
raveling has joined #asahi-dev
chadmed_ has quit [Quit: Page closed]
i509vcb has quit [Quit: Connection closed for inactivity]
Mary has quit [Quit: The Lounge - https://thelounge.chat]
<kettenis> jannau: that RTKit message should be changed to mention the actual address
newiz has quit [Quit: Konversation terminated!]
<jannau> kettenis: those are the address and end. the device's SRAM region is not printed
<jannau> dt has <0x2 0x4ec9c000 0x0 0x8000> as SRAM
<jannau> adt has "region-id-91 = [0x000000024EC00000, 0x0000000000140000]" which would cover everything
kedde1 has joined #asahi-dev
<jannau> doubling the size of the SRAM region fixes that. still doesn't work but looks like a different error
kedde has quit [Ping timeout: 480 seconds]
nyilas has joined #asahi-dev
<ChaosPrincess> writing a drm kms driver, the atomic_flush callback only gets called two times, despite x seeming to grab that screen. any suggestions on what i might be doing wrong? https://github.com/WhatAmISupposedToPutHere/linux/blob/adp/drivers/gpu/drm/adp/adp_drv.c
nsklaus has joined #asahi-dev
<jannau> ChaosPrincess: Xorg/modesetting driver doesn't do swaps. it will just update the framebuffer
nyilas has quit [Remote host closed the connection]
<ChaosPrincess> so, like, my hardware doesnt support that. you must do flushes for it to grab the new framebuffer contents.
Mary has joined #asahi-dev
nyilas has joined #asahi-dev
<jannau> not sure if drm/kms has something for that case. it has to have though. I would look at displaylink driver or the usb display gagdet driver. those have to have the same problem. for testing you could use weston instead of X
bps has joined #asahi-dev
<ChaosPrincess> doesnt the dcp driver have the same problem?
<ChaosPrincess> or it can grab fb updates without a swap?
<jannau> no, the actual display controller scans the current fb(s) continuously out
<jannau> if it didn't that simpledrm wouldn't work
<jannau> I don't see how drivers/gpu/drm/udl handles that. maybe modeset acts differently with drm_gem_fb_create_with_dirty / damage regions / DRM_GEM_SHADOW_PLANE_FUNCS
<ChaosPrincess> looks like drm_atomic_helper_dirtyfb is what i need
<ChaosPrincess> looking at rockchip driver
<ChaosPrincess> also, is there a way to specify the primary display in the dt? sddm attempts to render to the touchbar display when it starts up, which is undesirable
<_jannau_> I don't think so. does your driver gets card0? If so I need to see if there is a way the apple driver can ensure it gets card0 from simpledrm. That of course only helps if simpledrm is built-in and the other drivers are modules
<_jannau_> only solution in practice will be to ensure the touchbar daemon is started early
<_jannau_> does the fb console use the touchbar display as well?
<kettenis> jannau: ah, misread the code then
<kettenis> sound plausible that the SRAM is bigger and they moved things around in a newer firmware version
<ChaosPrincess> _jannau_: i am getting card0, and whats stranger is it does so, even though i built dcp in-kernel and touchbar as module
<ChaosPrincess> the text console display on primary screen
<ChaosPrincess> +S
<_jannau_> dcp fails to take over card0 from simpledrm. I didn't care enough to check if we can ensure that it works. so card0 might be available after gpu and dcp driver are loaded. The next loaded driver (your module) gets it on init time then
nsklaus has quit [Quit: ZZZzzz…]
nela has quit [Quit: bye!]
nela has joined #asahi-dev
nsklaus has joined #asahi-dev
nsklaus has quit []
kedde2 has joined #asahi-dev
kedde1 has quit [Ping timeout: 480 seconds]
unko has quit [Quit: cya]
Chinese_soup has joined #asahi-dev
CoolStar has quit [Remote host closed the connection]
WindowPa- has joined #asahi-dev
WindowPain has quit [Ping timeout: 480 seconds]
nsklaus has joined #asahi-dev
WindowPa- has quit [Remote host closed the connection]
cylm has joined #asahi-dev
WindowPain has joined #asahi-dev
gabuscus has quit [Ping timeout: 480 seconds]
<_jannau_> ok for now but ideally it should be only non-fatal for the framebuffer. Should be easily possible after we handle the other reserved regions via the "segments" ADT property
<ChaosPrincess> ok, figured out dirty framebuffers, now have a problem where hardware coordinates are rotated 90 degrees anticlockwise compared to what linux expects
<ChaosPrincess> is there something that can already deal with that
<kettenis> there is the panel orientation stuff
<kettenis> see the "rotation" property in Documentation/devicetree/bindings/display/panel/panel-common.yaml
<ChaosPrincess> isnt that rotating the panel, not crtc coordinates?
<_jannau_> drm/kms has also panel orientation properties. Those should be used by userspace
<kettenis> ChaosPrincess: isn't that the same?
___nick___ has joined #asahi-dev
<kettenis> if the crtc coordinates don't match the panel orientation, the panel is rotated
<_jannau_> ChaosPrincess: search for panel_orientation in https://www.kernel.org/doc/html/next/gpu/drm-kms.html
nicolas17 has joined #asahi-dev
<ChaosPrincess> calling drm_connector_set_panel_orientation(&adp->connector, DRM_MODE_PANEL_ORIENTATION_RIGHT_UP); did not help
<ChaosPrincess> image is still rotated
<nicolas17> ChaosPrincess: hey I remember a while ago I tested your spi-nor patch on M2 and it didn't work
<nicolas17> did you continue on that? did it even get merged for the m1 part?
<_jannau_> ChaosPrincess: is it reported correctly by drm_info https://gitlab.freedesktop.org/emersion/drm_info
<ChaosPrincess> its in my tree, it works for m1, no comments on m2, i dont have them
gabuscus has joined #asahi-dev
<ChaosPrincess> _jannau_: │ └───"panel orientation" (immutable): enum {Normal, Upside Down, Left Side Up, Right Side Up} = Left Side Up
<_jannau_> I don't know who's supposed to handle the rotation
WindowPa- has joined #asahi-dev
WindowPa| has joined #asahi-dev
WindowPain has quit [Ping timeout: 480 seconds]
WindowPa- has quit [Ping timeout: 480 seconds]
WindowPain has joined #asahi-dev
___nick___ has quit []
WindowPa| has quit [Ping timeout: 480 seconds]
___nick___ has joined #asahi-dev
___nick___ has quit []
WindowPain has quit [Read error: Connection reset by peer]
___nick___ has joined #asahi-dev
WindowPain has joined #asahi-dev
WindowPain has quit [Read error: Connection reset by peer]
WindowPain has joined #asahi-dev
<dottedmag> The property description kinda says it's up to userspace: "Optional connector property indicating how the lcd-panel is mounted inside the casing (e.g. normal or upside-down)"
<dottedmag> And "DOC: standard connector properties" in drivers/gpu/drm/drm_connector.c confirms it
i509vcb has joined #asahi-dev
cylm has quit [Ping timeout: 480 seconds]
<jannau> nicolas17, ChaosPrincess: spi-nor / nvram partition as in asahi-6.2-12 works as intended on m2
<kettenis> sweet, my cpio/initrd based firmware loader works in u-boot
A_L_I_C_E has quit [Quit: Quit]
A_L_I_C_E has joined #asahi-dev
<nicolas17> jannau: oh so someone else implemented in the meantime?
<jannau> not sure. it is still ChaosPrincess patch. I might did some minor modifications and tested it. iirc
raveling has quit [Ping timeout: 480 seconds]
bps has quit [Ping timeout: 480 seconds]
<nicolas17> ah
Cyrinux9 has quit []
Cyrinux9 has joined #asahi-dev
<kettenis> that has code to load the asmedia controller firmware
<kettenis> as a side-effect, it should leave the controller alone if the firmware could not be loaded
* jannau goes off preparing the do not init port if link is already up patch
CoolStar has joined #asahi-dev
___nick___ has quit [Ping timeout: 480 seconds]
maximbaz has quit [Quit: bye]
maximbaz has joined #asahi-dev
A_L_I_C_E has quit [Ping timeout: 480 seconds]
A_L_I_C_E has joined #asahi-dev
CME has quit [Ping timeout: 480 seconds]
CME has joined #asahi-dev
nsklaus has quit [Quit: ZZZzzz…]
manawyrm has quit [Quit: Read error: 2.99792458 x 10^8 meters/second (Excessive speed of light)]
manawyrm has joined #asahi-dev
<ChaosPrincess> ended up rotating the buffer in software. Technically works, but very much not a solution i like
nopeslide13 has quit []
nyilas has quit [Remote host closed the connection]
nopeslide13 has joined #asahi-dev