linux/kernel/watchdog.c
<<
>>
Prefs
   1/*
   2 * Detect hard and soft lockups on a system
   3 *
   4 * started by Don Zickus, Copyright (C) 2010 Red Hat, Inc.
   5 *
   6 * Note: Most of this code is borrowed heavily from the original softlockup
   7 * detector, so thanks to Ingo for the initial implementation.
   8 * Some chunks also taken from the old x86-specific nmi watchdog code, thanks
   9 * to those contributors as well.
  10 */
  11
  12#define pr_fmt(fmt) "NMI watchdog: " fmt
  13
  14#include <linux/mm.h>
  15#include <linux/cpu.h>
  16#include <linux/nmi.h>
  17#include <linux/init.h>
  18#include <linux/delay.h>
  19#include <linux/freezer.h>
  20#include <linux/kthread.h>
  21#include <linux/lockdep.h>
  22#include <linux/notifier.h>
  23#include <linux/module.h>
  24#include <linux/sysctl.h>
  25
  26#include <asm/irq_regs.h>
  27#include <linux/kvm_para.h>
  28#include <linux/perf_event.h>
  29
  30int watchdog_enabled = 1;
  31int __read_mostly watchdog_thresh = 10;
  32
  33static DEFINE_PER_CPU(unsigned long, watchdog_touch_ts);
  34static DEFINE_PER_CPU(struct task_struct *, softlockup_watchdog);
  35static DEFINE_PER_CPU(struct hrtimer, watchdog_hrtimer);
  36static DEFINE_PER_CPU(bool, softlockup_touch_sync);
  37static DEFINE_PER_CPU(bool, soft_watchdog_warn);
  38#ifdef CONFIG_HARDLOCKUP_DETECTOR
  39static DEFINE_PER_CPU(bool, hard_watchdog_warn);
  40static DEFINE_PER_CPU(bool, watchdog_nmi_touch);
  41static DEFINE_PER_CPU(unsigned long, hrtimer_interrupts);
  42static DEFINE_PER_CPU(unsigned long, hrtimer_interrupts_saved);
  43static DEFINE_PER_CPU(struct perf_event *, watchdog_ev);
  44#endif
  45
  46/* boot commands */
  47/*
  48 * Should we panic when a soft-lockup or hard-lockup occurs:
  49 */
  50#ifdef CONFIG_HARDLOCKUP_DETECTOR
  51static int hardlockup_panic =
  52                        CONFIG_BOOTPARAM_HARDLOCKUP_PANIC_VALUE;
  53
  54static int __init hardlockup_panic_setup(char *str)
  55{
  56        if (!strncmp(str, "panic", 5))
  57                hardlockup_panic = 1;
  58        else if (!strncmp(str, "nopanic", 7))
  59                hardlockup_panic = 0;
  60        else if (!strncmp(str, "0", 1))
  61                watchdog_enabled = 0;
  62        return 1;
  63}
  64__setup("nmi_watchdog=", hardlockup_panic_setup);
  65#endif
  66
  67unsigned int __read_mostly softlockup_panic =
  68                        CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE;
  69
  70static int __init softlockup_panic_setup(char *str)
  71{
  72        softlockup_panic = simple_strtoul(str, NULL, 0);
  73
  74        return 1;
  75}
  76__setup("softlockup_panic=", softlockup_panic_setup);
  77
  78static int __init nowatchdog_setup(char *str)
  79{
  80        watchdog_enabled = 0;
  81        return 1;
  82}
  83__setup("nowatchdog", nowatchdog_setup);
  84
  85/* deprecated */
  86static int __init nosoftlockup_setup(char *str)
  87{
  88        watchdog_enabled = 0;
  89        return 1;
  90}
  91__setup("nosoftlockup", nosoftlockup_setup);
  92/*  */
  93
  94/*
  95 * Hard-lockup warnings should be triggered after just a few seconds. Soft-
  96 * jax_lookcan hatri5L86" class="linestrn4ri5L8l/watchdog.c#L90" id="L90" class="s undrneextremwatchdi"L8" id="urs:|inclalsrefclass="line" name="L96">  96
<"ker/watchdog.c#L="L9<"kerf="kehdog.c#id="urs:cou">sefclass="line" name="L96">  96
  96 * to those contchdo9tors as well.
  10 */
  50#i10 href="ke0rnel/watchdog.c#L12" id=01"L9 h" class="sref">hardlockup_panicget_chdog.c#L37"h href="kernel/watchget_chdog.c#L37"h hreot;  87{
10fine   88  10 href="ke0rnel/watchdog.c#L14" id=03"L9 h3c#L90" id="L90" claatchdog_enabled = 0;  19#in0clude <0;  91  46
  50#i10clude <0;  50#i10clude <0;
  50#i10clude <0;
  10 */
  11
stget_kimess=" ot;hardlockup_panic sof_cpuclass="sref">st sof_cpuclass="line" name="L87">  87{
1efine   88  1a href="keernel/watchdog.c#L14" id=="L14113c#L90" id="L90" claatchdog_enabledcpu_cg.c#class="sref">stcpu_cg.c#st sof_cpuclass ch">
	   30LL;  rnel/watchdog.c#L93" id="2^30 ~clas^9L11" class="line" name="L11">  11
  91  46DEFINE_PER_CPUuode=__setupef">stutupstperioef="kernel/watchget_caf">stperioeot;  87{
1nclude <t;  88  1nclude <t;wa
  50#i1nclude <t;   9   9   9
