VM

共 6 篇文章。

Matthew Dillon's most recent VM work

Kernel

From the commit log:

Close an interrupt race between vm_page_lookup() and (typically) a vm_page_sleep_busy() check by using the correct spl protection. An interrupt can occur inbetween the two operations and unbusy/free the page in question, causing the busy check to fail and for the code to fall through and then operate on a page that may have been freed and possibly even reused. Also note that vm_page_grab() had the same issue between the lookup, busy check, and vm_page_busy() call.

阅读全文… ( 本文约 229 字,阅读大致需要 2 分钟 )

Dillon's comments on FreeBSD/DFly's VM

Kernel

Dillon wrote:

Well, this is fun. There are over 460 files in the 5.x source tree (360 in DFly) that make calls to malloc(… M_NOWAIT), and so far about 80% of the calls that I’ve reviewed generate inappropriate side effects when/if a failure occurs. CAM is the biggest violator… it even has a few panic() conditionals if a malloc(… M_NOWAIT) fails. Not Fun!

阅读全文… ( 本文约 200 字,阅读大致需要 1 分钟 )