On 03/11/2010 07:25 AM, Paolo Bonzini wrote:
On 03/11/2010 01:57 PM, Paul Brook wrote:
+struct QEMUNotifier
>  +{
>  +    void (*notify)(QEMUNotifier *notifier);
>  +};

I suggest combining this with QEMUBH.

I didn't understand this suggestion exactly, but I think it's related that I didn't understand the advantage of making QEMUNotifier a struct. Instead of using container_of, reusing QEMUBHFunc (renamed to QEMUCallbackFunc maybe?) in QEMUNotifierNode like this:

I like treating a slot as a single object instead of as function pointer/opaque pair. It gives us better type safety and reduces the amount of parameters that need to be passed around.

Regards,

Anthony Liguori


Reply via email to