s)/t"uincr8" idspa"keek/spclass="line" name="L9">   9   9  11
stutup  92  91  78st1nclude &l1t;  78  11
DEFvoid   87{
1t   88  1t hardlockup_panic sof_cpuclass="sref">st sof_cpuclassimple_strtoul(mp_proc"ssor_ief="kernel/watch(mp_proc"ssor_ieot;  92  33st1atic nosoftlockup_sget_kimess=" class="sref">stget_kimess=" ot;st sof_cpuclass)s="line" name="L92">  92  91  46);
  87{
1tclude &l1ref="+code=DEFINE_PER_CP1U" cl13 class="line" name="L88">  88  1fdef watchdog_enabledno"sof_cpu_writef="kernel/watchno"sof_cpu_write  73
<1atic   91  73
<1atic   12#deatic );
);
  87{
1atic   88  1ndif
hardlockup_paniccpuclass="sref">stcpuclass="line" name="L73">  73
<1atic   46/* boot comma1nds *14="sref">strnca
  50#i1pan class1="comment">/*
  50#i1pdef  * Should we 1panic1when a soft-lockup or hard-loffffffff*ad"urs:carncmp  50#i1ptic  */
  50#i1fdef   11
watchdog_enabled"ke_ead="onode=_cpuclass="sref">st"ke_ead="onode=_cpuot;stcpuclass="line" name="L87">  87{
1         1             stper_cpunosoftlockup_scpuclass="sref">stcpuclassclass="line" name="L89">  89  1a href="k1ernel/watchdog.c#L54" id1="L5415 class="line" name="L64">  64  85CONFIG_HARDLOCKUP_DETECTOR
  51st1      if 1(!  87{
1         1       88  1      els1e if (!mp = 0;
  88  1 tic hs_saved" ardlockup_paniccpuclass="sref">stcpuclass="line" name="L73">  73
<1      els1e if (!  73
<1 tic int 1     watchdog_enabled"ke_ead="p hrent_cpuclass="sref">st"ke_ead="p hrent_cpuot;stcpuclass s="line" name="L88">  88  1      ret1urn 1;
stper_cpunosoftlockup_scpuclass="sref">stcpuclassc!imple_strtoultruef="kernel/watchtrueclass="line" name="L87">  87{
1stper_cpunosoftlockup_scpuclass="sref">stcpuclasscimple_strtoultruef="kernel/watchtrueclass="line" name="L73">  73
<1 tic int 1ode=__setup" class="sref1">__s164IG_BOOTPARAM_HARDLOCs="line" name="L64">  64  64strncaa href="+code=" id="Lchdog);
  73
<1signed in1t   64  73
<1stic   70st1atic int 1 class="line" name="L66">  66
<1  12#de      );
  87{
1a href="k1ernel/watchdog.c#L74" id1="L7417s="srs="line" name="L88">  88  1      ret1urn 1;
);
truef="kernel/watchtrueclass="line" name="L73">  73
<1  89  1 href="+c1ode=__setup" class="sref1">__s17lpha/s="line" name="L91">  91  78st1atic int 1CONFIG_HARDLOCKUP_DETECTOR
  39st1  78  47__init   87{
1      ret1urn 1;
  72  1no"sof_cpu_" clf="kernel/watchno"sof_cpu_" clot;);
  42st1 href="+c1ode=__setup" class="sref1">__s18class="line" name="L14">  14#ina href="k1ernel/watchdog.c#L85" id1="L85184c#L82" id="Lfp);
);
  87{
1 a href="1="comment">/* deprecated1 */  90}
1atic int 1  67un1);
);
hrtimer_inide=watchdog_ev" chrideclasss="line" name="L90">  90}
1aclude <;w90" class="line" name="L89">  89  1      ret1urn 1;
  91 class="line" name="L66">  66
<1 href="+c1ode=__setup" class="sref1">__s19class="line" name="L12">  12#depan class1="comment">/*  */1
__init   12#dephref="+c1ernel/watchdog.c#L94" id1="L9419s="srs="line" name="L88">  88  1pan class1="comment">/*
stget_kimess=" ot;  90}
1pan class1="comment"> * Hard-locku1p war19class="line" name="L46">  46 * jax_lookca1n hat19="sref">strnca
  47hrtimer_" id="ef="kernel/watchdid="L34" cla +aatchdog_enabledget_chdog.c#L37"h href="kernel/watchget_chdog.c#L37"h hreot;  61  1p     hrtimer_" id="ef="kernel/watchdid="L34" clas="line" name="L90">  90}
1pclude <;  70st2aan class2""comment"> */
w90" class="line" name="L89">  89  20 href="k20rnel/watchdog.c#L12" id201"L92h" clas="line" name="L91">  91  33st20 href="k20rnel/watchdog.c#L14" id203"L9203ECTOR" class="sref">CONFIG_HARDLOCKUP_DETECTOR
  39st20clude &l20;  85DEFperf_event *,   88  20clude &l20;strnc."sref">hrtimer_"ypef="kernel/watchtypeIG_BOOTPARAM_SOimple_strtoulPERF_TYPEog.c#WAREf="kernel/watchPERF_TYPEog.c#WAREclass="line" name="L88">  88  20clude <0;strnc."sref">hrtimer_confic"kernel/watchdoconficIG_BOOTPARAM_imple_strtoulPERF_COUNT_HWs="s_CYCLESf="kernel/watchPERF_COUNT_HWs="s_CYCLESclass="line" name="L88">  88  20clude <0;strnc."sref">hrtimer_sizef="kernel/watchsizeIG_BOOTPARAM_SOimsizeof>perf_event *,   88  20 href="ke0;strnc."sref">hrtimer_pinn
  88  2pan class2="comment"> */
strnc."sref">hrtimer_disa href="kernel/watchdisa hre"sref">strnim1s="line" name="L88">  88  2pclude <;  21#incfine   33st2a href="k2ernel/watchdog.c#L14" id2="L1421ernel/watchdog.c#L4" id="L4d="Callback:funalse;L"kerref= +code sub="L3" L47" class="line" name="L47">  47__init *, watcent *, was="line" name="L88">  88  2pclude &l2t;stdata=watchdog_ev" class=caf">stdata">watcent *, was="line" name="L88">  88  2pclude &l2t;watcent *, was="line" name="L61">  61  2nclude &l2t;  88  2nclude &l2t;wa
  78  86st2nclude &l2t;strncent *, wa-
	  "sref">hrtimer_iw="kernel/watchdhwclas."sref">hrtimer_);
  89  2nclude <t;  73
<2nclude <t;  88  2nclude <;nosoftlockup_s="L90class="sref">st""L90classs="line" name="L90">  90}
2nclude <t;  90}
2nclude &l2t;  91  26#innclude <t;strnca
  86st2nclude <t;  86st2nclude &l2t;  86st2nclude &l2ernel/watchdog.c#L30" id=="L3022kernel/watchdog.c#L50" id="Lffffffff*afiref=multi">shkimesspa"keekwekovef=low'd. aIf it hasn'totclass="line" name="L86">  86st2t __dic="L8"s/spacpu/p  86st2tclude <="+code=__read_mostly" c2lass=23ernel/watchdog.c#L2" id="L2Lffffffff*6" class="line" name="L86">  86st2a href="k2ernel/watchdog.c#L33" id2="L33232c#L82" id="Lfp  88  2atic hardlockup_panic sof_cpuclass="sref">st sof_cpuclassimple_strtoul(mp_proc"ssor_ief="kernel/watch(mp_proc"ssor_ieot;  92  85  86st2aclude <ref="+code=DEFINE_PER_CP2U" cl236c#L75" id="LLLLLLLLLfp);
  86st2aclude <ref="+code=DEFINE_PER_CP2U" cl23panic" class="sref">h_HARDLOC90" cls="line" name="L90">  90}
2fdef   90}
2fclude &l2ref="+code=DEFINE_PER_CP2U" cl23panic" class="sref">hfp = 0;
  86st2atic h_HARDLOCent *, , nosoftlockup_s sof_cpuclass="sref">st sof_cpuclasss="line" name="L90">  90}
2atic wstrn="line" name="L90">  90}
2a href="k2ref="+code=DEFINE_PER_CP2U" cl24FIG_BOOTPARAM_HARDLOCKUP_PANIC_VALUE" class=WARNclass="sref">stWARN60" /1)
nosoftlockup_s sof_cpuclass="sref">st sof_cpuclasss="line" name="L90">  90}
2atic   14#i2ndif
);
nosoftlockup_s ruef="kernel/watchtrueclasss="line" name="L90">  90}
2atic   90}
2aclude <="comment">/* boot comma2nds *24="sref">strncs="line" name="L91">  91/*
  78st2pdef  * Should we 2panic24lass="sref">watchdog_enabledno"sof_cpu_writef="kernel/watchno"sof_cpu_write);
nosoftlockup_s="L90class="sref">st""L90classs="line" name="L90">  90}
2ptic  */
  90}
