On Thu, Feb 03, 2022 at 03:29:30PM -0500, Sasha Levin wrote: > From: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> > > [ Upstream commit c9d967b2ce40d71e968eb839f36c936b8a9cf1ea ] > > The buffer handling in pm_show_wakelocks() is tricky, and hopefully > correct. Ensure it really is correct by using sysfs_emit_at() which > handles all of the tricky string handling logic in a PAGE_SIZE buffer > for us automatically as this is a sysfs file being read from. > > Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> > Reviewed-by: Lee Jones <lee.jones@xxxxxxxxxx> > Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@xxxxxxxxx> > Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> > --- > kernel/power/wakelock.c | 11 ++++------- > 1 file changed, 4 insertions(+), 7 deletions(-) This is already in a stable release, so no need to add it again. thanks, greg k-h