soc/google/cpif: Don't pin workers onto CPU2

There's no reason to pin workers onto CPU2. Instead, allow the workers to
run where the workqueue sees fit, most likely on the CPU which enqueues the
worker, which is better than always dumping the workers onto CPU2.

Signed-off-by: Sultan Alsawaf <sultan@kerneltoast.com>
This commit is contained in:
Sultan Alsawaf 2024-12-02 22:38:28 -08:00 committed by Ksawlii
parent e117973ff8
commit 7a02051d8c
2 changed files with 5 additions and 11 deletions

View file

@ -50,8 +50,6 @@ static int s5100_lcd_notifier(struct notifier_block *notifier,
#define msecs_to_loops(t) (loops_per_jiffy / 1000 * HZ * t)
#define RUNTIME_PM_AFFINITY_CORE 2
static struct modem_ctl *g_mc;
static int s5100_poweroff_pcie(struct modem_ctl *mc, bool force_off);
@ -213,8 +211,7 @@ static irqreturn_t ap_wakeup_handler(int irq, void *data)
(gpio_val == 1 ? IRQF_TRIGGER_LOW : IRQF_TRIGGER_HIGH));
mif_enable_irq(&mc->cp_gpio_irq[CP_GPIO_IRQ_CP2AP_WAKEUP]);
queue_work_on(RUNTIME_PM_AFFINITY_CORE, mc->wakeup_wq,
(gpio_val == 1 ? &mc->wakeup_work : &mc->suspend_work));
queue_work(mc->wakeup_wq, gpio_val == 1 ? &mc->wakeup_work : &mc->suspend_work);
return IRQ_HANDLED;
}
@ -1482,8 +1479,7 @@ static int s5100_pm_notifier(struct notifier_block *notifier,
(gpio_val == 1 ? IRQF_TRIGGER_LOW : IRQF_TRIGGER_HIGH));
mif_enable_irq(&mc->cp_gpio_irq[CP_GPIO_IRQ_CP2AP_WAKEUP]);
queue_work_on(RUNTIME_PM_AFFINITY_CORE, mc->wakeup_wq,
(gpio_val == 1 ? &mc->wakeup_work : &mc->suspend_work));
queue_work(mc->wakeup_wq, gpio_val == 1 ? &mc->wakeup_work : &mc->suspend_work);
}
spin_unlock_irqrestore(&mc->pcie_pm_lock, flags);
break;
@ -1629,13 +1625,11 @@ static int s5100_abox_call_state_notifier(struct notifier_block *nb,
switch (action) {
case ABOX_CALL_EVENT_OFF:
mc->pcie_voice_call_on = false;
queue_work_on(RUNTIME_PM_AFFINITY_CORE, mc->wakeup_wq,
&mc->call_off_work);
queue_work(mc->wakeup_wq, &mc->call_off_work);
break;
case ABOX_CALL_EVENT_ON:
mc->pcie_voice_call_on = true;
queue_work_on(RUNTIME_PM_AFFINITY_CORE, mc->wakeup_wq,
&mc->call_on_work);
queue_work(mc->wakeup_wq, &mc->call_on_work);
break;
default:
mif_err("undefined call event = %lu\n", action);

View file

@ -373,7 +373,7 @@ static void s51xx_pcie_cpl_timeout_cb(struct exynos_pcie_notify *noti)
if (mc->pcie_cto_retry_cnt++ < 10) {
pr_err("[%s][%d] retry pcie poweron !!!\n", __func__,
mc->pcie_cto_retry_cnt);
queue_work_on(2, mc->wakeup_wq, &mc->wakeup_work);
queue_work(mc->wakeup_wq, &mc->wakeup_work);
} else {
pr_err("[%s][%d] force crash !!!\n", __func__,
mc->pcie_cto_retry_cnt);