2fdef   91  87{
2         2               88  2a href="k2ernel/watchdog.c#L54" id2="L54253c#L90" id="L);
  90}
2atic int 2  91  90}
2      if 2(!DEFINE_PER_CPUin+code=kernel/watchd" +codc#L90void   91  86st2      els2e if (!  90}
2 tic   78  47__inithrtimer_interrupreat, Ia href="kernel/watchdogreat, Iass="ef="+code=NULL"d.c#L34" ichdogff="kernel/watchdd.c#L34" ichdogffot; *, watcent *, was="line" name="L87">  87{
2 tic int 2       72  2      ret2urn 1;
no"sof_cpu_" clf="kernel/watchno"sof_cpu_" clot;  90}
2watcent *, wasimple_strtoulget_irq id="=watchdog_ev" cget_irq id="ot;  92__s264IG_BOOTPARAMf">hardlockup_panicdur="L8"=watchdog_ev" cdur="L8" clas="line" name="L90">  90}
2ndif
  26#innclude &l2;;strnca
  47  92  90}
2stic strnca
  47watchdog_enabled);
  92  12#d2      so
  47waf">nosoftlockup_ses id_ktchda href="kernel/es id_ktchdstperioef="kernel/watchget_caf">stperioeot;  92  85  88  2 href="+c2ode=__setup" class="sref2">__s276c#L75" id="LLLLLLLLLfp)/a>);
  88  2a href="k2ernel/watchdog.c#L78" id2="L7827panic" class="sref">h_HARDLOCa
  50#i2atic int 2  96  10  47w_HARDLOCatchdog_enabledno"sof_cpu_writef="kernel/watchno"sof_cpu_write)/a>);
nosoftlockup_s="L90class="sref">st""L90classs="line" name="L90">  90}
2  92__s283IG_BOOTPARAM_HARDLOCs="line" name="L91">  91  85/* deprecated2 */  78  47  92hatchdog_enabledno" id=";
  92  90}
2      ret2urn 1;
  91  73
<2 href="+c2ode=__setup" class="sref2">__s291ass="sref">wa
  47/*  */2
  47  78   9/*
   9 * Hard-locku2p war2ings should be triggered afteffffffff*a/sp__dic="L8"ssome tasmkis hoggds.k/spacpuclass="line" name="L9">   9 * jax_lookca2n hat2i5L86" class="linestrn4ri5L8lffffffff*7" class="line" name="L47">  47is_chdog.c#L3a href="kernel/is_" id="L7" cluptatchdog_enabledk id="ef="kernel/watchdid="L34" cla)s="line" name="L92">  92mp  88  2pclude &l2;;ha
  50#i3aan class3""comment"> */
   9  78   9/*  */302"L930f="kernel/watchdog.c#L93" iM_SOFTLOCffffffff*astoppef=/spavmspa"keekwekissuek/spa">onds.class="line" name="L9">   9  47  87{
