Skip to content

Commit 5f2ac9b

Browse files
jannaumarcan
authored andcommitted
drm : apple: iomfb: Handle OOB ASYNC/CB context
Only observed with dcp/dptx in linux after initialisation and reset in m1n1. On the initial startup dcp sends two D576 (hotPlug_notify_gated) presumendly due to state confusion due to the multiple dptx connections. Signed-off-by: Janne Grunau <[email protected]>
1 parent e19e19a commit 5f2ac9b

3 files changed

Lines changed: 8 additions & 1 deletion

File tree

drivers/gpu/drm/apple/dcp-internal.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ struct apple_dcp {
154154
struct dcp_mem_descriptor memdesc[DCP_MAX_MAPPINGS];
155155

156156
struct dcp_channel ch_cmd, ch_oobcmd;
157-
struct dcp_channel ch_cb, ch_oobcb, ch_async;
157+
struct dcp_channel ch_cb, ch_oobcb, ch_async, ch_oobasync;
158158

159159
/* iomfb EP callback handlers */
160160
const iomfb_cb_handler *cb_handlers;

drivers/gpu/drm/apple/iomfb.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ static int dcp_channel_offset(enum dcp_context_id id)
4848
switch (id) {
4949
case DCP_CONTEXT_ASYNC:
5050
return 0x40000;
51+
case DCP_CONTEXT_OOBASYNC:
52+
return 0x48000;
5153
case DCP_CONTEXT_CB:
5254
return 0x60000;
5355
case DCP_CONTEXT_OOBCB:
@@ -117,6 +119,8 @@ static struct dcp_channel *dcp_get_channel(struct apple_dcp *dcp,
117119
return &dcp->ch_oobcmd;
118120
case DCP_CONTEXT_ASYNC:
119121
return &dcp->ch_async;
122+
case DCP_CONTEXT_OOBASYNC:
123+
return &dcp->ch_oobasync;
120124
default:
121125
return NULL;
122126
}

drivers/gpu/drm/apple/iomfb.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@ enum dcp_context_id {
2828
/* Out-of-band command */
2929
DCP_CONTEXT_OOBCMD = 6,
3030

31+
/* Out-of-band Asynchronous */
32+
DCP_CONTEXT_OOBASYNC = 7,
33+
3134
DCP_NUM_CONTEXTS
3235
};
3336

0 commit comments

Comments
 (0)