[Nouveau] [PATCH] volt/gk104: round up in gk104_volt_set

2016-04-16 Thread Karol Herbst
We always want a equal or higher voltage than the requested ones, otherwise
nouveau undervolts.

Signed-off-by: Karol Herbst 
---
 drm/nouveau/nvkm/subdev/volt/gk104.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drm/nouveau/nvkm/subdev/volt/gk104.c 
b/drm/nouveau/nvkm/subdev/volt/gk104.c
index 81788c2..9043dc8 100644
--- a/drm/nouveau/nvkm/subdev/volt/gk104.c
+++ b/drm/nouveau/nvkm/subdev/volt/gk104.c
@@ -57,7 +57,7 @@ gk104_volt_set(struct nvkm_volt *base, u32 uv)
 
/* the blob uses this crystal frequency, let's use it too. */
div = 27648000 / bios->pwm_freq;
-   duty = (uv - bios->base) * div / bios->pwm_range;
+   duty = DIV_ROUND_UP((uv - bios->base) * div, bios->pwm_range);
 
nvkm_wr32(device, 0x20340, div);
nvkm_wr32(device, 0x20344, 0x8000 | duty);
-- 
2.8.1

___
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau


Re: [Nouveau] [PATCH 1/2] nouveau/bl: Assign different names to interfaces

2016-04-16 Thread Pierre Moreau
On 02:40 PM - Apr 15 2016, Nick Tenney wrote:
> On Fri, Apr 15, 2016 at 11:25 AM, Ilia Mirkin  wrote:
> 
> > On Fri, Apr 15, 2016 at 11:22 AM, Pierre Moreau 
> > wrote:
> > > On 11:06 AM - Apr 15 2016, Ilia Mirkin wrote:
> > >> On Fri, Apr 15, 2016 at 10:57 AM, Pierre Moreau 
> > wrote:
> > >> > Currently, every backlight interface created by Nouveau uses the same
> > name,
> > >> > nv_backlight. This leads to a sysfs warning as it tries to create an
> > already
> > >> > existing folder. This patch adds a incremented number to the name,
> > but keeps
> > >> > the initial name as nv_backlight, to avoid possibly breaking
> > userspace; the
> > >> > second interface will be named nv_backlight1, and so on.
> > >> >
> > >> > Fixes: fdo#86539
> >
>  I believe Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=86539 is
> the preferred format. I think this is picked up by the mesa release scripts
> or some such.

Ack’ed. I’ll fix that in the v2.

Thanks!
Pierre

> 
> > >> > Signed-off-by: Pierre Moreau 
> > >> > ---
> > >> >  drm/nouveau/nouveau_backlight.c | 35
> > +--
> > >> >  1 file changed, 33 insertions(+), 2 deletions(-)
> > >> >
> > >> > diff --git a/drm/nouveau/nouveau_backlight.c
> > b/drm/nouveau/nouveau_backlight.c
> > >> > index 89eb460..914e2cb 100644
> > >> > --- a/drm/nouveau/nouveau_backlight.c
> > >> > +++ b/drm/nouveau/nouveau_backlight.c
> > >> > @@ -36,6 +36,10 @@
> > >> >  #include "nouveau_reg.h"
> > >> >  #include "nouveau_encoder.h"
> > >> >
> > >> > +static atomic_t bl_interfaces_nb = { 0 };
> > >>
> > >> static data is initialized to 0, this should be unnecessary.
> > >
> > > I didn’t know that. But on the other hand, I like having it explicit,
> > and it
> > > should not add any overhead.
> >
> > It increases the size of the object file. I believe it's kernel policy
> > to avoid static initializations to 0. (Note that this doesn't hold in
> > regular user applications, just the kernel.)
> >
> >   -ilia
> > ___
> > Nouveau mailing list
> > Nouveau@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/nouveau
> >

> ___
> dri-devel mailing list
> dri-de...@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel



signature.asc
Description: PGP signature
___
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau


[Nouveau] [Bug 94964] New: Tearing with opengl-hq and not with opengl on Gnome with MPV

2016-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=94964

