linux-next: manual merge of the drm-msm-lumag tree with Linus' tree

From: Stephen Rothwell
Date: Sun Jun 26 2022 - 20:33:58 EST


Hi all,

Today's linux-next merge of the drm-msm-lumag tree got a conflict in:

drivers/gpu/drm/msm/msm_fence.c

between commit:

3c7a52217a8c ("drm/msm: Drop update_fences()")

from Linus' tree and commit:

bda2eac959ae ("drm/msm: Fix fence rollover issue")

from the drm-msm-lumag tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging. You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

--
Cheers,
Stephen Rothwell

diff --cc drivers/gpu/drm/msm/msm_fence.c
index 38e3323bc232,a35a6746c7cd..000000000000
--- a/drivers/gpu/drm/msm/msm_fence.c
+++ b/drivers/gpu/drm/msm/msm_fence.c
@@@ -46,14 -54,13 +54,15 @@@ bool msm_fence_completed(struct msm_fen
(int32_t)(*fctx->fenceptr - fence) >= 0;
}

- /* called from irq handler and workqueue (in recover path) */
+ /* called from irq handler */
void msm_update_fence(struct msm_fence_context *fctx, uint32_t fence)
{
- spin_lock(&fctx->spinlock);
+ unsigned long flags;
+
+ spin_lock_irqsave(&fctx->spinlock, flags);
- fctx->completed_fence = max(fence, fctx->completed_fence);
+ if (fence_after(fence, fctx->completed_fence))
+ fctx->completed_fence = fence;
- spin_unlock(&fctx->spinlock);
+ spin_unlock_irqrestore(&fctx->spinlock, flags);
}

struct msm_fence {

Attachment: pgpgPZvz4Va_5.pgp
Description: OpenPGP digital signature