On 08/19/2014 01:40 PM, David Matlack wrote: > On Mon, Aug 18, 2014 at 10:19 PM, Xiao Guangrong > <xiaoguangr...@linux.vnet.ibm.com> wrote: >> On 08/19/2014 01:00 PM, David Matlack wrote: >>> On Mon, Aug 18, 2014 at 9:41 PM, Xiao Guangrong >>> <xiaoguangr...@linux.vnet.ibm.com> wrote: >>>> On 08/19/2014 12:31 PM, David Matlack wrote: >>>>> The single line patch I suggested was only intended to fix the "forever >>>>> incorrectly exit mmio". >>>> >>>> My patch also fixes this case and that does not doubly increase the >>>> number. I think this is the better one. >>> >>> I prefer doubly increasing the generation for this reason: the updated >>> boolean >>> requires extra code on the "client-side" to check if there's an update in >>> progress. And that makes it easy to get wrong. In fact, your patch >>> forgot to check the updated bit in mark_mmio_spte(). Doubly increasing the >>> generation requires no "client-side" code to work. >> >> No, the updated patch is used to fix case 2 which i draw the scenario in >> the last mail. I mean the original patch in this patchset which just >> increase the number after srcu-sync. >> >> Then could you tell me that your approach can do but my original patch can >> not? > > It avoids publishing new memslots with an old generation number attached to > them (even if it only lasts for a short period of time).
I can not see the problem if that happen, could you please draw the scenario? > Do you have a reason > why you don't want to doubly increase the generation? That more easily causes the number wrap-around. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/