/[packages]/cauldron/kernel/current/PATCHES/patches/0083-thermal-da9062-61-Prevent-hardware-access-during-sys.patch
ViewVC logotype

Annotation of /cauldron/kernel/current/PATCHES/patches/0083-thermal-da9062-61-Prevent-hardware-access-during-sys.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1329221 - (hide annotations) (download)
Fri Nov 9 22:05:45 2018 UTC (5 years, 11 months ago) by tmb
File size: 1794 byte(s)
add fixes from sashas autosel queue
1 tmb 1329221 From c9755d22f2c93a353bc647056111900525d57801 Mon Sep 17 00:00:00 2001
2     From: Geert Uytterhoeven <geert+renesas@glider.be>
3     Date: Fri, 12 Oct 2018 09:20:17 +0200
4     Subject: [PATCH 083/145] thermal: da9062/61: Prevent hardware access during
5     system suspend
6    
7     [ Upstream commit 760eea43f8c6d48684f1f34b8a02fddc1456e849 ]
8    
9     The workqueue used for monitoring the hardware may run while the device
10     is already suspended. Fix this by using the freezable system workqueue
11     instead, cfr. commit 51e20d0e3a60cf46 ("thermal: Prevent polling from
12     happening during system suspend").
13    
14     Fixes: 608567aac3206ae8 ("thermal: da9062/61: Thermal junction temperature monitoring driver")
15     Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
16     Acked-by: Steve Twiss <stwiss.opensource@diasemi.com>
17     Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
18     Signed-off-by: Sasha Levin <sashal@kernel.org>
19     ---
20     drivers/thermal/da9062-thermal.c | 4 ++--
21     1 file changed, 2 insertions(+), 2 deletions(-)
22    
23     diff --git a/drivers/thermal/da9062-thermal.c b/drivers/thermal/da9062-thermal.c
24     index dd8dd947b7f0..01b0cb994457 100644
25     --- a/drivers/thermal/da9062-thermal.c
26     +++ b/drivers/thermal/da9062-thermal.c
27     @@ -106,7 +106,7 @@ static void da9062_thermal_poll_on(struct work_struct *work)
28     THERMAL_EVENT_UNSPECIFIED);
29    
30     delay = msecs_to_jiffies(thermal->zone->passive_delay);
31     - schedule_delayed_work(&thermal->work, delay);
32     + queue_delayed_work(system_freezable_wq, &thermal->work, delay);
33     return;
34     }
35    
36     @@ -125,7 +125,7 @@ static irqreturn_t da9062_thermal_irq_handler(int irq, void *data)
37     struct da9062_thermal *thermal = data;
38    
39     disable_irq_nosync(thermal->irq);
40     - schedule_delayed_work(&thermal->work, 0);
41     + queue_delayed_work(system_freezable_wq, &thermal->work, 0);
42    
43     return IRQ_HANDLED;
44     }
45     --
46     2.19.1
47    

  ViewVC Help
Powered by ViewVC 1.1.30