mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 12:44:03 +02:00
xfs: bump lost_prev_errors if we lose even the healthmon lost event
LOLLM observes that we don't bump xfs_healthmon::lost_prev_event even if
we can't allocate or queue a LOST event, which means that events can
disappear silently when things are going very wrong. Bump the counter
to avoid this problem.
Cc: stable@vger.kernel.org # v7.0
Fixes: b3a289a2a9 ("xfs: create event queuing, formatting, and discovery infrastructure")
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Assisted-by: LOLLM # finding obvious bugs
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
This commit is contained in:
parent
74eeb68a62
commit
295f2cfd3e
|
|
@ -326,8 +326,10 @@ xfs_healthmon_clear_lost_prev(
|
|||
if (hm->events < XFS_HEALTHMON_MAX_EVENTS)
|
||||
event = kmemdup(&lost_event, sizeof(struct xfs_healthmon_event),
|
||||
GFP_NOFS);
|
||||
if (!event)
|
||||
if (!event) {
|
||||
xfs_healthmon_bump_lost(hm);
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
__xfs_healthmon_insert(hm, INSERT_TAIL, event);
|
||||
cleared:
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user