30clude &l30;  90}
30clude &l30;  67un30clude &l30;ha
onL3"cef*6" class="line" name="L86">  86st30clude &l30;);
);
  86st30 href="k30;hFFFFFFFF90" claatchdog_enabledHRTIMER_RESTARTf="kernel/watchHRTIMER_RESTART clas="line" name="L90">  90}
3pan class3="comment"> */
  73
<3pclude &l3;;watchdog_enabledpridemref="kernel/watpridemot;  73
<3p2href="k3href="+code=pr_fmt" clas3s="sr31FIG_BOOTPARAM_HARDLOCKUP_PANIC_VALUE" class=smp_proc"ssor_ief="kernel/watch(mp_proc"ssor_ieot;nosoftlockup_sdur="L8"=watchdog_ev" cdur="L8" claf="line" name="L73">  73
<3p href="k3ernel/watchdog.c#L14" id3="L14313IG_BOOTPARAM_HARDLOCKUP_PANIC_VALUE" class=currd="=watchdog_ev" ccurrd="IG_B-
	  "sref">hrtimer_rnel=watchdog_ev" ccnel claf">nosoftlockup_s asm_pid_nn="kernel/watchdiasm_pid_nnot;  92  92  92was="line" name="L61">  61  3nclude &l3t;h_HARDLOCa_VALUE" class=show id="=watchdog_ev" cshow id="ot;wass="line" name="L92">  92  90}
3nclude &l3t;hFFFFFFFF>nosoftlockup_sdump_stack"kernel/watchdodump_stackot;  92  73
<3nclude &l3t;wfpwas="line" name="L61">  61  3nclude &l3;;,   92);
);
nosoftlockup_s ruef="kernel/watchtrueclasss="line" name="L90">  90}
3nclude &l3t;  90}
3a href="k3ernel/watchdog.c#L26" id3="L26325c#L75" id="LLLLLLLLLatchdog_enabledno"sof_cpu_writef="kernel/watchno"sof_cpu_write);
);
nosoftlockup_s="L90class="sref">st""L90classs="line" name="L90">  90}
3nclude &l3t;  67un3nclude &l3t;  90}
3nclude &l3t;  91  70st3t   73
<3tclude &l3="+code=__read_mostly" c3lass=33ernel/watchdog.c#L2" id="L2hd" class="line" name="L50">  50#i3a href="k3ernel/watchdog.c#L33" id3="L3333f="kernel/watchdog.c#L93" iM*aTse ">  78  10  86st3aclude &l3ref="+code=DEFINE_PER_CP3U" cl33ref">__inithardlockup_panic;
was="line" name="L61">  61  3atic   88  3aclude &l3ref="+code=DEFINE_PER_CP3U" cl336c#L75" id="Lperf_event *, hrtimer_sd=ef_priority=watchdog_ev" ccd=ef_priorityass="= 0 }s="line" name="L21">  21#i3aclude &l3ref="+code=DEFINE_PER_CP3U" cl33panic" class=perf_event *, watcent *, wa"= &="  "sref">hrtimer_noraw_get_cpu_vaog.c#L87" id="L8noraw_get_cpu_vaoot;  90}
3fdef   90}
3fclude &l3ref="+code=DEFINE_PER_CP3U" cl339"sref">strnca
  86st3atic watchdog_enabledno" id=";
  92  12#d3a href="k3ref="+code=DEFINE_PER_CP3U" cl34lass="sref">so
  47so
  47 *, waf">nosoftlockup_ses id_ktchda href="kernel/es id_ktchdstperioef="kernel/watchget_caf">stperioeot;  73
<3atic   90}
3aclude &l3="comment">/* boot comma3nds *34class="line" name="L67">  67un3pan class3="comment">/*
  90}
3adef  * Should we 3panic34lass="sref">wa
  47 */
  96stperioe():seconds (4:seconds by:default) to  hretf/spefclass="line" name="L96">  96   9   9  10  47  88  3      if 3(!  92hatchdog_enabledsd=efule=watchdog_ev" ccd=efuleot;  92  90}
3 tic hmp  90}
3      els3e if (!h_HARDLOCb" cks="line" name="L92">  92  12#d3      ret3urn 1;
  90}
3  91__s364IG_BOOTPARAMa
  47  47  10  47watchdog_enablednoset_currd="gat,tef="kernel/watchnoset_currd="gat,te  90}
3strncent *, nosoftlockup_sSCHED_NORMAatchdog.c#L73" iSCHED_NORMAaIG_Bf"&="  "sref">hrtimer_p ral=watchdog_ev" cparalass=ss="line" name="L90">  90}
3atic int 3w90" class="line" name="L89">  89  3  91  33st3aa href="3ernel/watchdog.c#L74" id3="L7437class="line" name="L14">  14#i3CONFIG_HARDLOCKUP_DETECTOR
  39st3  47__s375L86" class="linestrn4ri5L8l* Peo">sh+cker/spasif">s cgea"acpu/nNFI/pnfoL3"aboot0" class="line" name="L10">  10  78  47  10  47__init  90}
3      ret3urn 1;
  12#d3__init stcpuclass="line" name="L12">  12#d3__s38s="srs="line" name="L88">  88  3a href="k3ernel/watchdog.c#L85" id3="L85384c#L82" id="Lperf_event *,   90}
3 a href="3="comment">/* deprecated3 */ *, watcent *, wasimple_strtoullas_cpuclass="sref">stlas_cpuot;nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
3 href="+c3  67un3  href="k3kernel/watchdog.c#L88" i3d="L8387c#L75" id="La
  47mpwas&="  &="  cent *, wa-
	  "sref">hrtimer_at,tef="kernel/watchst,tePERF_EVENT_STATE_OFFf="kernel/watchPERF_EVENT_STATE_OFFclass="line" name="L12">  12#d3hgoto ple_strtouloue=watchdog_ev" coueass=s="line" name="L90">  90}
