power: supply: Ratelimit no data debug output
PATCH 1/1 power: supply: Ratelimit no data debug output
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.
---
Cc: Hans de Goede <[email protected]>
Cc: Sebastian Reichel <[email protected]>
Cc: [email protected]
--- drivers/power/supply/power_supply_sysfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/power/supply/power_supply_sysfs.c +2 -1
@@ -285,7 +285,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,
Signature · 1 line
2.39.2
Hi,
Quoted 9 lines · Marek Vasut
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.
Quoted 5 lines
Signed-off-by Marek Vasut <[email protected]>---
Cc: Hans de Goede <[email protected]>
Cc: Sebastian Reichel <[email protected]>
Cc: [email protected]
Thanks, patch looks good to me:
Regards,
Hans
Quoted 18 lines
--- drivers/power/supply/power_supply_sysfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/power/supply/power_supply_sysfs.c +2
-1@@ -285,7 +285,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,
Quoted 1 line · Hans de Goede
Hi,
Hi,
Quoted 16 lines · Marek Vasut
Quoted 9 lines
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.
Quoted 5 lines
Signed-off-by Marek Vasut <[email protected]>---
Cc: Hans de Goede <[email protected]>
Cc: Sebastian Reichel <[email protected]>
Cc: [email protected]
Quoted 3 lines
Thanks, patch looks good to me:
Reviewed-by Hans de Goede <[email protected]>
Any news ? Maybe this could be applied now ?
Hi,
Quoted 17 lines · Marek Vasut
Quoted 16 lines · Hans de Goede
Quoted 14 lines · Marek Vasut
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 <[email protected]>---
Cc: Hans de Goede <[email protected]>
Cc: Sebastian Reichel <[email protected]>
Cc: [email protected]
Quoted 5 lines
Quoted 3 lines
Thanks, patch looks good to me:
Reviewed-by Hans de Goede <[email protected]>Any news ? Maybe this could be applied now ?
Sorry for the delay; I applied it to my fixes branch now.
-- Sebastian
Quoted 1 line · Sebastian Reichel
Hi,
Hi,
Quoted 18 lines · Marek Vasut
Quoted 17 lines · Hans de Goede
Quoted 16 lines · Marek Vasut
Quoted 14 lines
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 <[email protected]>---
Cc: Hans de Goede <[email protected]>
Cc: Sebastian Reichel <[email protected]>
Cc: [email protected]
Quoted 7 lines
Quoted 5 lines
Quoted 3 lines
Thanks, patch looks good to me:
Reviewed-by Hans de Goede <[email protected]>Any news ? Maybe this could be applied now ?
Sorry for the delay; I applied it to my fixes branch now.
Thanks !