ChanServ changed the topic of #dri-devel to: <ajax> nothing involved with X should ever be unable to find a bar
epoch101 has joined #dri-devel
epoch101_ has quit [Ping timeout: 480 seconds]
Nasina has joined #dri-devel
haaninjo has quit [Quit: Ex-Chat]
iive has quit [Quit: They came for me...]
Nasina has quit [Read error: Connection reset by peer]
bolson has quit [Ping timeout: 480 seconds]
Nasina has joined #dri-devel
Nasina has quit [Read error: Connection reset by peer]
Nasina has joined #dri-devel
Nasina has quit [Read error: Connection reset by peer]
jfalempe has quit [Quit: jfalempe]
jfalempe has joined #dri-devel
valpackett has joined #dri-devel
Nasina has joined #dri-devel
asrivats_ has quit [Read error: Connection reset by peer]
asrivats has quit [Remote host closed the connection]
Nasina has quit [Read error: Connection reset by peer]
asrivats_ has joined #dri-devel
asrivats has joined #dri-devel
feaneron has joined #dri-devel
davispuh has quit [Ping timeout: 480 seconds]
idr has quit [Ping timeout: 480 seconds]
valpackett has quit [Ping timeout: 480 seconds]
The_Company has joined #dri-devel
djbw has quit [Ping timeout: 480 seconds]
Company has quit [Ping timeout: 480 seconds]
feespay[m] has joined #dri-devel
epoch101 has quit [Ping timeout: 480 seconds]
djbw has joined #dri-devel
gnuiyl has quit [Remote host closed the connection]
Daanct12 has joined #dri-devel
Nasina has joined #dri-devel
nerdopolis has quit [Ping timeout: 480 seconds]
Nasina has quit [Read error: Connection reset by peer]
sguddati has joined #dri-devel
sadwylndev has quit []
YuGiOhJCJ has joined #dri-devel
roboporo has joined #dri-devel
<roboporo>
Hello,
<roboporo>
is there a reason why the atomic KMS API doesn't allow for changes to the props of a cursor plane (ex. crtc_x) in an asnyc/immediate commit?
<roboporo>
I am trying to get tearing (async page flips) and hardware cursors working together using the atomic API, but it doesn't work even though I know it does in X11
Nasina has joined #dri-devel
feespay[m] has quit [autokilled: Spambot. Mail support@oftc.net if you think this is in error. (2025-06-26 03:26:57)]
feaneron has quit [Ping timeout: 480 seconds]
sguddati has quit [Ping timeout: 480 seconds]
karolherbst has quit [Read error: Connection reset by peer]
karolherbst has joined #dri-devel
glennk has joined #dri-devel
libv has joined #dri-devel
sguddati has joined #dri-devel
Nasina has quit [Read error: Connection reset by peer]
Nasina has joined #dri-devel
sguddati has quit [Ping timeout: 480 seconds]
Duke`` has joined #dri-devel
<kode54>
roboporo: I already posted a question about this to a bunch of mailing lists and people, too
<kode54>
specifically, it's asking why the allowance check is even performed when the write is redundant
<kode54>
because both kwin and wlroots will spam fb_id=0 and crtc_id=0 every commit that the cursor is disabled
<kode54>
I also expressed that I attempted to make the atomic code only write properties that changed, dropping them from the commit if they'd be no-op writes
<kode54>
turns out that breaks things :D
<kode54>
the appropriate mailing list is indeed the dri-devel one
<kode54>
but I started on amd-gfx because my initial patch was against amd code
<kode54>
let me dig up the full thread on lore for amd-gfx
<kode54>
that particular patch should seal it up for you
<kode54>
not a properly formatted commit patch, because I was asking for feedback, and what a proper commit message should be
<kode54>
this patch makes it so that only the redundancy check is applied to the majority of properties
<kode54>
and so that the three that we want to allow, also pass a redundancy check
<kode54>
the reason I don't use the function for that, is because I don't want the alert message, since a fail will hit its own message in that path
<roboporo>
kode54: nice I guess I got lucky you asked already heh
<kode54>
yeah
<roboporo>
how would I go about trying the patch? I haven't really messed with kernel patches
<kode54>
which distribution are you using?
<roboporo>
arch
<kode54>
arch packages tend to make it easy to add patches to the build
<kode54>
pick your kernel, copy the patch file into the package root, add its filename to the sources list, updpkgsums after you have all the other sources
<kode54>
they usually have a loop in the prepare function to patch -Np1 anything named *.patch in the sources list
<roboporo>
in the PKGBUILD right?
<kode54>
yes
leo60228- has quit [Read error: Connection reset by peer]
<roboporo>
ok nice I'll try it then
leo60228 has joined #dri-devel
<roboporo>
hmmm wait now that I look at it wouldn't the crtc_x property just hit the drm_atomic_check_prop_changes path and fail?
<kode54>
that's a plane update
kzd has quit [Ping timeout: 480 seconds]
<kode54>
this function has to do with plane properties
<kode54>
crtc_x would hit that top function
<kode54>
hmm
<kode54>
weird, maybe it's spamming all plane properties even though it's a disabled cursor?
<cmarcelo>
glehmann: yeah, I can take a look tomorrow
sghuge has quit [Remote host closed the connection]
sghuge has joined #dri-devel
coldfeet has quit [Remote host closed the connection]
sguddati has quit [Ping timeout: 480 seconds]
vliaskov__ has quit [Remote host closed the connection]
MrCooper__ is now known as MrCooper
kts has joined #dri-devel
Moe_Icenowy is now known as MoeIcenowy
pepp has joined #dri-devel
fab has joined #dri-devel
pepp_ has quit [Ping timeout: 480 seconds]
jkrzyszt has joined #dri-devel
lynxeye has joined #dri-devel
gnuiyl has joined #dri-devel
Nasina has quit [Ping timeout: 480 seconds]
flto has quit [Remote host closed the connection]
flto has joined #dri-devel
Nasina has joined #dri-devel
coldfeet has joined #dri-devel
kts has quit [Ping timeout: 480 seconds]
coldfeet has quit [Quit: Lost terminal]
davispuh has joined #dri-devel
<DragoonAethis>
FYI: The Intel kernel CI infra is going down for the weekend due to the lab power shutdown. It'll be back online on Monday, more details in emails.
davispuh has quit [Ping timeout: 480 seconds]
warpme has quit []
RSpliet has quit [Quit: Bye bye man, bye bye]
RSpliet has joined #dri-devel
YuGiOhJCJ has quit []
jsa1 has quit [Ping timeout: 480 seconds]
feaneron has joined #dri-devel
jsa1 has joined #dri-devel
haaninjo has joined #dri-devel
dolphin has quit [Quit: Leaving]
Nasina has quit [Read error: Connection reset by peer]
Nasina has joined #dri-devel
<zamundaaa[m]>
<roboporo> "why not do an initial non-..." <- Because that is not required by the API, and tracking atomic state on the compositor side just makes the compositor more complicated and makes bugs a lot more likely
<zamundaaa[m]>
Or to put it another way, kernel regressions just have to be fixed in the kernel
warpme has joined #dri-devel
Nasina has quit [Read error: Connection reset by peer]
Daanct12 has quit [Quit: WeeChat 4.6.3]
jsa1 has quit [Remote host closed the connection]
Nasina has joined #dri-devel
Nasina has quit [Read error: Connection reset by peer]
jsa1 has joined #dri-devel
Nasina has joined #dri-devel
Nasina has quit [Read error: Connection reset by peer]
coldfeet has joined #dri-devel
coldfeet has quit [Quit: Lost terminal]
fab has quit [Quit: fab]
guludo has joined #dri-devel
Nasina has joined #dri-devel
Nasina has quit [Read error: Connection reset by peer]
f_ has quit [Ping timeout: 480 seconds]
<kode54>
I attempted to track the atomic state in the compositor library
<kode54>
it broke spectacularly :D
<kode54>
clearly this should be handled in the kernel
hansg has joined #dri-devel
<sima>
hm did I miss a fun discussion with this "track atomic state" thing?
fab has joined #dri-devel
odrling has quit [Remote host closed the connection]
odrling has joined #dri-devel
feaneron has quit [Ping timeout: 480 seconds]
<daniels>
sima: async commits disallowing any property set outside of the golden ones, even if they're the same as prior values
coldfeet has joined #dri-devel
<emersion>
these are allowed if they're the same as the previous ones
f_ has joined #dri-devel
nerdopolis has joined #dri-devel
coldfeet has quit [Quit: Lost terminal]
Nasina has joined #dri-devel
<sima>
daniels, uh ...
<sima>
async is very funny anyway, lots of special casing
Nasina has quit [Read error: Connection reset by peer]
<pac85>
One thing I don't get is why cursor updates are disallowed. The commit that introduces the check talks about modesetting being a problem but updating the cursor wouldn't cause modesetting right?
<pac85>
though perhaps cursors is an amd limitation? Not sure
<vsyrjala>
intel hw cursors can't do async. and moving a plane is a sync operation anyway
<emersion>
there was a patch to allow cursors on AMD
<emersion>
not sure what the status is
<pac85>
ah
<pac85>
anyway with legacy ig. none of this is an issue because cursor is handled completely separately so even if it is a sync update it doesn't affect page flipping?
<MrCooper>
vsyrjala: couldn't the HW/driver use the latest available cursor plane position for the next scanout cycle though?
<pac85>
yeah basically a mailbox
rasterman has quit [Quit: Gettin' stinky!]
<MrCooper>
something like that has to be happening anyway for the legacy cursor ioctl, isn't it?
digetx has quit [Ping timeout: 480 seconds]
digetx has joined #dri-devel
feaneron has joined #dri-devel
Xan[m] has joined #dri-devel
robmur01 has quit [Remote host closed the connection]
asrivats_ has quit [Ping timeout: 480 seconds]
Company has joined #dri-devel
asrivats_ has joined #dri-devel
robmur01 has joined #dri-devel
jkrzyszt_ has joined #dri-devel
jkrzyszt has quit [Ping timeout: 480 seconds]
mripard has quit [Quit: WeeChat 4.6.3]
epoch101 has joined #dri-devel
SquareWinter68 has quit [Ping timeout: 480 seconds]
<roboporo>
MrCooper: yeah that's what I'm interested in. Is it possible to add that path into the atomic api?
<emersion>
i've been discussing an AMEND thing numerous times in the past
<roboporo>
Having hardware cursors with async commits is definitley a feature missing in atomic vs legacy
coldfeet has joined #dri-devel
<roboporo>
emersion: an AMEND thing?
coldfeet has quit []
kzd has joined #dri-devel
<MrCooper>
not sure what AMEND would buy over ASYNC for the cursor plane
<MrCooper>
roboporo: a flag to amend a pending atomic commit instead of creating a new one
krumelmonster has quit [Ping timeout: 480 seconds]
kzd_ has joined #dri-devel
<roboporo>
Ah I see
<emersion>
MrCooper: i wouldn't want my cursor to tear, but with ASYNC it can happen
<emersion>
IMHO overloading ASYNC semantics isn't a good way forward
<zamundaaa[m]>
Yeah, I'd also prefer a separate amend flag
<zamundaaa[m]>
Even if the kernel internally confuses the two a lot
<pac85>
Yeah, mailbox has different semantics than tearing. If async can be either under the hood and you replace fb_id basically userspace would have no idea which buffer is being scanned out so it can't know which buffer is free to draw to I think. Overloading would only be acceptable for properties like x and y offset ig. However for cursor you also need to say "tear the plane I'm updating the fb onn but mailbox the cursor update"
kzd has quit [Ping timeout: 480 seconds]
<pac85>
or I guess you could do two commits with different flags?
<roboporo>
pac85: I actually tried just doing a seperate commit that only changed the cursor plane position
<MrCooper>
emersion: I don't necessarily disagree, the cursor plane needs to be usable with ASYNC anyway though (or ASYNC is kind of unusable with the cursor plane on), and maybe no tearing could be achieved differently, even just a gentlemen's agreement (is there any case where tearing is actually desirable for the cursor plane?)
krumelmonster has joined #dri-devel
<roboporo>
but it seemed to limit the pageflip rate to the vsync rate instead of allowing a higher "tearing" frame rate
<pac85>
MrCooper: if cursor can be updated with an amend flag then you'd just stop updating the cursor in the same commit as the flip perhaops?
<pac85>
bascially back to how legacy worked
<MrCooper>
roboporo: yep, any commit without ASYNC syncs to vblank
<roboporo>
yeah maybe the AMEND thing would just allow the seperate commit to not have to sync to vblank, but just change the cursor plane stuff
<roboporo>
I guess basically the cursor plane updates at vblank while the primary does async?
<MrCooper>
pac85: hmm, I guess that could kind of work, though it leaves a non-0 chance for the cursor amend commit to miss the next scanout cycle
<pac85>
MrCooper: If you want the cursor to not tear but the image to tear, intrinsically you are updating them not atomically. Even if you do it in one commit the image update may still happen ealier because it is allowed to tear whereas the cursor needs to be latched
<MrCooper>
one downside of AMEND is that it strictly speaking doesn't allow the driver to apply the cursor plane change during the ongoing scanout cycle, which some HW can do without tearing in some cases
<pac85>
uhm
<pac85>
I kinda feel like having an ioctl for cursor is the best option if it really has this hw dependent behavior that only applies to cursors
<pac85>
and the nice thing is, the cursor ioctl doesn't give you an event back so the change in semantics aren't visible to user space
<MrCooper>
could call it DRM_IOCTL_MODE_CURSOR(2) ;)
<pac85>
another important different in semantics is wgt vrr
<pac85>
I think rn if you update the cursor in a commit it triggers scanout right?
<pac85>
that's a huge problem imho
<pac85>
and amend wouldn't solve it either
<MrCooper>
right (at least that's supposed to happen, I understand there are driver bugs though), OTOH cursor plane moves should be applied for any LFC scanout cycles though
flto has quit [Remote host closed the connection]
flto has joined #dri-devel
<pac85>
yeah, legacy api behavior on amd. In practice it totally eliminates the whole cursor with vrr issue sine the panel is always refreshing at some decent rate due to lfc
<MrCooper>
ASYNC seems pretty close, except for tearing and triggering scanout with VRR
<pac85>
I mean, it is further than amend
<pac85>
I'm not sure how amend is specified would be nice to see the proposal
<MrCooper>
let's settle on both having one issue in common and another one each :)
jkrzyszt_ has quit [Remote host closed the connection]
<pac85>
lol yeah
<pac85>
but yeah if you want the legacy iotcl back I agree with you that's the best solution as it solves all three things very simply
Duke`` has joined #dri-devel
<pac85>
the alternative would be a pair of flags perhaps: a flag to do commits that don't touch vrr and a flag that makes the semantics non defined. Sounds like more work
olivial has quit [Read error: Connection reset by peer]
olivial has joined #dri-devel
jkrzyszt has joined #dri-devel
epoch101_ has joined #dri-devel
epoch101 has quit [Read error: Connection reset by peer]
asrivats_ has quit [Ping timeout: 480 seconds]
dsimic is now known as Guest18783
dsimic has joined #dri-devel
Guest18783 has quit [Ping timeout: 480 seconds]
Duke`` has quit [Ping timeout: 480 seconds]
<sima>
pac85, yeah async is supposed to be atomic, but with tearing allowed, which is extremely hw specific of what you can and cannot do
<pac85>
yeah I see
Fijxu has quit [Quit: XD!!]
Fijxu has joined #dri-devel
djbw has quit [Ping timeout: 480 seconds]
<MrCooper>
does AMEND really help for that though? E.g. if an ASYNC commit for the primary plane is followed by an AMEND commit for the cursor plane, doesn't the latter effectively become part of the ASYNC commit as well?
tobiasjakobi has joined #dri-devel
<pac85>
where are the semantics of the amend proposal specified (if anywhere)