Divacky Roman wrote:

hi

[snip]

is my analysis correct? if so, can the race be mitigated by moving the flag 
setting (hence
also the locking) after the msleep()?


No. When the wakeup is performed, the VPO_SWAPINPROG flag is also cleared. Both operations occur in the I/O completion handler with the object locked. Thus, if the I/O completion handler runs first, the msleep on the page within the while loop will not occur because the page's VPO_SWAPINPROG flag is already cleared.

Regards,
Alan

_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to