Patch "power: supply: Ratelimit no data debug output" has been added to the 4.14-stable tree

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

 



This is a note to let you know that I've just added the patch titled

    power: supply: Ratelimit no data debug output

to the 4.14-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     power-supply-ratelimit-no-data-debug-output.patch
and it can be found in the queue-4.14 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 8b8ddcddc7eeb88e31780a773d526054e10be8ee
Author: Marek Vasut <marex@xxxxxxx>
Date:   Sun Mar 5 21:52:26 2023 +0100

    power: supply: Ratelimit no data debug output
    
    [ Upstream commit 155c45a25679f571c2ae57d10db843a9dfc63430 ]
    
    Reduce the amount of output this dev_dbg() statement emits into logs,
    otherwise if system software polls the sysfs entry for data and keeps
    getting -ENODATA, it could end up filling the logs up.
    
    This does in fact make systemd journald choke, since during boot the
    sysfs power supply entries are polled and if journald starts at the
    same time, the journal is just being repeatedly filled up, and the
    system stops on trying to start journald without booting any further.
    
    Signed-off-by: Marek Vasut <marex@xxxxxxx>
    Reviewed-by: Hans de Goede <hdegoede@xxxxxxxxxx>
    Signed-off-by: Sebastian Reichel <sebastian.reichel@xxxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/power/supply/power_supply_sysfs.c b/drivers/power/supply/power_supply_sysfs.c
index 2ccaf4ff4be47..2cb8a31e9dac0 100644
--- a/drivers/power/supply/power_supply_sysfs.c
+++ b/drivers/power/supply/power_supply_sysfs.c
@@ -88,7 +88,8 @@ static ssize_t power_supply_show_property(struct device *dev,
 
 		if (ret < 0) {
 			if (ret == -ENODATA)
-				dev_dbg(dev, "driver has no data for `%s' property\n",
+				dev_dbg_ratelimited(dev,
+					"driver has no data for `%s' property\n",
 					attr->attr.name);
 			else if (ret != -ENODEV && ret != -EAGAIN)
 				dev_err_ratelimited(dev,



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux