本文整理汇总了C++中Capability::invalidate方法的典型用法代码示例。如果您正苦于以下问题:C++ Capability::invalidate方法的具体用法?C++ Capability::invalidate怎么用?C++ Capability::invalidate使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Capability
的用法示例。
在下文中一共展示了Capability::invalidate方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: assert
Obj_space_phys<SPACE>::v_delete(V_pfn virt, Page_order size,
L4_fpage::Rights page_attribs = L4_fpage::Rights::FULL())
{
(void)size;
assert (size == Page_order(0));
Capability *c = get_cap(virt);
if (c && c->valid())
{
if (page_attribs & L4_fpage::Rights::R())
c->invalidate();
else
c->del_rights(page_attribs);
}
return L4_fpage::Rights(0);
}
示例2: assert
unsigned long
Generic_obj_space<SPACE>::v_delete(Page_number virt, Size size,
unsigned long page_attribs = L4_fpage::RWX)
{
(void)size;
assert (size.value() == 1);
Capability *c = get_cap(virt.value());
if (c && c->valid())
{
if (page_attribs & L4_fpage::R)
c->invalidate();
else
c->del_rights(page_attribs & L4_fpage::WX);
}
return 0;
}