Subversion Repositories Kolibri OS

Rev

Rev 6937 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6937 Rev 7144
Line 1060... Line 1060...
1060
					mstb->guid);
1060
					mstb->guid);
1061
		} else {
1061
		} else {
Line 1062... Line 1062...
1062
 
1062
 
1063
			ret = drm_dp_dpcd_write(
1063
			ret = drm_dp_dpcd_write(
1064
					mstb->mgr->aux,
1064
					mstb->mgr->aux,
1065
						     DP_GUID,
1065
					DP_GUID,
1066
					mstb->guid,
1066
					mstb->guid,
1067
					16);
1067
					16);
1068
		}
1068
		}
1069
	}
1069
	}
Line 1418... Line 1418...
1418
	req_type = txmsg->msg[0] & 0x7f;
1418
	req_type = txmsg->msg[0] & 0x7f;
1419
	if (req_type == DP_CONNECTION_STATUS_NOTIFY ||
1419
	if (req_type == DP_CONNECTION_STATUS_NOTIFY ||
1420
		req_type == DP_RESOURCE_STATUS_NOTIFY)
1420
		req_type == DP_RESOURCE_STATUS_NOTIFY)
1421
		hdr->broadcast = 1;
1421
		hdr->broadcast = 1;
1422
	else
1422
	else
1423
	hdr->broadcast = 0;
1423
		hdr->broadcast = 0;
1424
	hdr->path_msg = txmsg->path_msg;
1424
	hdr->path_msg = txmsg->path_msg;
1425
	hdr->lct = mstb->lct;
1425
	hdr->lct = mstb->lct;
1426
	hdr->lcr = mstb->lct - 1;
1426
	hdr->lcr = mstb->lct - 1;
1427
	if (mstb->lct > 1)
1427
	if (mstb->lct > 1)
1428
		memcpy(hdr->rad, mstb->rad, mstb->lct / 2);
1428
		memcpy(hdr->rad, mstb->rad, mstb->lct / 2);
Line 1684... Line 1684...
1684
	if (!mstb) {
1684
	if (!mstb) {
1685
		mstb = drm_dp_get_last_connected_port_and_mstb(mgr, port->parent, &port_num);
1685
		mstb = drm_dp_get_last_connected_port_and_mstb(mgr, port->parent, &port_num);
Line 1686... Line 1686...
1686
 
1686
 
1687
		if (!mstb) {
1687
		if (!mstb) {
1688
			drm_dp_put_port(port);
1688
			drm_dp_put_port(port);
1689
		return -EINVAL;
1689
			return -EINVAL;
1690
	}
1690
		}
Line 1691... Line 1691...
1691
	}
1691
	}
1692
 
1692
 
1693
	txmsg = kzalloc(sizeof(*txmsg), GFP_KERNEL);
1693
	txmsg = kzalloc(sizeof(*txmsg), GFP_KERNEL);
Line 2064... Line 2064...
2064
		/* give this the main reference */
2064
		/* give this the main reference */
2065
		mgr->mst_primary = mstb;
2065
		mgr->mst_primary = mstb;
2066
		kref_get(&mgr->mst_primary->kref);
2066
		kref_get(&mgr->mst_primary->kref);
Line 2067... Line 2067...
2067
 
2067
 
2068
		ret = drm_dp_dpcd_writeb(mgr->aux, DP_MSTM_CTRL,
2068
		ret = drm_dp_dpcd_writeb(mgr->aux, DP_MSTM_CTRL,
2069
					 DP_MST_EN | DP_UP_REQ_EN | DP_UPSTREAM_IS_SRC);
2069
							 DP_MST_EN | DP_UP_REQ_EN | DP_UPSTREAM_IS_SRC);
2070
		if (ret < 0) {
2070
		if (ret < 0) {
2071
			goto out_unlock;
2071
			goto out_unlock;
Line 2072... Line 2072...
2072
		}
2072
		}
Line 2281... Line 2281...
2281
		struct drm_dp_sideband_msg_req_body msg;
2281
		struct drm_dp_sideband_msg_req_body msg;
2282
		struct drm_dp_mst_branch *mstb = NULL;
2282
		struct drm_dp_mst_branch *mstb = NULL;
2283
		bool seqno;
2283
		bool seqno;
Line 2284... Line 2284...
2284
 
2284
 
2285
		if (!mgr->up_req_recv.initial_hdr.broadcast) {
2285
		if (!mgr->up_req_recv.initial_hdr.broadcast) {
2286
		mstb = drm_dp_get_mst_branch_device(mgr,
2286
			mstb = drm_dp_get_mst_branch_device(mgr,
2287
						    mgr->up_req_recv.initial_hdr.lct,
2287
							    mgr->up_req_recv.initial_hdr.lct,
2288
						    mgr->up_req_recv.initial_hdr.rad);
2288
							    mgr->up_req_recv.initial_hdr.rad);
2289
		if (!mstb) {
2289
			if (!mstb) {
2290
			DRM_DEBUG_KMS("Got MST reply from unknown device %d\n", mgr->up_req_recv.initial_hdr.lct);
2290
				DRM_DEBUG_KMS("Got MST reply from unknown device %d\n", mgr->up_req_recv.initial_hdr.lct);
2291
			memset(&mgr->up_req_recv, 0, sizeof(struct drm_dp_sideband_msg_rx));
2291
				memset(&mgr->up_req_recv, 0, sizeof(struct drm_dp_sideband_msg_rx));
2292
			return 0;
2292
				return 0;
2293
		}
2293
			}
Line 2294... Line 2294...
2294
		}
2294
		}
2295
 
2295