lkml.org 
[lkml]   [2018]   [Jun]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[PATCH 0/4] lib/vsprintf: Remove atomic-unsafe support for printk format %pCr
Date
	Hi all,

"%pCr" formats the current rate of a clock, and calls clk_get_rate().
The latter obtains a mutex, hence it must not be called from atomic
context. As vsprintf() (and e.g. printk()) must be callable from any
context, it's better to remove support for this (rarely-used) format.

This patch series:
- Changes all existing users of "%pCr" to print the result of
clk_get_rate() directly, which is safe as they all do this in task
context only,
- Removes support for the "%pCr" printk format.

Note that any remaining out-of-tree users will start seeing the clock's
name printed instead of its rate.

Thanks for your comments!

Geert Uytterhoeven (4):
clk: renesas: cpg-mssr: Stop using printk format %pCr
thermal: bcm2835: Stop using printk format %pCr
serial: sh-sci: Stop using printk format %pCr
lib/vsprintf: Remove atomic-unsafe support for %pCr

Documentation/core-api/printk-formats.rst | 3 +--
drivers/clk/renesas/renesas-cpg-mssr.c | 9 +++++----
drivers/thermal/broadcom/bcm2835_thermal.c | 4 ++--
drivers/tty/serial/sh-sci.c | 4 ++--
lib/vsprintf.c | 3 ---
5 files changed, 10 insertions(+), 13 deletions(-)

--
2.7.4

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds

\
 
 \ /
  Last update: 2018-06-01 11:30    [W:0.169 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site