Commit 2f6ca957 authored by David S. Miller's avatar David S. Miller

Merge branch 'net-ipa-sc7180-suspend-resume'

Alex Elder says:

====================
net: ipa: sc7180 suspend/resume

This series permits suspend/resume to work for the IPA driver
on the Qualcomm SC7180 SoC.  The IPA version on this SoC requires
interrupts to be enabled when the suspend and resume callbacks are
made, and the first patch moves away from using the noirq variants.
The second patch fixes a problem with resume that occurs because
pending interrupts were being cleared before starting a channel.
====================
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents d53b1162 195ef57f
......@@ -238,11 +238,6 @@ static void gsi_irq_ieob_enable(struct gsi *gsi, u32 evt_ring_id)
iowrite32(val, gsi->virt + GSI_CNTXT_SRC_IEOB_IRQ_MSK_OFFSET);
}
static void gsi_isr_ieob_clear(struct gsi *gsi, u32 mask)
{
iowrite32(mask, gsi->virt + GSI_CNTXT_SRC_IEOB_IRQ_CLR_OFFSET);
}
static void gsi_irq_ieob_disable(struct gsi *gsi, u32 evt_ring_id)
{
u32 val;
......@@ -777,7 +772,6 @@ static void gsi_channel_deprogram(struct gsi_channel *channel)
int gsi_channel_start(struct gsi *gsi, u32 channel_id)
{
struct gsi_channel *channel = &gsi->channel[channel_id];
u32 evt_ring_id = channel->evt_ring_id;
int ret;
mutex_lock(&gsi->mutex);
......@@ -786,9 +780,6 @@ int gsi_channel_start(struct gsi *gsi, u32 channel_id)
mutex_unlock(&gsi->mutex);
/* Clear the channel's event ring interrupt in case it's pending */
gsi_isr_ieob_clear(gsi, BIT(evt_ring_id));
gsi_channel_thaw(channel);
return ret;
......@@ -1093,7 +1084,7 @@ static void gsi_isr_ieob(struct gsi *gsi)
u32 event_mask;
event_mask = ioread32(gsi->virt + GSI_CNTXT_SRC_IEOB_IRQ_OFFSET);
gsi_isr_ieob_clear(gsi, event_mask);
iowrite32(event_mask, gsi->virt + GSI_CNTXT_SRC_IEOB_IRQ_CLR_OFFSET);
while (event_mask) {
u32 evt_ring_id = __ffs(event_mask);
......
......@@ -933,8 +933,8 @@ static int ipa_resume(struct device *dev)
}
static const struct dev_pm_ops ipa_pm_ops = {
.suspend_noirq = ipa_suspend,
.resume_noirq = ipa_resume,
.suspend = ipa_suspend,
.resume = ipa_resume,
};
static struct platform_driver ipa_driver = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment