All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Egger <Christoph.Egger@amd.com>
To: Ian Jackson <Ian.Jackson@eu.citrix.com>
Cc: xen-devel@lists.xensource.com
Subject: Re: [PATCH] tools: don't require hardcoded path in guest config file
Date: Fri, 19 Jun 2009 17:32:25 +0200	[thread overview]
Message-ID: <200906191732.26314.Christoph.Egger@amd.com> (raw)
In-Reply-To: <19003.43994.710809.744259@mariner.uk.xensource.com>

On Friday 19 June 2009 17:16:42 Ian Jackson wrote:
> Christoph Egger writes ("[Xen-devel] [PATCH] tools: don't require hardcoded 
path in guest config file"):
> > Attached patch allows xen tools to no longer require the hardcoded path's
> > to hvmloader, qemu-dm and stubdom-dm in the guest config files.
>
> In general I think this is a great idea.
> I just have some detailed quibbles.
>
> > +            if not os.path.exists(self['platform']['device_model']):
> > +                self['platform']['device_model'] = \
> > +                    auxbin.pathTo(self['platform']['device_model'])
>
> I think it would be better just to look for a slash in the specified
> value, and always prepend the path.  Otherwise you end up checking for
> the file in xend's cwd which is pretty strange behaviour.
>
> Treating all /-less values as paths in the expected installation
> directory is more sensible.

Ok.

> > +                    # XXX basename works around a bug somewhere in the 
guest
> > +                    # config file parser which prepends cwd to the kernel 
> > +                   # w/o checking if the result is valid if no  absolute
> > +                    # path is specified 
>
> Surely it would be better to fix the guest config file parser!

Right. But I didn't find the exact place where the cwd is actually prepended.
It would be great, if you can help out here.

> > +                    if os.path.basename(self['PV_kernel']) 
==  'hvmloader':
>
> That workaround is a pretty hideous hack.

Yes, it is.

Christoph


-- 
---to satisfy European Law for business letters:
Advanced Micro Devices GmbH
Karl-Hammerschmidt-Str. 34, 85609 Dornach b. Muenchen
Geschaeftsfuehrer: Thomas M. McCoy, Giuliano Meroni
Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen
Registergericht Muenchen, HRB Nr. 43632

  reply	other threads:[~2009-06-19 15:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-19 14:33 [PATCH] tools: don't require hardcoded path in guest config file Christoph Egger
2009-06-19 15:16 ` Ian Jackson
2009-06-19 15:32   ` Christoph Egger [this message]
2009-06-22 13:01   ` Christoph Egger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200906191732.26314.Christoph.Egger@amd.com \
    --to=christoph.egger@amd.com \
    --cc=Ian.Jackson@eu.citrix.com \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.