From: Scott Feldman <sfel...@gmail.com> Date: Thu, 24 Sep 2015 22:29:43 -0700
> I'd rather keep 2-phase not optional, or at least make it some what of > a pain for drivers to opt-out of 2-phase. Forcing the driver to see > both phases means the driver needs to put some code to skip phase 1 > (and hopefully has some persistent comment explaining why its being > skipped). Something like: > > /* I'm skipping phase 1 prepare for this operation. I have infinite hardware > * resources and I'm not setting any persistent state in the driver or device > * and I don't need any dynamic resources from the kernel, so its impossible > * for me to fail phase 2 commit. Nothing to prepare, sorry. > */ I agree with Scott here. If you can opt out of something, you can not think about it and thus more likely get it wrong. I can just see a driver not implementing prepare at all and then doing stupid things in commit when they hit some resource limit or whatever, rather than taking care of such issues in prepare. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html