| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Signed-off-by: Lyude <lyude@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It turns out there's a difference in X between a CRTC being "disabled"
and simply having it's DPMS turned off. This is problematic though,
because if DPMS is turned off you can't really use the CRTC as a normal
CRTC anyway since page flipping and vblanks will be non-functional. As a
result, we've been considering DPMS-on CRTCs as enabled and attempt to
perform pageflips, vblank waits, etc. on them which inevitably fails. and
usually breaks the display the first time any of the CRTCs have their
DPMS turned on.
This was a problem that didn't really show itself until kernel 4.10 when
atomic modesetting was added which caused nouveau to stop trying to
fulfill pageflips and vblank waits on disabled CRTCs. I'm not sure how
pageflipping disabled CRTCs ever worked in the first place, but since
not doing so is the proper behavior anyway I haven't investigated any
further.
So, copy the ms_crtc_on() function from the modesetting driver and add
it here as drmmode_crtc_on(), then use that in all of the places where
we should be checking for both DPMS off and disabled CRTCs.
This fixes issues with the X ceasing to function (usually) after the
first time a CRTC has it's DPMS turned on. Reproduction recipe:
- Load up gnome-shell on a machine
- Wait for the display to timeout from inactivity and turn itself off
- Shake the cursor or press something on the keyboard. Chances are the
monitor will come back on, but the display remains black until the
next time the X server is restarted.
Signed-off-by: Lyude <lyude@redhat.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
|
|
|
|
|
| |
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
|
|
|
|
|
| |
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
|
|
|
|
|
|
|
|
| |
This flips GM10x to using the updated format, which is what I tested
with. However GM20x and GP10x also use this TIC format.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
|
|
|
|
|
|
|
| |
For consistency with mesa. It wasn't used anywhere previously.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
|
|
|
|
|
| |
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
|
|
|
|
|
|
|
| |
These are copied directly from the mesa repository.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Acked-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
rendercheck -f a8r8g8b8 passes as much as on a GK208, and xv appears to
work. Very lightly tested.
Instead of sticking coordinates into pushbufs, the vertex shader is
modified to read them from a constbuf, indexed by vertex id. This
approach could be used for all nvc0 generations, but I didn't want to
rock the boat.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
|
|
|
|
|
|
|
| |
- Fixes for reverse prime offload
- ABI 23 support for Xorg 1.19
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu
|
|
|
|
|
|
| |
NotifyFd is available after API 22, and must be used after API 23.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
drmmode_set_scanout_pixmap(pix) adds drmmod->fb_id through a call
to drmmode_xf86crtc_resize(), but on a subsequent
drmmode_set_scanout_pixmap(NULL) it would not remove the fb.
This keeps the crtc marked as busy, which causes the dgpu to not
being able to runtime suspend, after an output attached to the dgpu
has been used once. Which causes burning through an additional 10W
of power and the laptop to run quite hot.
This commit adds the missing remove fb call, allowing the dgpu to runtime
suspend after an external monitor has been plugged into the laptop.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
|
|
|
|
|
|
|
|
| |
I don't think these should actually be able to happen, given that we
already reject the unknown formats in the Check() functions. But,
just in case...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
|
|
|
|
|
|
| |
Reported by Coverity.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
|
|
|
|
|
|
|
|
| |
A port of commit ff9a6b6f from xf86-video-ati.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93670
Reported-by: Thomas D. <thfrdue@gmx.de>
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
| |
Various random fixes have been pending for a long while now...
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In multi-x-screen ZaphodHeads configurations, there isn't a
one-to-one mapping of kernel provided drmmode crtc index
to the index of the corresponding xf86Crtc inside the
xf86CrtcConfig crtc array anymore, ie. for kernel provided
drmmode->mode_res->crtcs[i], the i'th crtc won't correspond
to the xf86Crtc in the i'th slot of the x-screens xf86CrtcConfig
anymore, once ZaphodHeads has only selected a subset of all crtcs
of a graphics card for a given x-screen, instead of all crtcs.
This breaks the mapping of bit positions in the bit masks returned
in kencoder->possible_crtcs and kencoder->possible_clones. A 1 bit
in position i of those masks allows use of the kernels i'th crtc for
the given kencoder. The X-Servers dix code checks those bit masks
for valid xf86Output -> xf86Crtc assignments, assuming that the i'th
slot xf86CrtcConfigPtr config->crtc[i] corresponds to bit i in the
xf86Output->possibe_crtcs bitmask, and bails if the bitmask doesn't
allow the specified assignment of crtc to output. If ZaphodHeads
breaks the assumption of bit i <-> crtc slot i this ends in failure.
Take this shift of crtc index positions wrt. encoder bitmask bit
positions into account by bit-shifting positions accordingly when
assigning encoder->possible_crtcs to output->possible_crtcs, so
the proper indices match up again for validation by the dix.
This problem wasn't apparent last year when testing the ZaphodHeads
support on some Kepler cards, as apparently the encoder->possible_crtcs
bitmasks returned for those cards by the kernel just had all 4
lsb bits set for all tested encoders/output, so each of the cards 4
crtcs could go with each output and things worked by chance.
The current code breaks, e.g., on 2010 MacBookPro with nv50, where
one crtc is hardwired to the internal lvds panel, and one crtc
is hardwired to the external DP connector, resulting in a failure
where dual-display on single-x-screen works fine, but assigning
each output to a separate x-screen via ZaphodHeads fails due to
the mismatched encoder->possible_crtcs bitmasks.
This patch fixes the problem.
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
|
|
|
|
| |
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
| |
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=70931
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
|
| |
There is no EXA acceleration, and now no GLAMOR either.
User is better off with modesetting until EXA makes an appearance.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
|
|
| |
If you want glamor, just use modesetting instead. It's hooked up
incorrectly in nouveau, and there doesn't seem to be any point in fixing
it when the modesetting driver does it all properly.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Allow user to select the maximum level of DRI implementation
to use, DRI2 or DRI3.
exa accel supports both DRI2 and, if the kernel supports
rendernodes, also DRI3. However, DRI3 still seems to have
some bugs on current implementations, and additionally it
doesn't work well at all for X-Servers older than 1.16.3
due to X-Server bugs. Therefore we default to DRI2 on exa,
but allow the user to enable DRI3 with this new option.
nouveau's glamor accel backend currently doesn't work under
DRI2 at all, so we continue to use DRI3 whenever it is
supported and ignore this new option for now.
Also add a bit more output about status of Present and
DRI3 to aid debugging.
Note: This was originally meant to be a boolean parameter,
to just select between DRI3 on and off, but changed
here to a DRI level to make it consistent with the
same option in the released Intel-ddx.
v2: Use fixed up Bool return type of nouveau_present_init().
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Cc: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: Emil Velikov <emil.l.velikov@gmail.com>
Cc: Martin Peres <martin.peres@free.fr>
Cc: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
|
|
| |
Make it a Bool consistently, as declared in header.
Reported-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
| |
Reviewed-by: Dave Airlie <airlied@redhat.com>
|
|
|
|
|
|
|
| |
Mirrors commit b6d871bf2 (radeon: adopt for new X server dirty tracking
APIs.) in xf86-video-ati.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91284
|
|
|
|
|
|
|
|
|
|
|
| |
This is probably a typo error which has been introduced in 2009...
This fixes the following warning detected by Clang :
drmmode_display.c:907:30: warning: use of logical '&&' with constant operand [-Wconstant-logical-operand]
if (props && (props->flags && DRM_MODE_PROP_ENUM)) {
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
|
|
|
|
|
|
|
| |
As decoded by envydis. Perhaps these should move into separate files
similar to nvc0, but this seems like a simple intermediate solution.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
|
|
| |
Doing a solid copy of 0, or a clear, has the same effect. This is a
partial revert of commit 5439a9905eab8c. Pre-nv50 hardware succeeds with
copies more often.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
|
|
|
|
|
| |
A 32-bit shift is a no-op, which will also make the new planemask get
or'd with ~0, thus negating the usefulness of the subsequent
planemask != ~0 check. Only do this if it's a less-than-32-bit per pixel
format, in which case it will have the desired effect of setting the
high bits.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Martin Peres <martin.peres@free.fr>
|
|
|
|
|
|
|
|
|
|
| |
Pre-nv50 has all sorts of funny requirements for non-copy alu
operations, and will bail out of solid fills left and right. Account for
that case and fall back to the memset.
Reported-by: Andrew Randrianasulu <randrianasulu@gmail.com>
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Martin Peres <martin.peres@free.fr>
|
|
|
|
| |
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
| |
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
| |
Oops!
|
|
|
|
|
| |
The memcpy in the fallback path fails with SIGBUS on GK20A because
this memory is not coherent, try to use a solid fill instead.
|
|
|
|
| |
Judging from previous commits all linear buffers should have a 256 byte alignment.
|
| |
|
|
|
|
| |
Signed-off-by: Maarten Lankhorst <dev@mblankhorst.nl>
|
|
|
|
| |
Signed-off-by: Maarten Lankhorst <dev@mblankhorst.nl>
|
| |
|
|
|
|
| |
As reported by Roy Spliet.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
| |
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
|
|
| |
Only the NVA3/5/8/F tesla chips have a copy engine. Don't bother trying
to create one on earlier tesla chips (and thus printing an error on
failure).
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Highlights:
- Support for server managed fd's.
- Glamor support.
- Maxwell support.
- DRI3 and initial Present support.
- vsync'ed kms pageflip performance fixes when running on Linux 3.13+
- Multi-display vsync, vblank, swap scheduling, timestamping fixes.
- Multi x-screen support fixes.
- ZaphodHead support on for multiple outputs per x-screen.
- EXA nv-10 fixes.
- Enable sync of swaps to vblank by default (Option GLXVblank "on").
- Disable pseudo-triplebuffering by default (Option SwapLimit "1").
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
|