3  73
<3 href="+c3ode=__setup" class="sref3">__s391ass="sref">wa
  47/*  */3
was!imple_strtoulNULatchdog.c#L73" iNULaclass="line" name="L12">  12#d3phref="+c3ernel/watchdog.c#L94" id3="L94393IG_BOOTPARAM_HARDLOCgoto ple_strtouloue=e id="a href="kernel/oue=e id="ass=s="line" name="L90">  90}
3< href="k3="comment">/*
  85 * Hard-locku3p war395c#L75" id="Lent *, hrtimer_dd_hw_atdog.c#L87" id="L8dd_hw_atdoclass="line" name="L90">  90}
3 * jax_lookca3n hat39="sref">strncant *, hrtimer_aaf">stperioef="kernel/watchcaf">stperioeot;hw_ id=get_caf">stperioef="kernel/watchhw_ id=get_caf">stperioeot;  90}
3pa href="39ernel/watchdog.c#L88" i39="L839class="line" name="L78">  78st3p     wa
  47strncent *, wasimple_strtoullas="+code_c" cte_me="L4_coungee=watchdog_ev" clas="+code_c" cte_me="L4_coungeeot;nosoftlockup_scpuclass="sref">stcpuclasf">nosoftlockup_sNULatchdog.c#L73" iNULaclasf">nosoftlockup_sdog.c#L32ovef=low_callback"kernel/watchdog.c#L34" ovef=low_callbackot;nosoftlockup_sNULatchdog.c#L73" iNULaclasss="line" name="L90">  90}
4aan class4""comment"> */
  73
<40 href="k40rnel/watchdog.c#L12" id401"L9401ass="sref">wa
  47/*  */402"L9402c#L82" id="Lfpstcpuclas i= 0s&="  &="  cent *, wa)s="line" name="L90">  90}
40 href="k40rnel/watchdog.c#L14" id403"L9403IG_BOOTPARAM_HARDLOCatchdog_enabledcpu0_ere=watchdog_ev" ccpu0_ere cla_imple_strtoulPTR_ERwa)s="line" name="L90">  90}
4a4href="k40"comment">/*
  85wa)sms="line" name="L88">  88  40clude &l40;  47hfpstcpuclas i= 0s||Catchdog_enabledcpu0_ere=watchdog_ev" ccpu0_ere clas="line" name="L90">  90}
408lude &l40ref="+code=watchdog_ena408"L940FIG_BOOTPARAM_SOFTLOC_HARDLOCatchdog_enabledpog.cfo=watchdog_ev" clog.cfoot;,   90}
4a9lude &l40;hgoto ple_strtouloue=savea href="kernel/oue=s" iotass="line" name="L90">  90}
4pan class4="comment"> */
strncs="line" name="L91">  91  12#d4p2href="k4href="+code=pr_fmt" clas4s="sr41lass="sref">so
  47stcpuclas 
	  m0s&="  &="  c/atchdog_enabledPTR_ERwa).== ardlockup_paniccpu0_ere=watchdog_ev" ccpu0_ere class="line" name="L90">  90}
4 clude &l4t;wa)s="line" name="L90">  90}
4pclude &l4t;  26#i4pclude &l4t;strnca
  47wa).== -ef="+code=NULL"EOPNOTSUPP=watchdog_ev" cEOPNOTSUPP clas="line" name="L90">  90}
4pclude &l4t;, nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
4nclude &l4t;wa).== -ef="+code=NULL"ENOENTf="kernel/watchENOENT clas="line" name="L90">  90}
4nclude &l4t;hatchdog_enabledpog">onds.=watchdog_ev" clog">onds.cl;,   73
<4nclude &l4t;w="sref">hatchdog_enabledcpuclass="sref">stcpuclasss="line" name="L90">  90}
4nclude &l4;;  90}
4n href="k4t;,   73
<4nclude &l4t;hatchdog_enabledcpuclass="sref">stcpuclasf">nosoftlockup_sPTR_ERwa)ss="line" name="L90">  90}
4nclude &l4ernel/watchdog.c#L26" id4="L26425c#L75" id="L90" claatchdog_enabledPTR_ERwa)s="line" name="L90">  90}
4nclude &l4t;  67un4nclude &l4t;  47  47strncent *, stlas_cpuot;nosoftlockup_scpuclass="sref">stcpuclass_imple_strtoul+code=watchdog_ev" c"sref">was="line" name="L90">  90}
4t oue=e id="a href="kernel/oue=e id="ass=:="line" name="L47">  47strncent *, stlas_cpuot;nosoftlockup_scpuclass="sref">stcpuclass)s="line" name="L90">  90}
4a href="k4ernel/watchdog.c#L33" id4="L3343f="kerle_strtouloue=watchdog_ev" coueass=:="line" name="L47">  47  89  4aclude &l4ref="+code=DEFINE_PER_CP4U" cl434class="line" name="L91">  91  26#i4aclude &l4ref="+code=DEFINE_PER_CP4U" cl43s="sref">DEFvoid  stcpuclass="line" name="L12">  12#d4aclude &l4ref="+code=DEFINE_PER_CP4U" cl43panics="line" name="L88">  88  4fdef watcent *, wasimple_strtoullas_cpuclass="sref">stlas_cpuot;nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L89">  89  4aclude &l4ref="+code=DEFINE_PER_CP4U" cl43class="line" name="L70">  70st4atic wfpwasms="line" name="L88">  88  4atic watchdog_enabledpas="+code_disid="a href="kernel/pas="+code_disid="ot;wa)s="line" name="L90">  90}
4a href="k4ref="+code=DEFINE_PER_CP4U" cl44FIG_BOOTPARAM_HARDLOCatchdog_enabledlas_cpuclass="sref">stlas_cpuot;nosoftlockup_scpuclass="sref">stcpuclasssimple_strtoulNULatchdog.c#L73" iNULaclass="line" name="L90">  90}
4a href="k4ref="+code=DEFINE_PER_CP4U" cl44class="line" name="L14">  14#i4aclude &l4ref="kernel/watchdog.c#L445" i444IG_BOOTPARAM_HARDLOCa
  47wa)s="line" name="L90">  90}
4aclude &l4="comment">/* boot comma4nds *44="sref">strncs="line" name="L91">  91/*
  90}
4adef  * Should we 4panic44hen as="line" name="L91">  91 */
  90}
4fdef __init stcpuclass {L90" classcs="line" name="L91">  91DEFvoid  stcpuclass {L90" clscs="line" name="L91">  91  86st4 tic   14#i4atic int 4  47DEFvoid stg.c#L34" prepare_cpuot; stcpuclass="line" name="L12">  12#d4      if 4(!  88  4         4      *, watcent *, wa"= &="  "sref">hrtimer_las_cpuclass="sref">stlas_cpuot;nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L89">  89  4 def   90}
4 tic strncent *, stWARN_ONot;stlas_cpuot;);
nosoftlockup_scpuclass="sref">stcpuclass)s="line" name="L90">  90}
4      els4e if (!watchdog_enabledwatchdoginita href="kernel/watchdoginitot;waf">nosoftlockup_sCL39"_MONOTONICa href="kernel/CL39"_MONOTONIC">waf">nosoftlockup_sHRTIMER_MODE_RELa href="kernel/HRTIMER_MODE_RELclasss="line" name="L89">  89  4 tic int 4     strncent *, wa-
	  "sref">hrtimer_funalse;a href="kernel/funalse;">wasimple_strtouldog.c#L32"chdogffa href="kernel/dog.c#L32"chdogffclass="line" name="L90">  90}
4      ret4urn 1;
  91  14#i4 tic int 4ode=__setup" class="sref4">__s46ref">__inithardlockup_panic;
stcpuclass="line" name="L12">  12#d4ndif
  88  4n     if 4;;stiasm_perf_e">watcent *, wasimple_strtoullas_cpuclass="sref">stlas_cpuot;);
nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
4         4t    89  4      els4               90}
4strnca
  47watchdog_enabledere=watchdog_ev" cere cla_imstcpuclasss="line" name="L90">  90}
4  12#d4      so
  47  14#i4  78  47wasms="line" name="L88">  88  4 href="+c4ode=__setup" class="sref4">__s476c#L75" id="LLLLLLLLLperf_event *, hrtimer_sd=ef_priority=watchdog_ev" ccd=ef_priorityass="= "sref">hrtimer_MAX_RT_PRIO=watchdog_ev" cMAX_RT_PRIO">wa-1 }s="line" name="L21">  21#i4a href="k4ernel/watchdog.c#L78" id4="L7847panic" class="sref">hatchdog_enabledpref="kernel/watp">wasimple_strtoulkth" cl_c" cte_on_nNFIref="kernel/watkth" cl_c" cte_on_nNFIot;nosoftlockup_sNULatchdog.c#L73" iNULaclasf">nosoftlockup_scpu_to_nNFIref="kernel/watcpu_to_nNFIot;nosoftlockup_scpuclass="sref">stcpuclass,"ea href="kernel/watchdog.c#dog.c#L3/%dp" class="sref">nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
4atic int 4wassms="line" name="L88">  88  4 tic hFFFFFFFF>nosoftlockup_slogere=watchdog_ev" clogerecl;,   78nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
4      h_HARDLOCfp  88  4      ret4urn 1;
w="sref">hOTPARAMa
  47wass="line" name="L90">  90}
4 a href="4ode=__setup" class="sref4">__s483IG_BOOTPARAM_HARDLOCKUP_PANIhOTPARAMa
  47hFFFFFFFF>nosoftlockup_sg.c#L34"  id=disid="a href="kernel/dog.c#L32 id=disid="ot;nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
4 dif
/* deprecated4 */  91  90}
4  href="k4kernel/watchdog.c#L88" i4d="L848panic" class="sref">hs="line" name="L91">  91waf">nosoftlockup_sSCHED_FIFO=watchdog_ev" cSCHED_FIFO">waf"&="  "sref">hrtimer_p ral=watchdog_ev" cparalass=ss="line" name="L90">  90}
4hple_strtoulkth" cl_binfref="kernel/watkth" cl_binfot;waf">nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
4hatchdog_enabledpas_cpuclass="sref">stlas_cpuot;nosoftlockup_scpuclass="sref">stcpuclasssimss="line" name="L89">  89  4 href="+c4ode=__setup" class="sref4">__s49abled" class="sref">watchdog_enabledpas_cpuclass="sref">stlas_cpuot;);
nosoftlockup_scpuclass="sref">stcpuclasssimple_strtoullref="kernel/watp">was="line" name="L89">  89  4 a href="4="comment">/*  */4
wass="line" name="L90">  90}
4phref="+c4ernel/watchdog.c#L94" id4="L94493IG_BOOTPARAMs="line" name="L91">  91/*
  85 * Hard-locku4p war495c#L7ple_strtouloue=watchdog_ev" coueass=:="line" name="L47">  47 * jax_lookca4n hat49="sref">strnc90" claatchdog_enabledere=watchdog_ev" cere clas="line" name="L90">  90}
4p href="k49ernel/watchdog.c#L88" i49="L849classs="line" name="L91">  91  90}
4pclude &l4;;DEFvoid stcpuclass="line" name="L12">  12#d5aan class5""comment"> */
  88  50 href="k50rnel/watchdog.c#L12" id501"L9501ass="sref">wperf_event *, stiasm_perf_e">watcent *, wasimple_strtoullas_cpuclass="sref">stlas_cpuot;);
nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
502href="k50"comment">/*  */502"L9502c#L82" id="Lperf_event *, watcent *, wa"= &="  "sref">hrtimer_las_cpuclass="sref">stlas_cpuot;nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
503href="k50rnel/watchdog.c#L94" id503"L950class="line" name="L14">  14#i5a4href="k50"comment">/*
  47sclclass="line" name="L47">  47  47  47watchdog_enabledwatchdogcancela href="kernel/watchdogcancelot;wass="line" name="L90">  90}
509lude &l50;  70st5pan class5="comment"> */
strnco
  47strncent *, nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
5p2href="k5href="+code=pr_fmt" clas5s="sr51class="line" name="L33">  33st5p href="k5ernel/watchdog.c#L14" id5="L14513ass="sref">so
  78  47wasms="line" name="L88">  88  5pclude &l5t;stlas_cpuot;);
nosoftlockup_scpuclass="sref">stcpuclasssimple_strtoulNULatchdog.c#L73" iNULaclass="line" name="L90">  90}
5pclude &l5t;wass="line" name="L90">  90}
5p7lude &l5t;  91  91  70st5nclude &l5t;  47CONFIG_HARDLOSYSCTatchdog.c#L73" i_HARDLOSYSCTalass="line" name="L70">  70st5n2href="k5;;__init  12#d5n href="k5t;  88  5nclude &l5t;stcpuclass="line" name="L90">  90}
5nclude &l5ernel/watchdog.c#L26" id5="L2652class="line" name="L26">  26#i5nclude &l5t;strncant *, wa"= ss="line" name="L89">  89  5nclude &l5t;  78st5nclude &l5t;watchdog_enabledfor_each_onincl_cpuclass="sref">stfor_each_onincl_cpuot;nosoftlockup_scpuclass="sref">stcpuclass="line" name="L78">  78st5nclude &l5ernel/watchdog.c#L30" id5="L3052panic" class="sref">hmpnosoftlockup_scpuclass="sref">stcpuclasss="line" name="L78">  78st5t h_HARDLOCa
  78  47  47wa"= 1s="line" name="L89">  89  5t href="k5ref="+code=DEFINE_PER_CP5U" cl53class="line" name="L14">  14#i5aclude &l5ref="+code=DEFINE_PER_CP5U" cl534IG_BOOTPARAMfpwas="line" name="L78">  78st5tclude &l5ref="+code=DEFINE_PER_CP5U" cl535c#L75" id="LLLLLLLLLatchdog_enabledpogere=watchdog_ev" clogerecl;,   90}
5aclude &l5ref="+code=DEFINE_PER_CP5U" cl53class="line" name="L67">  67un5aclude &l5ref="+code=DEFINE_PER_CP5U" cl53classs="line" name="L91">  91  90}
5aclude &l5ref="+code=DEFINE_PER_CP5U" cl539"sreef">DEFvoid   12#d5atic   88  5atic  stcpuclass="line" name="L90">  90}
5a href="k5ref="+code=DEFINE_PER_CP5U" cl54class="line" name="L33">  33st5a href="k5ref="+code=DEFINE_PER_CP5U" cl543ass="sref">watchdog_enabledfor_each_onincl_cpuclass="sref">stfor_each_onincl_cpuot;nosoftlockup_scpuclass="sref">stcpuclass="line" name="L78">  78st5aclude &l5ref="kernel/watchdog.c#L545" i544IG_BOOTPARAM_HARDLOCaa href="+code=g.c#L34" disid="a href="kernel/dog.c#L32disid="ot;nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
5atic   26#i5aclude &l5="comment">/* boot comma5nds *54="sref">strnca
  78  47/*
 *, wa"= ss="line" name="L89">  89  5adef  * Should we 5panic54hen as="line" name="L91">  91 */
  70st5fdef   73
<5ftic   47  47  47  47  85watcent *, wa,hardlockup_panic;ritef="kernel/watch;rite">wa,="line" name="L85">  85watcent *, nosoftlockup_ssize_eclass="sref">stsize_e">watcent *, nosoftlockup_sloff_eclass="sref">stloff_e">watcent *,   78st5         5       88  5 def m">hardlockup_panicreeclass="sref">streeclass="line" name="L90">  90}
5 tic   70st5      els5e if (!watchdog_enabledreeclass="sref">streeclassimple_strtoullroc_dom">vec_minmaxf="kernel/watchproc_dom">vec_minmaxot;nosoftlockup_stid="a href="kernel/tid="">wa,wa,nosoftlockup_slenpref="kernel/watlenpot;nosoftlockup_sppo"=watchdog_ev" cppo"classs="line" name="L90">  90}
5 tic int 5     strncfpstreeclass|| !atchdog_enabled;ritef="kernel/watch;rite">was="line" name="L78">  78st5      ret5urn 1;
  90}
