[PATCH v3 1/2] drm/bridge: Add Cadence DSI driver
Eric Anholt
eric at anholt.net
Fri Sep 1 18:32:32 UTC 2017
Boris Brezillon <boris.brezillon at free-electrons.com> writes:
> Hi Eric,
>
> On Thu, 31 Aug 2017 10:03:23 -0700
> Eric Anholt <eric at anholt.net> wrote:
>
>> Boris Brezillon <boris.brezillon at free-electrons.com> writes:
>> > + VID_DATATYPE(MIPI_DSI_PACKED_PIXEL_STREAM_16);
>> > + break;
>> > +
>> > + default:
>> > + dev_err(dsi->base.dev, "Unsupported DSI format\n");
>> > + return;
>> > + }
>>
>> > +static irqreturn_t cdns_dsi_interrupt(int irq, void *data)
>> > +{
>> > + struct cdns_dsi *dsi = data;
>> > + irqreturn_t ret = IRQ_NONE;
>> > + u32 flag, ctl;
>> > +
>> > + flag = readl(dsi->regs + DIRECT_CMD_STS_FLAG);
>> > + if (flag) {
>> > + ctl = readl(dsi->regs + DIRECT_CMD_STS_CTL);
>> > + ctl &= ~flag;
>> > + writel(ctl, dsi->regs + DIRECT_CMD_STS_CTL);
>>
>> Are you meant to just write flag to DIRECT_CMD_STS_CLEAR, maybe?
>
> Actually, I want to keep the status flag untouched, I'm just masking the
> interrupt to not be interrupted until the waiter has cleared the
> status flags.
>
> I'm doing that because the user may want to wait for several different
> events (error, done, timeout, ...), and I'm not doing the check in the
> interrupt handler. Instead, I'm just waking up the waiter and let him
> check the status flag himself.
Oh, OK. That sounds good.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20170901/1bede0c6/attachment.sig>
More information about the dri-devel
mailing list