Now that we've extracted i915's code for reading both the normal DPCD
caps and extended DPCD caps into a shared helper, let's start using this
in nouveau to enable us to start checking extended DPCD caps for free.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau
Just a tiny drive-by cleanup, we can consolidate i915's code for
checking for MST support into a helper to be shared across drivers.
Signed-off-by: Lyude Paul
Reviewed-by: Sean Paul
---
drivers/gpu/drm/i915/display/intel_dp.c | 18 ++
include/drm/drm_dp_mst_helper.h
() in
intel_dp_detect_dpcd(), which is a functional change.
Signed-off-by: Lyude Paul
Reviewed-by: Sean Paul
---
drivers/gpu/drm/drm_dp_helper.c | 22 ++
drivers/gpu/drm/i915/display/intel_dp.c | 21 -
include/drm/drm_dp_helper.h | 8
in intel_dp_get_dpcd()
Signed-off-by: Lyude Paul
Reviewed-by: Sean Paul
---
drivers/gpu/drm/drm_dp_helper.c | 22 ++
drivers/gpu/drm/i915/display/intel_dp.c | 11 +--
include/drm/drm_dp_helper.h | 1 +
3 files changed, 28 insertions(+), 6 deletions(-)
diff
nt us from
sending unneeded hotplug events to userspace when nothing has actually
changed.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_connector.c | 54 ++---
1 file changed, 27 insertions(+), 27 deletions(-)
diff --git a/drivers/gpu/d
go ahead and just move
this code out of i915 into a shared DRM DP helper that we can use in
other drivers.
v2:
* Remove redundant dpcd[DP_DPCD_REV] == 0 check
* Fix drm_dp_dpcd_read() ret checks
Signed-off-by: Lyude Paul
Reviewed-by: Sean Paul
---
drivers/gpu/drm/drm_dp_helper.c | 77
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 16 +++-
1 file changed, 3 insertions(+), 13 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index 032afc73e2a33..201c0b4335563 100644
f mstm in nv50_mstm_detect() - thanks kernel
bot!
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv04/disp.c | 6 +-
drivers/gpu/drm/nouveau/dispnv50/disp.c | 192 +---
drivers/gpu/drm/nouveau/nouveau_connector.c | 14 +-
drivers/gpu/drm/n
if the connector is removed without a corresponding hpd event, so let's
fix that.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_connector.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_connector.c
b
Just use drm_dp_dpcd_(readb|writeb)() so we get automatic DPCD logging
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 11 +++
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/dispnv50/disp.c
b
, since we wouldn't be able to do anything without
DPCD access anyway.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 3 +++
drivers/gpu/drm/nouveau/nouveau_dp.c | 15 +++
drivers/gpu/drm/nouveau/nouveau_encoder.h | 1 +
3 files
Kernel bot!
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv04/dac.c | 2 +-
drivers/gpu/drm/nouveau/dispnv04/dfp.c | 7 +-
drivers/gpu/drm/nouveau/dispnv04/disp.c | 18 +
drivers/gpu/drm/nouveau/dispnv04/disp.h | 4 +
drivers/gpu/drm
Since fa3cdf8d0b09 ("drm/nouveau: Reset MST branching unit before
enabling") we've been clearing DP_MST_CTRL before we start enabling MST.
Since then clearing DP_MST_CTRL in nv50_mstm_new() has been unnecessary
and redundant, so let's remove it.
Signed-off-by: Lyude Paul
Reviewed-by:
No functional changes.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index 8db9216d52c69
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index 8a0f7994e1aeb..ee778ddc95fae 100644
Noticed this while going through our DP code - we use an open-coded
version of drm_dp_read_desc() instead of just using the helper, so
change that. This will also let us use quirks in the future if we end up
needing them.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm
Since this actually logs accesses, we should probably always be using
this imho…
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 12
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b
On Tue, 2020-08-25 at 08:28 +1000, Ben Skeggs wrote:
> On Tue, 25 Aug 2020 at 04:33, Lyude Paul wrote:
> > Not entirely sure why this never came up when I originally tested this
> > (maybe some BIOSes already have this setup?) but the ->caps_init vfunc
> > appears to
Since I'm almost certain I didn't get capability checking right for
pre-volta chipsets, let's start logging any caps we find to make things
like this obvious in the future.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 10 ++
1 file changed, 10 insertions
Changes since v1:
* Don't just program the DMA notifier offset, make sure to actually
perform an update
Signed-off-by: Lyude Paul
Fixes: 4a2cb4181b07 ("drm/nouveau/kms/nv50-: Probe SOR and PIOR caps for DP
interlacing support")
Cc: # v5.8+
---
drivers/gpu/drm/nouveau/d
ter(>ddc);
> > > > + ret = i2c_add_adapter(>ddc);
> > > > + if (ret)
> > > > + return ret;
> > > > +
> > > > + if (port->connector && port->connector->kdev) {
> > > > + ret = sysfs_create_link(>connector->kdev->kobj,
> > > > + >aux.ddc.dev.kobj, "ddc");
> > > > + if (ret)
> > > > + i2c_del_adapter(>aux.ddc);
> > > > + }
> > > > + return ret;
> > > > }
> > > >
> > > > /**
> > > > @@ -5513,6 +5536,8 @@ static int drm_dp_mst_register_i2c_bus(struct
> > > > drm_dp_mst_port *port)
> > > > */
> > > > static void drm_dp_mst_unregister_i2c_bus(struct drm_dp_mst_port *port)
> > > > {
> > > > + if (port->connector && port->connector->kdev)
> > > > + sysfs_remove_link(>connector->kdev->kobj, "ddc");
> > > > i2c_del_adapter(>aux.ddc);
> > > > }
> > > >
> > > > --
> > > > 2.28.0.rc0.142.g3c755180ce-goog
> > > >
--
Sincerely,
Lyude Paul (she/her)
Software Engineer at Red Hat
). Thanks kernel test robot!
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv04/dac.c | 2 +-
drivers/gpu/drm/nouveau/dispnv04/dfp.c | 7 +-
drivers/gpu/drm/nouveau/dispnv04/disp.c | 18 +
drivers/gpu/drm/nouveau/dispnv04/disp.h | 4 +
drivers
On Fri, 2020-08-21 at 01:37 +0300, Imre Deak wrote:
> On Wed, Aug 19, 2020 at 05:34:15PM -0400, Lyude Paul wrote:
> > (adding Ville and Imre to the cc here, they might be interested to know
> > about
> > this, comments down below)
> >
> > On Wed, 2020-08-1
in intel_dp_get_dpcd()
Signed-off-by: Lyude Paul
Reviewed-by: Sean Paul
---
drivers/gpu/drm/drm_dp_helper.c | 22 ++
drivers/gpu/drm/i915/display/intel_dp.c | 11 +--
include/drm/drm_dp_helper.h | 1 +
3 files changed, 28 insertions(+), 6 deletions(-)
diff
Just use drm_dp_dpcd_(readb|writeb)() so we get automatic DPCD logging
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 11 +++
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/dispnv50/disp.c
b
Since fa3cdf8d0b09 ("drm/nouveau: Reset MST branching unit before
enabling") we've been clearing DP_MST_CTRL before we start enabling MST.
Since then clearing DP_MST_CTRL in nv50_mstm_new() has been unnecessary
and redundant, so let's remove it.
Signed-off-by: Lyude Paul
Reviewed-by:
Now that we've extracted i915's code for reading both the normal DPCD
caps and extended DPCD caps into a shared helper, let's start using this
in nouveau to enable us to start checking extended DPCD caps for free.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 16 +++-
1 file changed, 3 insertions(+), 13 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index 032afc73e2a33..201c0b4335563 100644
if the connector is removed without a corresponding hpd event, so let's
fix that.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_connector.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_connector.c
b
they all check for DP_DETAILED_CAP_INFO_AVAILABLE anyway.
* Fix ret code check for drm_dp_dpcd_read
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/drm_dp_helper.c | 46 +
drivers/gpu/drm/i915/display/intel_dp.c | 14 ++--
include/drm/drm_dp_helper.h
, since we wouldn't be able to do anything without
DPCD access anyway.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 3 +++
drivers/gpu/drm/nouveau/nouveau_dp.c | 15 +++
drivers/gpu/drm/nouveau/nouveau_encoder.h | 1 +
3 files
() in
intel_dp_detect_dpcd(), which is a functional change.
Signed-off-by: Lyude Paul
Reviewed-by: Sean Paul
---
drivers/gpu/drm/drm_dp_helper.c | 22 ++
drivers/gpu/drm/i915/display/intel_dp.c | 21 -
include/drm/drm_dp_helper.h | 8
go ahead and just move
this code out of i915 into a shared DRM DP helper that we can use in
other drivers.
v2:
* Remove redundant dpcd[DP_DPCD_REV] == 0 check
* Fix drm_dp_dpcd_read() ret checks
Signed-off-by: Lyude Paul
Reviewed-by: Sean Paul
---
drivers/gpu/drm/drm_dp_helper.c | 77
Just a tiny drive-by cleanup, we can consolidate i915's code for
checking for MST support into a helper to be shared across drivers.
Signed-off-by: Lyude Paul
Reviewed-by: Sean Paul
---
drivers/gpu/drm/i915/display/intel_dp.c | 18 ++
include/drm/drm_dp_mst_helper.h
or MST..
* All of the duplicate DPCD version checks.
This leaves us with much nicer looking code, a much more sensible
locking scheme, and an easy way of checking whether MST is enabled or
not for handling DP HPD IRQs.
v2:
* Get rid of accidental newlines
Signed-off-by: Lyude Paul
Reviewed-b
receive a HPD IRQ. We also add a mask to
nouveau_drm to keep track of which connectors are waiting to be reprobed
in response to an HPD IRQ.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_connector.c | 42 +
drivers/gpu/drm/nouveau
probe_dpcd() and nouveau_dp_irq(), and reprobing the
connector if things change.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 54 ---
drivers/gpu/drm/nouveau/nouveau_encoder.h | 2 +
2 files changed, 51 insertions(+), 5
nt us from
sending unneeded hotplug events to userspace when nothing has actually
changed.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_connector.c | 54 ++---
1 file changed, 27 insertions(+), 27 deletions(-)
diff --git a/drivers/gpu/d
Since this actually logs accesses, we should probably always be using
this imho…
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 12
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b
No functional changes.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index 8db9216d52c69
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index 8a0f7994e1aeb..ee778ddc95fae 100644
it
with nv04_encoder_get_connector(), nv50_outp_get_old_connector(), and
nv50_outp_get_new_connector().
v2:
* Don't line-wrap for_each_(old|new)_connector_in_state in
nv50_outp_get_(old|new)_connector() - sravn
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv04/dac.c | 2
Noticed this while going through our DP code - we use an open-coded
version of drm_dp_read_desc() instead of just using the helper, so
change that. This will also let us use quirks in the future if we end up
needing them.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm
On Wed, 2020-08-19 at 11:29 -0400, Sean Paul wrote:
> On Tue, Aug 11, 2020 at 04:04:56PM -0400, Lyude Paul wrote:
> > Since DP 1.3, it's been possible for DP receivers to specify an
> > additional set of DPCD capabilities, which can take precedence over the
> > capabilities re
On Wed, 2020-08-19 at 11:29 -0400, Sean Paul wrote:
> On Tue, Aug 11, 2020 at 04:04:56PM -0400, Lyude Paul wrote:
> > Since DP 1.3, it's been possible for DP receivers to specify an
> > additional set of DPCD capabilities, which can take precedence over the
> > capabilities re
(adding Ville and Imre to the cc here, they might be interested to know about
this, comments down below)
On Wed, 2020-08-19 at 11:15 -0400, Sean Paul wrote:
> On Tue, Aug 11, 2020 at 04:04:50PM -0400, Lyude Paul wrote:
> > We're going to be doing the same probing process i
On Wed, 2020-08-19 at 11:15 -0400, Sean Paul wrote:
> On Tue, Aug 11, 2020 at 04:04:50PM -0400, Lyude Paul wrote:
> > We're going to be doing the same probing process in nouveau for
> > determining downstream DP port capabilities, so let's deduplicate the
> > work
ct inode *inode, struct file *file)
> > > > {
> > > > unsigned int minor = iminor(inode);
> > > > struct drm_dp_aux_dev *aux_dev;
> > > >
> > > > aux_dev = drm_dp_aux_dev_get_by_minor(minor);
> > > > if (!aux_dev)
> > > > return -ENODEV;
> > > >
> > > > file->private_data = aux_dev;
> > > > return 0;
> > > > }
> > > >
> > > >
> > > > ___
> > > > dri-devel mailing list
> > > > dri-de...@lists.freedesktop.org
> > > > https://lists.freedesktop.org/mailman/listinfo/dri-devel
>
>
--
Cheers,
Lyude Paul (she/her)
Software Engineer at Red Hat
nt us from
sending unneeded hotplug events to userspace when nothing has actually
changed.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_connector.c | 54 ++---
1 file changed, 27 insertions(+), 27 deletions(-)
diff --git a/drivers/gpu/d
() in
intel_dp_detect_dpcd(), which is a functional change.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/drm_dp_helper.c | 22 ++
drivers/gpu/drm/i915/display/intel_dp.c | 21 -
include/drm/drm_dp_helper.h | 8 +++-
3 files changed
if the connector is removed without a corresponding hpd event, so let's
fix that.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_connector.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_connector.c
b
probe_dpcd() and nouveau_dp_irq(), and reprobing the
connector if things change.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 54 ---
drivers/gpu/drm/nouveau/nouveau_encoder.h | 2 +
2 files changed, 51 insertions(+), 5 deletions(-)
diff --git a/d
Now that we've extracted i915's code for reading both the normal DPCD
caps and extended DPCD caps into a shared helper, let's start using this
in nouveau to enable us to start checking extended DPCD caps for free.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 14
And of course, we'll also need to read the sink count from other drivers
as well if we're checking whether or not it's supported. So, let's
extract the code for this into another helper.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/drm_dp_helper.c | 20
drivers/gpu
go ahead and just move
this code out of i915 into a shared DRM DP helper that we can use in
other drivers.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/drm_dp_helper.c | 76 +
drivers/gpu/drm/i915/display/intel_dp.c | 60 +---
drivers/gpu/drm/i915
number of
downstream ports, no sense in reading the whole thing every time
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/drm_dp_helper.c | 32 +
drivers/gpu/drm/i915/display/intel_dp.c | 14 ++-
include/drm/drm_dp_helper.h | 3 +++
3 files
, since we wouldn't be able to do anything without
DPCD access anyway.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 3 +++
drivers/gpu/drm/nouveau/nouveau_dp.c | 15 +++
drivers/gpu/drm/nouveau/nouveau_encoder.h | 1 +
3 files
Just a tiny drive-by cleanup, we can consolidate i915's code for
checking for MST support into a helper to be shared across drivers.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/i915/display/intel_dp.c | 18 ++
include/drm/drm_dp_mst_helper.h | 22
Just use drm_dp_dpcd_(readb|writeb)() so we get automatic DPCD logging
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 11 +++
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/dispnv50/disp.c
b
receive a HPD IRQ. We also add a mask to
nouveau_drm to keep track of which connectors are waiting to be reprobed
in response to an HPD IRQ.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_connector.c | 42 +
drivers/gpu/drm/nouveau
Since fa3cdf8d0b09 ("drm/nouveau: Reset MST branching unit before
enabling") we've been clearing DP_MST_CTRL before we start enabling MST.
Since then clearing DP_MST_CTRL in nv50_mstm_new() has been unnecessary
and redundant, so let's remove it.
Signed-off-by: Lyude Paul
Reviewed-by:
No functional changes.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index 8db9216d52c69
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 16 +++-
1 file changed, 3 insertions(+), 13 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index d701f09aea645..bb85d81c25244 100644
--- a/drivers/gpu/drm
or MST..
* All of the duplicate DPCD version checks.
This leaves us with much nicer looking code, a much more sensible
locking scheme, and an easy way of checking whether MST is enabled or
not for handling DP HPD IRQs.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/n
Since this actually logs accesses, we should probably always be using
this imho…
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 12
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b
it
with nv04_encoder_get_connector(), nv50_outp_get_old_connector(), and
nv50_outp_get_new_connector().
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm/nouveau/dispnv04/dac.c | 2 +-
drivers/gpu/drm/nouveau/dispnv04/dfp.c | 7 +-
drivers/gpu/drm/nouveau/dispnv04/disp.c | 18
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/nouveau_dp.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_dp.c
b/drivers/gpu/drm/nouveau/nouveau_dp.c
index 8a0f7994e1aeb..ee778ddc95fae 100644
--- a/drivers/gpu/drm/nouveau
Noticed this while going through our DP code - we use an open-coded
version of drm_dp_read_desc() instead of just using the helper, so
change that. This will also let us use quirks in the future if we end up
needing them.
Signed-off-by: Lyude Paul
Reviewed-by: Ben Skeggs
---
drivers/gpu/drm
code
nouveau :1f:00.0: disp: chid 0 stat 10003360 reason 3
[RESERVED_METHOD] mthd 0d80 data code
nouveau :1f:00.0: DRM: CRC notifier ctx for head 3 not finished
after 50ms
So, fix that.
Signed-off-by: Lyude Paul
Fixes: c4b27bc8682c ("drm/nouveau/kms
of this.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/dispnv50/head907d.c | 11 ++-
1 file changed, 2 insertions(+), 9 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/dispnv50/head907d.c
b/drivers/gpu/drm/nouveau/dispnv50/head907d.c
index 8f860e9c52247..85648d790743f 100644
--- a/drivers
Since I'm almost certain I didn't get capability checking right for
pre-volta chipsets, let's start logging any caps we find to make things
like this obvious in the future.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 10 ++
1 file changed, 10 insertions
Changes since v1:
* Don't just program the DMA notifier offset, make sure to actually
perform an update
Signed-off-by: Lyude Paul
Fixes: 4a2cb4181b07 ("drm/nouveau/kms/nv50-: Probe SOR and PIOR caps for DP
interlacing support")
Cc: # v5.8+
---
drivers/gpu/drm/nouveau/d
ata 508c 102b
This is magic nvidia speak for "You need to have the DMA notifier offset
programmed before you can call NV507D_GET_CAPABILITIES." So, let's fix
this by doing that.
Signed-off-by: Lyude Paul
Fixes: 4a2cb4181b07 ("drm/nouveau/kms/nv50-: Probe SOR an
Heh, I remember this being mentioned to me way back but completely forgot to
ever go fix it. Thanks for the patch!
Reviewed-by: Lyude Paul
This is missing a Fixes: tag though:
Fixes: 1e797f556c61 ("drm/dp: Split drm_dp_mst_allocate_vcpi")
Cc: # v4.12+
So I will go ahe
.
Signed-off-by: Lyude Paul
Fixes: 7fec8f5379fb ("drm/nouveau/drm/nouveau: Fix deadlock with fb_helper with
async RPM requests")
Cc: sta...@vger.kernel.org
Cc: Ben Skeggs
Cc: dri-de...@lists.freedesktop.org
Cc: nouv...@lists.freedesktop.org
Cc: # v4.19+
---
drivers/gpu/drm/nouveau/nouveau_f
We want to update the last busy timer for our device and use
pm_runtime_put_autosuspend() here instead so that our GPU can
autosuspend when we're done.
Signed-off-by: Lyude Paul
Fixes: f231976c2e89 ("drm/nouveau/fbcon: take runpm reference when userspace
has an open fd")
Cc: Ben Skegg
Again, we don't have any need to suspend the device synchronously here,
and doing so could in theory lead to a deadlock (although it's unlikely
since we've called pm_runtime_mark_last_busy() before-hand).
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/nouveau_display.c | 2 +-
1 file
This isn't an error, this just means there's multiple asynchronous
resume requests going at the same time. Treat it like a success.
Signed-off-by: Lyude Paul
Fixes: 79e765ad665d ("drm/nouveau/drm/nouveau: Prevent handling ACPI HPD events
too early")
Cc: sta...@vger.kernel.org
Cc: Ka
Signed-off-by: Lyude Paul
Fixes: 79e765ad665d ("drm/nouveau/drm/nouveau: Prevent handling ACPI HPD events
too early")
Cc: sta...@vger.kernel.org
Cc: Ben Skeggs
Cc: dri-de...@lists.freedesktop.org
Cc: nouv...@lists.freedesktop.org
Cc: # v4.19+
---
drivers/gpu/drm/nouveau/nouveau_dis
No functional changes here, just a drive-by cleanup.
Signed-off-by: Lyude Paul
[cc'd to stable since the next fix needs this patch to apply]
Fixes: 79e765ad665d ("drm/nouveau/drm/nouveau: Prevent handling ACPI HPD events
too early")
Cc: sta...@vger.kernel.org
Cc: Ben Skeggs
Looks like that we forgot to handle -EINPROGRESS being returned by
pm_runtime_get(), which can happen if multiple callers try to
asynchronously resume the GPU before it wakes up. This is perfectly
normal and OK, so fix this by treating -EINPROGRESS as success.
Signed-off-by: Lyude Paul
Fixes
While I don't know of any problems this has caused, it's definitely not
a great idea for us to potentially block in
nouveau_fbcon_set_suspend_work(). We don't really need to anyway, and
want to simply trigger the autosuspend timer instead.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau
Found another one, we forget to drop the runtime PM reference we grab
here in the event of a failure. So, do that.
Signed-off-by: Lyude Paul
Fixes: 3e1a12754d4d ("drm/nouveau: Fix deadlocks in nouveau_connector_detect()")
Cc: sta...@vger.kernel.org
Cc: Ben Skeggs
mic_release_notifier_contexts(struct drm_atomic_state *state)
> {}
> static inline void
> -nv50_crc_atomic_start_reporting(struct drm_atomic_state *) {}
> +nv50_crc_atomic_start_reporting(struct drm_atomic_state *state) {}
> static inline void
> -nv50_crc_atomic_set(struct nv50_head *, struct nv50_head_atom *) {}
> +nv50_crc_atomic_set(struct nv50_head *head, struct nv50_head_atom *asyh) {}
> static inline void
> -nv50_crc_atomic_clr(struct nv50_head *) {}
> +nv50_crc_atomic_clr(struct nv50_head *head) {}
>
> #endif /* IS_ENABLED(CONFIG_DEBUG_FS) */
> #endif /* !__NV50_CRC_H__ */
--
Cheers,
Lyude Paul (she/her)
Software Engineer at Red Hat
impossible-to-set modes to userspace by
validating the minimum bandwidth requirements of each display mode
against the maximum bandwidth supported by the MST connector.
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 41 +++--
drivers/gpu/drm/nouveau
e'll also need to be able to
pass down the current drm acquisition context for use in ->get_modes().
So, add another version of ->get_modes() which accepts an acquisition
context, ->get_modes_ctx().
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/drm_probe_helper.c | 11 ++
On Tue, 2020-07-21 at 12:00 -0400, Lyude Paul wrote:
> On Tue, 2020-07-21 at 18:27 +0300, Mika Westerberg wrote:
> > On Tue, Jul 21, 2020 at 11:01:55AM -0400, Lyude Paul wrote:
> > > Sure thing. Also, feel free to let me know if you'd like access to one
> > > of
>
On Tue, 2020-07-21 at 18:27 +0300, Mika Westerberg wrote:
> On Tue, Jul 21, 2020 at 11:01:55AM -0400, Lyude Paul wrote:
> > Sure thing. Also, feel free to let me know if you'd like access to one of
> > the
> > systems we saw breaking with this patch - I'm fairly sure I'v
Reviewed-by: Lyude Paul
Thanks!
On Tue, 2020-07-21 at 15:17 +, Wei Yongjun wrote:
> When using single_open() for opening, single_release() should be
> used instead of seq_release(), otherwise there is a memory leak.
>
> Fixes: 12885ecbfe62 ("drm/nouveau/kms/nvd9-
do
> to make both nouveau and TBT working at the same time.
>
> > oddly enough I wasn't able to reproduce it on my XPS 9560, will ping
> > once something breaks.
--
Cheers,
Lyude Paul (she/her)
Software Engineer at Red Hat
, fix the inline function declarations we use in
drm/drivers/gpu/drm/nouveau/dispnv50/crc.h when CONFIG_DEBUG_FS is
enabled.
Fixes: 12885ecbfe62 ("drm/nouveau/kms/nvd9-: Add CRC support")
Reported-by: kernel test robot
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/nouveau/dispnv50/
This is an ioctl callback, so we're guaranteed to have IRQs enabled when
calling this function. Use the plain _irq() variants of spin_(un)lock()
to make this more obvious.
Signed-off-by: Lyude Paul
Cc: Daniel Vetter
---
drivers/gpu/drm/drm_vblank.c | 7 +++
1 file changed, 3 insertions
This one's easy - we're already calling kzalloc() in this function, so
we must already be guaranteed to have IRQs enabled when calling this.
So, use the plain _irq() variants of spin_(un)lock() to make this more
obvious.
Signed-off-by: Lyude Paul
Cc: Daniel Vetter
---
drivers/gpu/drm
ock(). So, fix this to make the irq context of this function
more obvious.
Signed-off-by: Lyude Paul
Cc: Daniel Vetter
---
drivers/gpu/drm/drm_vblank.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/drm_vblank.c b/drivers/gpu/drm/drm_vblank.c
in
This function is only ever called from ioctl context, so we're
guaranteed to have interrupts enabled. Stop using the irqsave/irqrestore
variants of spin_(un)lock_irq() to make this more obvious.
Signed-off-by: Lyude Paul
Cc: Daniel Vetter
---
drivers/gpu/drm/drm_vblank.c | 5 ++---
1 file
This is only called from:
* Atomic modesetting hooks
* Module probing routines
* Legacy modesetting hooks
All of which have IRQs enabled, so we can also get rid of
irqsave/restore here to make the IRQ context of this function more
obvious.
Signed-off-by: Lyude Paul
Cc: Daniel Vetter
ut until
> we resolve all of those).
>
> Signed-off-by: Karol Herbst
> CC: Alex Hung
> CC: "Rafael J. Wysocki"
> CC: Len Brown
> CC: Lyude Paul
> CC: linux-kernel@vger.kernel.org
> CC: dri-de...@lists.freedesktop.org
> CC: nouv...@lists.freedeskt
On Thu, 2020-07-16 at 18:54 -0500, Bjorn Helgaas wrote:
> [+cc Sasha -- stable kernel regression]
> [+cc Patrick, Kai-Heng, LKML]
>
> On Fri, Jul 17, 2020 at 12:10:39AM +0200, Karol Herbst wrote:
> > On Tue, Jul 7, 2020 at 9:30 PM Karol Herbst wrote:
> > > Hi everybody,
> > >
> > > with the
T helpers so we can estimate the full_pbn
value as best we can.
Tested-by: Imre Deak
Reviewed-by: Imre Deak
Cc: Manasi Navare
Cc: Jani Nikula
Cc: Ville Syrjala
Cc: Cooper Chiou
Co-developed-by: Lyude Paul
Signed-off-by: Lee Shawn C
squash! drm/i915/mst: filter out the display mode exceed s
turn 0/ in drm_mode_validate_pipeline()
* Minor cleanup in drm_connector_mode_valid()
Tested-by: Imre Deak
Reviewed-by: Imre Deak
Cc: Lee Shawn C
Signed-off-by: Lyude Paul
---
drivers/gpu/drm/drm_crtc_helper_internal.h | 7 +-
drivers/gpu/drm/drm_probe_helper.c
301 - 400 of 923 matches
Mail list logo