From mboxrd@z Thu Jan 1 00:00:00 1970 From: aq Subject: Re: problem using xenbus interface Date: Tue, 9 Aug 2005 15:47:28 +0900 Message-ID: <9cde8bff05080823471ed79f37@mail.gmail.com> References: <5d7aca9505080805267dce691b@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Dan Smith Cc: NAHieu , "List: Xen Developers" List-Id: xen-devel@lists.xenproject.org On 8/8/05, Dan Smith wrote: >=20 > > err =3D xenbus_scanf("/", "restart_mode", "%s", mode); >=20 > This will try to read //restart_mode, not /domain//restart_mode, > which I assume is not what you want. >=20 > Also, there is no way to access keys in the /domain/ directly, > only keys in subfolders. For example, you should be using something > like /domain//control/restart_mode, like this: >=20 > err =3D xenbus_scanf("control", "restart_mode", "%s", mode); >=20 > Note the absence of the leading '/' in the directory parameter. This > means the location is relative to the "home directory" of the domain. >=20 > > err =3D xenbus_mkdir("/", "test"); >=20 > As I understand it, the plan is to remove the xenbus_mkdir() kernel > interface. Directories should be created by the tools. You should > have Xend (or something else) do the creation before the kernel needs > it. I have another idea on this: if directories must be created by tools, we (or somebody desires) will have to patch Xend (or whatever) everytime we have a new kernel module. Imagine that we have 100 third party drivers in the future, are we willing to patch Xend 100 times? Let domU create xenstore nodes itself is a good thing: new kernel drivers can be self-contained. I hope we will not remove xenbus_mkdir(), or if we do, replace it with another equally. regards, aq