On 20.01.25 9:41, Pavel Tikhomirov wrote:
On 12/6/24 05:55, Alexander Atanasov wrote:
@@ -1402,6 +1402,12 @@ static void ploop_submit_cow_index_wb(struct
ploop_cow *cow)
WARN_ON(to[clu]);
WRITE_ONCE(to[clu], cow->dst_clu);
+ write_lock_irqsave(&md->lock, flags);
Should have _irq suffix.
There is a patch at the end of the series that removes
all save/restore variants. I will leave this as is - it is working but
not optimal.
+ to = md->kmpage;
+ WRITE_ONCE(to[clu], cow->dst_clu);
+ WRITE_ONCE(md->bat_levels[clu], ploop_top_level(ploop));
+ write_unlock_irqrestore(&md->lock, flags);
+
/* Prevent double clearing of holes_bitmap bit on complete_cow() */
cow->dst_clu = BAT_ENTRY_NONE;
spin_lock_irq(&ploop->deferred_lock);
Same as here.
note: Only possible call stack:
+-< ploop_submit_cow_index_wb
+-< ploop_process_one_delta_cow
| +-< ploop_process_delta_cow
| | +-< do_ploop_run_work
| | | +-< do_ploop_work
| | | +-< ploop_worker
it is always in process context.
Do you have traces from enospc timer ? for cow?
I think it is safe (as in defensive) to use save/restore everythere
until timer is changed.
--
Regards,
Alexander Atanasov
_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel