Home
last modified time | relevance | path

Searched refs:need_resched (Results 1 – 25 of 86) sorted by relevance

1234

/linux/Documentation/translations/zh_CN/scheduler/
H A Dsched-arch.rst37 2. need_resched/TIF_NEED_RESCHED 只会被设置,并且在运行任务调用 schedule()
38 之前永远不会被清除。空闲线程只需要查询need_resched,并且永远不会设置或清除它。
40 3. 当cpu_idle发现(need_resched() == 'true'),它应该调用schedule()。否则
43 4. 在检查need_resched时,唯一需要禁用中断的情况是,我们要让处理器休眠到下一个中
44 断(这并不对need_resched提供任何保护,它可以防止丢失一个中断):
49 if (!need_resched()) {
55 5. 当need_resched变为高电平时,TIF_POLLING_NRFLAG可以由不需要中断来唤醒它们
56 的空闲程序设置。换句话说,它们必须定期轮询need_resched,尽管做一些后台工作或
60 么需要清除它,然后发出一个内存屏障(接着测试need_resched,禁用中断,如3中解释)。
/linux/Documentation/scheduler/
H A Dsched-arch.rst29 2. need_resched/TIF_NEED_RESCHED is only ever set, and will never
31 threads need only ever query need_resched, and may never set or
34 3. When cpu_idle finds (need_resched() == 'true'), it should call
38 need_resched is if we are about to sleep the processor until
40 need_resched, it prevents losing an interrupt):
45 if (!need_resched()) {
52 need an interrupt to wake them up when need_resched goes high.
53 In other words, they must be periodically polling need_resched,
59 barrier issued (followed by a test of need_resched with
/linux/arch/arm64/include/asm/
H A Dpreempt.h31 current_thread_info()->preempt.need_resched = 0; in set_preempt_need_resched()
36 current_thread_info()->preempt.need_resched = 1; in clear_preempt_need_resched()
41 return !current_thread_info()->preempt.need_resched; in test_preempt_need_resched()
/linux/arch/mips/kernel/
H A Dentry.S48 # interrupt setting need_resched
84 local_irq_disable # make sure need_resched and
128 local_irq_disable # make sure need_resched and
150 local_irq_disable # make sure need_resched doesn't
H A Didle.c47 if (!need_resched()) in r4k_wait_irqoff()
61 if (!need_resched()) in rm7k_wait_irqoff()
/linux/arch/x86/include/asm/
H A Dmwait.h111 if (need_resched()) in mwait_idle_with_hints()
122 if (need_resched()) in mwait_idle_with_hints()
/linux/fs/jbd2/
H A Dcheckpoint.c285 need_resched() || spin_needbreak(&journal->j_list_lock) || in jbd2_log_do_checkpoint()
403 if (need_resched()) in journal_shrink_one_cp_list()
466 if (need_resched() || spin_needbreak(&journal->j_list_lock)) in jbd2_journal_shrink_checkpoint_list()
525 if (need_resched()) in __jbd2_journal_clean_checkpoint_list()
/linux/drivers/cpuidle/
H A Dcoupled.c477 if (need_resched()) { in cpuidle_enter_state_coupled()
519 if (need_resched()) { in cpuidle_enter_state_coupled()
535 if (need_resched()) { in cpuidle_enter_state_coupled()
/linux/arch/powerpc/lib/
H A Dvmx-helper.c49 if (need_irq_preemption() && need_resched()) in exit_vmx_usercopy()
/linux/kernel/sched/
H A Didle.c191 if (need_resched()) { in cpuidle_idle_call()
286 WARN_ON_ONCE(need_resched()); in do_idle()
301 * then setting need_resched is guaranteed to cause the CPU to in do_idle()
308 while (!need_resched()) { in do_idle()
314 * wakes from the sleeping instruction. And testing need_resched() in do_idle()
331 * need_resched() check before re-executing the sleeping in do_idle()
374 * need_resched() is set while polling is set. That means that clearing in do_idle()
/linux/drivers/net/ethernet/sfc/
H A Def100_rep.c399 bool need_resched; in efx_ef100_rep_poll() local
424 need_resched = efv->write_index != read_index; in efx_ef100_rep_poll()
426 if (need_resched) in efx_ef100_rep_poll()
/linux/fs/
H A Ddrop_caches.c32 (mapping_empty(inode->i_mapping) && !need_resched())) { in drop_pagecache_sb()
/linux/drivers/acpi/
H A Dacpi_pad.c168 while (!need_resched()) { in power_saving_thread()
209 /* If an external event has set the need_resched flag, then in power_saving_thread()
213 if (unlikely(need_resched())) in power_saving_thread()
/linux/Documentation/translations/zh_CN/locking/
H A Dmutex-design.rst53 任务(need_resched,需要重新调度)准备运行时,当前任务试图自旋来获得
/linux/drivers/gpib/agilent_82350b/
H A Dagilent_82350b.c539 if (need_resched()) in init_82350a_hardware()
550 if (need_resched()) in init_82350a_hardware()
573 if (need_resched()) in test_sram()
584 if (need_resched()) in test_sram()
/linux/drivers/net/wireguard/
H A Dsend.c282 if (need_resched()) in wg_packet_tx_worker()
306 if (need_resched()) in wg_packet_encrypt_worker()
/linux/mm/
H A Ddmapool_test.c86 if (need_resched()) in dmapool_test_block()
/linux/kernel/locking/
H A Dmutex.c406 if (!owner_on_cpu(owner) || need_resched()) { in mutex_spin_on_owner()
432 if (need_resched()) in mutex_can_spin_on_owner()
533 * If we fell out of the spin path because of need_resched(), in mutex_optimistic_spin()
537 if (need_resched()) { in mutex_optimistic_spin()
/linux/arch/arm/mach-omap2/
H A Dcpuidle34xx.c114 if (omap_irq_pending() || need_resched()) in omap3_enter_idle()
H A Dpm33xx-core.c221 if (omap_irq_pending() || need_resched()) in am33xx_cpu_suspend()
/linux/arch/um/kernel/
H A Dprocess.c233 return need_resched(); in uml_need_resched()
/linux/security/keys/
H A Dgc.c264 if (spin_is_contended(&key_serial_lock) || need_resched()) in key_garbage_collector()
/linux/arch/s390/kvm/
H A Dgmap.c926 if (need_resched()) in _gmap_enable_skeys()
986 if (need_resched()) in gmap_pv_destroy_range()
1003 if (need_resched()) in gmap_insert_rmap()
1104 if (need_resched()) in gmap_unshadow_level()
/linux/drivers/gpib/nec7210/
H A Dnec7210.c451 if (need_resched()) in nec7210_command()
513 if (need_resched()) in pio_read()
662 if (need_resched()) in pio_write()
/linux/drivers/gpib/fmh_gpib/
H A Dfmh_gpib.c521 if (need_resched()) in fmh_gpib_accel_write()
704 if (need_resched()) in fmh_gpib_fifo_write()
900 if (need_resched()) in fmh_gpib_accel_read()
1020 if (need_resched()) in fmh_gpib_fifo_read()

1234