[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] Is there example code and/or documentation for developing a Xen back-end/front-end driver pair?
Ewan Mellor wrote: Attached are some notes of mine. They are quite old, but I think it all ispretty much relevant.Basically, a backend watches /local/domain/0/backend/<deviceClass> and a frontend watches /local/domain/<domID>/device/<deviceClass>. When the tools write into those directories in the store, the drivers get a watch fired, and check those directories to see the new device details. The new internal stateis created based on that.If you are using the normal Xenbus code, then you can register your devicedriver with the Xenbus layer, and much of this is done for you.The drivers themselves use a simple state machine to handshake between frontand backends.The backends use hotplug / udev events inside domain 0 to trigger scripts forsimple bringup/teardown stuff, like attaching new vifs to bridges orwhatever. The tools watch for a specific node to be written in the store to indicate that this hotplug phase has succeeded (it's usually the one that doesthe final sanity checking and often has to bail out). HTH, IHI {It Helps Indeed!} Thanks. Could I encourage you to post those on the XenSource Wiki? -- Randy _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |