search for: drm_dp_mst_topology_put_mstb

Displaying 20 results from an estimated 38 matches for "drm_dp_mst_topology_put_mstb".

2018 Dec 20
0
[PATCH v2 01/16] drm/dp_mst: Rename drm_dp_mst_get_validated_(port|mstb)_ref and friends
s/drm_dp_get_validated_port_ref/drm_dp_mst_topology_get_port_validated/ s/drm_dp_put_port/drm_dp_mst_topology_put_port/ s/drm_dp_get_validated_mstb_ref/drm_dp_mst_topology_get_mstb_validated/ s/drm_dp_put_mst_branch_device/drm_dp_mst_topology_put_mstb/ This is a much more consistent naming scheme, and will make even more sense once we redesign how the current refcounting scheme here works. Signed-off-by: Lyude Paul <lyude at redhat.com> Cc: Daniel Vetter <daniel at ffwll.ch> Cc: David Airlie <airlied at redhat.com> Cc: Jerry...
2019 Sep 03
0
[PATCH v2 13/27] drm/dp_mst: Refactor drm_dp_mst_handle_down_rep()
...) { - DRM_DEBUG_KMS("Got MST reply with no msg %p %d %d %02x %02x\n", - mstb, - mgr->down_rep_recv.initial_hdr.seqno, - mgr->down_rep_recv.initial_hdr.lct, - mgr->down_rep_recv.initial_hdr.rad[0], - mgr->down_rep_recv.msg[0]); - drm_dp_mst_topology_put_mstb(mstb); - memset(&mgr->down_rep_recv, 0, sizeof(struct drm_dp_sideband_msg_rx)); - return 0; - } + drm_dp_sideband_parse_reply(&mgr->down_rep_recv, &txmsg->reply); - drm_dp_sideband_parse_reply(&mgr->down_rep_recv, &txmsg->reply); + if (txmsg->reply.repl...
2018 Dec 14
0
[WIP PATCH 03/15] drm/dp_mst: Introduce new refcounting scheme for mstbs and ports
...+The DP MST helpers use the following functions to manage topology refcounts: + +.. kernel-doc:: drivers/gpu/drm/drm_dp_mst_topology.c + :functions: drm_dp_mst_topology_get_port drm_dp_mst_topology_put_port + drm_dp_mst_topology_ref_port drm_dp_mst_topology_get_mstb + drm_dp_mst_topology_put_mstb drm_dp_mst_topology_ref_mstb + +Malloc refcount overview +~~~~~~~~~~~~~~~~~~~~~~~~ + +Malloc references are used to keep a :c:type:`struct drm_dp_mst_port` or +:c:type:`struct drm_dp_mst_branch` allocated even after all of its topology +references have been dropped, so that the driver or MST helper...
2018 Dec 14
2
[WIP PATCH 03/15] drm/dp_mst: Introduce new refcounting scheme for mstbs and ports
...the following functions to manage topology refcounts: > + > +.. kernel-doc:: drivers/gpu/drm/drm_dp_mst_topology.c > + :functions: drm_dp_mst_topology_get_port drm_dp_mst_topology_put_port > + drm_dp_mst_topology_ref_port drm_dp_mst_topology_get_mstb > + drm_dp_mst_topology_put_mstb drm_dp_mst_topology_ref_mstb > + > +Malloc refcount overview > +~~~~~~~~~~~~~~~~~~~~~~~~ > + > +Malloc references are used to keep a :c:type:`struct drm_dp_mst_port` or > +:c:type:`struct drm_dp_mst_branch` allocated even after all of its topology > +references have been droppe...
2018 Dec 19
1
[WIP PATCH 03/15] drm/dp_mst: Introduce new refcounting scheme for mstbs and ports
...ts: > > > + > > > +.. kernel-doc:: drivers/gpu/drm/drm_dp_mst_topology.c > > > + :functions: drm_dp_mst_topology_get_port drm_dp_mst_topology_put_port > > > + drm_dp_mst_topology_ref_port drm_dp_mst_topology_get_mstb > > > + drm_dp_mst_topology_put_mstb drm_dp_mst_topology_ref_mstb > > > + > > > +Malloc refcount overview > > > +~~~~~~~~~~~~~~~~~~~~~~~~ > > > + > > > +Malloc references are used to keep a :c:type:`struct drm_dp_mst_port` or > > > +:c:type:`struct drm_dp_mst_branch` allocated even...
2018 Dec 18
0
[WIP PATCH 03/15] drm/dp_mst: Introduce new refcounting scheme for mstbs and ports
...opology > > refcounts: > > + > > +.. kernel-doc:: drivers/gpu/drm/drm_dp_mst_topology.c > > + :functions: drm_dp_mst_topology_get_port drm_dp_mst_topology_put_port > > + drm_dp_mst_topology_ref_port drm_dp_mst_topology_get_mstb > > + drm_dp_mst_topology_put_mstb drm_dp_mst_topology_ref_mstb > > + > > +Malloc refcount overview > > +~~~~~~~~~~~~~~~~~~~~~~~~ > > + > > +Malloc references are used to keep a :c:type:`struct drm_dp_mst_port` or > > +:c:type:`struct drm_dp_mst_branch` allocated even after all of its > > to...
2019 Sep 03
0
[PATCH v2 12/27] drm/dp_mst: Refactor drm_dp_mst_handle_up_req()
...going over 80 character long lines * De-duplicate code for calling drm_dp_send_up_ack_reply() and getting the MSTB via it's GUID * Remove all of the duplicate calls to memset() and just use a goto instead * Actually do line wrapping * Remove the unnecessary if (mstb) check before calling drm_dp_mst_topology_put_mstb() - we are guaranteed to always have mstb != NULL at that point in the function Cc: Juston Li <juston.li at intel.com> Cc: Imre Deak <imre.deak at intel.com> Cc: Ville Syrjälä <ville.syrjala at linux.intel.com> Cc: Harry Wentland <hwentlan at amd.com> Reviewed-by: Daniel...
2019 Sep 25
2
[PATCH v2 16/27] drm/dp_mst: Refactor pdt setup/teardown, add more locking
...rtions(+), 77 deletions(-) > > diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c > index d1610434a0cb..9944ef2ce885 100644 > --- a/drivers/gpu/drm/drm_dp_mst_topology.c > +++ b/drivers/gpu/drm/drm_dp_mst_topology.c > @@ -1487,24 +1487,6 @@ drm_dp_mst_topology_put_mstb(struct drm_dp_mst_branch *mstb) > kref_put(&mstb->topology_kref, drm_dp_destroy_mst_branch_device); > } > > -static void drm_dp_port_teardown_pdt(struct drm_dp_mst_port *port, int old_pdt) > -{ > - struct drm_dp_mst_branch *mstb; > - > - switch (old_pdt) { > -...
2018 Dec 20
22
[PATCH v2 00/16] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2019 Oct 22
0
[PATCH v5 05/14] drm/dp_mst: Add probe_lock
...(!port->available_pbn) drm_dp_send_enum_path_resources(mgr, mstb, port); - if (port->mstb) { + if (port->mstb) mstb_child = drm_dp_mst_topology_get_mstb_validated( mgr, port->mstb); - if (mstb_child) { - drm_dp_check_and_send_link_address(mgr, mstb_child); - drm_dp_mst_topology_put_mstb(mstb_child); - } + + if (mstb_child) { + drm_dp_check_and_send_link_address(mgr, mstb_child); + drm_dp_mst_topology_put_mstb(mstb_child); } } } static void drm_dp_mst_link_probe_work(struct work_struct *work) { - struct drm_dp_mst_topology_mgr *mgr = container_of(work, struct drm_d...
2019 Oct 22
0
[PATCH v5 03/14] drm/dp_mst: Refactor pdt setup/teardown, add more locking
...+- 2 files changed, 110 insertions(+), 77 deletions(-) diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c index 204d0c832c65..3f16c0cb094b 100644 --- a/drivers/gpu/drm/drm_dp_mst_topology.c +++ b/drivers/gpu/drm/drm_dp_mst_topology.c @@ -1486,24 +1486,6 @@ drm_dp_mst_topology_put_mstb(struct drm_dp_mst_branch *mstb) kref_put(&mstb->topology_kref, drm_dp_destroy_mst_branch_device); } -static void drm_dp_port_teardown_pdt(struct drm_dp_mst_port *port, int old_pdt) -{ - struct drm_dp_mst_branch *mstb; - - switch (old_pdt) { - case DP_PEER_DEVICE_DP_LEGACY_CONV: - case D...
2019 Sep 03
0
[PATCH v2 16/27] drm/dp_mst: Refactor pdt setup/teardown, add more locking
...+- 2 files changed, 110 insertions(+), 77 deletions(-) diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c index d1610434a0cb..9944ef2ce885 100644 --- a/drivers/gpu/drm/drm_dp_mst_topology.c +++ b/drivers/gpu/drm/drm_dp_mst_topology.c @@ -1487,24 +1487,6 @@ drm_dp_mst_topology_put_mstb(struct drm_dp_mst_branch *mstb) kref_put(&mstb->topology_kref, drm_dp_destroy_mst_branch_device); } -static void drm_dp_port_teardown_pdt(struct drm_dp_mst_port *port, int old_pdt) -{ - struct drm_dp_mst_branch *mstb; - - switch (old_pdt) { - case DP_PEER_DEVICE_DP_LEGACY_CONV: - case D...
2018 Dec 14
22
[WIP PATCH 00/15] MST refcounting/atomic helpers cleanup
This is a WIP version of the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream
2019 Sep 25
0
[PATCH v2 16/27] drm/dp_mst: Refactor pdt setup/teardown, add more locking
...t; > diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c > > b/drivers/gpu/drm/drm_dp_mst_topology.c > > index d1610434a0cb..9944ef2ce885 100644 > > --- a/drivers/gpu/drm/drm_dp_mst_topology.c > > +++ b/drivers/gpu/drm/drm_dp_mst_topology.c > > @@ -1487,24 +1487,6 @@ drm_dp_mst_topology_put_mstb(struct > > drm_dp_mst_branch *mstb) > > kref_put(&mstb->topology_kref, drm_dp_destroy_mst_branch_device); > > } > > > > -static void drm_dp_port_teardown_pdt(struct drm_dp_mst_port *port, int > > old_pdt) > > -{ > > - struct drm_dp_mst_bra...
2019 Sep 03
0
[PATCH v2 10/27] drm/dp_mst: Remove huge conditional in drm_dp_mst_handle_up_req()
...rce_stat.port_number, msg.u.resource_stat.available_pbn); + if (!mstb) { + DRM_DEBUG_KMS("Got MST reply from unknown device %d\n", mgr->up_req_recv.initial_hdr.lct); + memset(&mgr->up_req_recv, 0, sizeof(struct drm_dp_sideband_msg_rx)); + return 0; } - if (mstb) - drm_dp_mst_topology_put_mstb(mstb); - - memset(&mgr->up_req_recv, 0, sizeof(struct drm_dp_sideband_msg_rx)); + DRM_DEBUG_KMS("Got RSN: pn: %d avail_pbn %d\n", msg.u.resource_stat.port_number, msg.u.resource_stat.available_pbn); } - return ret; + + if (mstb) + drm_dp_mst_topology_put_mstb(mstb); + + memset...
2019 Jan 03
16
[PATCH v3 00/16] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2019 Jan 11
20
[PATCH v7 00/20] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2019 Jan 05
19
[PATCH v4 00/16] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2019 Jan 10
21
[PATCH v6 00/20] MST refcounting/atomic helpers cleanup
This is the series I've been working on for a while now to get all of the atomic DRM drivers in the tree to use the atomic MST helpers, and to make the atomic MST helpers actually idempotent. Turns out it's a lot more difficult to do that without also fixing how port and branch device refcounting works so that it actually makes sense, since the current upstream implementation requires a
2019 Sep 25
1
[PATCH v2 20/27] drm/dp_mst: Protect drm_dp_mst_port members with connection_mutex
...nd_enum_path_resources(mgr, mstb, port); > > - if (port->mstb) { > + if (port->mstb) > mstb_child = drm_dp_mst_topology_get_mstb_validated( > mgr, port->mstb); > - if (mstb_child) { > - drm_dp_check_and_send_link_address(mgr, mstb_child); > - drm_dp_mst_topology_put_mstb(mstb_child); > - } > + > + drm_modeset_unlock(&dev->mode_config.connection_mutex); > + > + if (mstb_child) { > + drm_dp_check_and_send_link_address(mgr, mstb_child); > + drm_dp_mst_topology_put_mstb(mstb_child); > } > } > } > diff --git a/includ...