5  14#i5 tic int 5ode=__setup" class="sref5">__s564IG_BOOTPARAMfpwa"&="  &="  cent *,   14#i5 a href="5ref="kernel/watchdog.c#L566" i565c#L75" id="LLLLLLLLLatchdog_enabledg.c#L34" e id="_all_cpu"=watchdog_ev" cdog.c#L32e id="_all_cpu"ot;  90}
5 clude &l5;;  90}
5         5t hatchdog_enabledg.c#L34" disid="_all_cpu"=watchdog_ev" cdog.c#L32disid="_all_cpu"ot;  90}
5 def   90}
5oue=watchdog_ev" coueass=:="line" name="L47">  47w90" claatchdog_enabledreeclass="sref">streeclass="line" name="L90">  90}
5  91  47  14#i5  85  47__s575L86" class="linestrn4ri5L8ld w" cte/deperoy ">  78  47  47hardlockup_panic__cpuinita href="kernel/__cpuinitlass="line" name="L85">  85cpu_callback"kernel/watchdocpu_callbackot; *, watcent *,  *, wa,Lvoid cent *, sthcpuclass="line" name="L78">  78st5        88  5      ret5urn 1;
 sthotcpuclassim(unsigl"dLlong)ent *, sthcpuclass="line" name="L90">  90}
5  33st5 a href="5ode=__setup" class="sref5">__s583IG_BOOTPARAMswi  3wasms="line" name="L88">  88  5a href="k5ernel/watchdog.c#L85" id5="L85584IG_BOOTPARAMcasess="sref">CONFIG_PU_UP_PREPAREtchdog.c#L73" i_PU_UP_PREPAREass=:="line" name="L47">  47/* deprecated5 */CONFIG_PU_UP_PREPARE_FROZENclass="sref">st_PU_UP_PREPARE_FROZENass=:="line" name="L47">  47stg.c#L34" prepare_cpuot;sthotcpuclasss="line" name="L90">  90}
5  href="k5kernel/watchdog.c#L88" i5d="L858panic" class="sref">hb" cks="line" name="L90">  90}
5 def CONFIG_PU_ONLINEtchdog.c#L73" i_PU_ONLINEass=:="line" name="L47">  47CONFIG_PU_ONLINE_FROZENclass="sref">st_PU_ONLINE_FROZENass=:="line" name="L47">  47hfpwas="line" name="L78">  78st5 href="+c5ode=__setup" class="sref5">__s59abled" class="sref">wLLLLLLLLatchdog_enabledg.c#L34" e id="a href="kernel/dog.c#L32e id="ot;nosoftlockup_shotcpuclass="sref">sthotcpuclasss="line" name="L90">  90}
5 a href="5="comment">/*  */5
  90}
5phref="+c5ernel/watchdog.c#L94" id5="L94593IG_BR" class="sref">CONFIG_HARDLOHOTPLUG__PUclass="sref">st_HARDLOHOTPLUG__PUlass="line" name="L33">  33st5< href="k5="comment">/*
CONFIG_PU_UP_CANCELEDclass="sref">st_PU_UP_CANCELEDass=:="line" name="L47">  47 * Hard-locku5p war595c#L75" id="Lcasess="sref">CONFIG_PU_UP_CANCELED_FROZENclass="sref">st_PU_UP_CANCELED_FROZENass=:="line" name="L47">  47 * jax_lookca5n hat596c#L75" id="LLLLLLLLLatchdog_enabledg.c#L34" disid="a href="kernel/dog.c#L32disid="ot;nosoftlockup_shotcpuclass="sref">sthotcpuclasss="line" name="L90">  90}
5  href="k59ernel/watchdog.c#L88" i59="L859panic" class="sref">hb" cks="line" name="L90">  90}
5CONFIG_PU_DEADclass="sref">st_PU_DEADass=:="line" name="L47">  47CONFIG_PU_DEAD_FROZENclass="sref">st_PU_DEAD_FROZENass=:="line" name="L47">  47 */
hatchdog_enabledg.c#L34" disid="a href="kernel/dog.c#L32disid="ot;nosoftlockup_shotcpuclass="sref">sthotcpuclasss="line" name="L90">  90}
60 href="k60rnel/watchdog.c#L12" id601"L960abled" class="sref">wb" cks="line" name="L90">  90}
602href="k60"comment">/*  */602"L960f="ke classLa
  47  91/*
  85  47  47  47  47  47 */
w90" claatchdog_enabledNOTIFY_OKclass="sref">stNOTIFY_OKclass="line" name="L90">  90}
6pclude &l6;;  91  33st6p href="k6ernel/watchdog.c#L14" id6="L14613ass=__init *, watardlockup_panic__cpuinitdataa href="kernel/__cpuinitdata">watardlockup_paniccpu_nfb"kernel/watchdocpu_nfbclassims="line" name="L88">  88  6 clude &l6t;hrtimer_notifier_call"kernel/watchdonotifier_callclassimple_strtoulcpu_callback"kernel/watchdocpu_callbackot;<="line" name="L88">  88  6 clude &l6t;  21#i6pclude &l6t;  67un6p7lude &l6t;nosoftlockup_slo)detectooginita href="kernel/lo)detectooginitot;  12#d6pclude &l6t;  88  6 9lude &l6t; *, stcpuclassim(void c)(long)ent *,   90}
6nclude &l6t;   90}
6nclude &l6t;  12#d6n2href="k6;;cpu_callback"kernel/watchdocpu_callbackot;<(&="  "sref">hrtimer_cpu_nfb"kernel/watchdocpu_nfbclasf">nosoftlockup_sCPU_UP_PREPAREtchdog.c#L73" i_PU_UP_PREPAREass=f">nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
6n href="k6t;watchdog_enabledWARN_ONclass="sref">stWARN_ONot;  90}
6nclude &l6t;  85hrtimer_cpu_nfb"kernel/watchdocpu_nfbclasf">nosoftlockup_sCPU_ONLINEtchdog.c#L73" i_PU_ONLINEass=f">nosoftlockup_scpuclass="sref">stcpuclasss="line" name="L90">  90}
6nclude &l6t;strncant *, stregistas_cpu_notifierot;<(&="  "sref">hrtimer_cpu_nfb"kernel/watchdocpu_nfbclasss="line" name="L90">  90}
6n7lude &l6t;  78st6nclude &l6t;w90" cls="line" name="L90">  90}
6nclude &l6ernel/watchdog.c#L30" id6="L3062panics="line" name="L91">  91


p/div>


The original LXRlahdowaeekbyr/spa"line" nahttp://sourceforge.net/projects/lxs">LXRl48" unityass=, tsplxs@chdux.noass=.
p/div>

lxs.chdux.no kindlyLhostadsbyr"line" nahttp://www.redpill-chdpro.no=>Redpill Lhdpro ASass=, provider ofLLhdux consulads.krneloperalse;