[PATCH V2 0/3] Introduce and use DO_ONCE statement expression macro

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The printk_once macro in kernel.h is limited to printk

This generalizes the functionality of printk_once and
allows statements like DO_ONCE(pr_info("foo\n"))
and DO_ONCE(initialize(foo));

Uses atomic test_and_set_bit

Joe Perches (3):
  kernel.h: Add DO_ONCE statement expression macro
  arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c: Use DO_ONCE & spelling fix
  kernel.h: Remove unused printk_once

 arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c |    4 ++--
 include/linux/kernel.h                     |   26 +++++++++++---------------
 2 files changed, 13 insertions(+), 17 deletions(-)

--
To unsubscribe from this list: send the line "unsubscribe cpufreq" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Devel]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Forum]     [Linux SCSI]

  Powered by Linux