Bug ID: 94964
   Summary: Tearing with opengl-hq and not with opengl on Gnome
with MPV
   Product: Mesa
   Version: unspecified
  Hardware: x86-64 (AMD64)
OS: Linux (All)
Status: NEW
  Severity: normal
  Priority: medium
 Component: Drivers/DRI/nouveau
  Assignee: nouveau@lists.freedesktop.org
  Reporter: jeremy9...@gmail.com
QA Contact: nouveau@lists.freedesktop.org

Tearing with opengl-hq and not with opengl on Gnome with MPV

Hello, I'm on Fedora 23 with Linux 4.4, Gnome Shell 3.18, MPV 0.17 and Nouveau
driver (Nvidia GT430). In windowed mode I have tearing with opengl-hq and not
with opengl. In fullscreen mode there is no tearing with both opengl-hq and
opengl.

Here is the commands to test

mpv --no-config --vo=opengl-hq movie.mkv
mpv --no-config --vo=opengl movie.mkv

With Netrunner 14.2 (KDE - Kubuntu 14.04 derivative), MPV 0.17 and Nvidia
proprietary drivers there is no tearing in windowed mode with opengl-hq. I
tried Gnome Shell and Plasma 5 on Manjaro too. There is no tearing with Nouveau
and Opengl-hq in windowed mode in Plasma 5 but there is stutter and there is
tearing with Gnome Shell.

Actually there is dropped frames with Nouveau and Opengl-hq in windowed mode in
all DE.

I opened an issue on MPV github and Wm4, the main MPV dev, said that my GPU
(Nvidia GT430) with Nouveau driver is maybe too slow (no reclocking ?).

https://github.com/mpv-player/mpv/issues/2501

For me the logical behavior should be like on Plasma 5 with Nouveau, no tearing
but if the GPU is not powerful enough the playback have stutter due to the
dropped frames.

I contacted Rui Matos, a Mutter developper, and he advise me to file a bug
here. Here is a summary of our talk to give all the infos I have :

Rui : Did you try gnome-shell on this environment (same as Plasma 5)? I
supposed it'd still tear.

Me : I tried Plasma 5 and Gnome Shell on Manjaro with Nouveau on the same
installation. The tearing was present in Gnome Shell but not on Plasma 5.

Rui : I'm afraid I can't help with this one, you'll have to file a nouveau bug.

Me: Can you confirm that even if the tearing was present in Gnome Shell but not
on Plasma 5 on the same install I should file a bug to Nouveau.

Rui: Is kwin using opengl compositing? For the comparison to be meaningful you
need to compare gnome-shell with kwin with opengl compositing enabled.

Me: I just checked to be sure and the opengl compositing is enabled for kwin
too.

Rui: Ok. I still might be a driver issue that just happens to be triggered by
different timings and API usage in mutter vs. kwin. Anyway, I can't really do
much without the hardware to test, so it's still better to report it to
nouveau.

Thank you !

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.___
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau


[Nouveau] [Bug 82152] [NVE7] NULL deref when putting card back to sleep after unsuccessful init (HUB_INIT timeout)

2016-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=82152

--- Comment #11 from Patrick Burroughs  ---
Created attachment 122992
  --> https://bugs.freedesktop.org/attachment.cgi?id=122992=edit
dmesg output with errors from successful load

With Linux 4.5.0-ARCH, Mesa 11.1.2-3, DRI3, and using modesetting_drv instead
of intel_drv for the main display (not sure if that's relevant)... everything
works! (If "everything" consists of glxinfo, glxgears, and a few minutes of
Darwinia.)

I do still get errors in dmesg, though, as attached. I'll be happy to follow
along and do whatever digging is necessary to eradicate them, if someone wants
to take up that task.

-- 
You are receiving this mail because:
You are the assignee for the bug.___
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau


[Nouveau] [Bug 92126] [NVE4] GTX 760 Auto fan speed stays at 10% until temp hits 90C

2016-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=92126

--- Comment #5 from Karol Herbst  ---
Is this bug fixed in recent kernels? (4.5 I think?)

-- 
You are receiving this mail because:
You are the assignee for the bug.___
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau