WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [xen-devel][PATCH 2/5] Xl interface change plus changes to code it i

To: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Subject: Re: [xen-devel][PATCH 2/5] Xl interface change plus changes to code it impacts
From: Kamala Narasimhan <kamala.narasimhan@xxxxxxxxx>
Date: Mon, 14 Feb 2011 13:30:14 -0500
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Mon, 14 Feb 2011 10:33:49 -0800
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:content-type :content-transfer-encoding; bh=V01D0/Bp5SQ41lg6rpdrd3KMYFthHfMvMN4RtJWIGgw=; b=O1VjLny1Y7xFT0MaY2NIpwYISDiNfuRBaDduNlTGHhI2E+jfu++VJRB8F0cMLqJaW3 Y3mhbZnCMRNqDek59NRto7f09P+bYkqgACh0gK2z6wKHviSlLrj1OKncqvabHyt9Sg4H BLCwQEJQPo7p9Y6aeQf/FKhJ6+E8Md8TCzoIw=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=DhahYeqqX7yzE25KSbjCwqbLfKXuAA5pu9lF6blCsIL0XoD4zUY11yHGvNTQJovV0J 4hz0t6AkzyUK8KptlUefmjGmk5vFFVwYgsOGFi3xYtxiQksPdGCICKI527JRjZQWNt7d jCfxec5ADndTZCouIgnSqvnWWOF7UXlHVISYM=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <19801.27199.25918.814669@xxxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <4D5060EB.3060109@xxxxxxxxx> <4D52DB1E.6080101@xxxxxxxxx> <alpine.DEB.2.00.1102101143110.7277@kaball-desktop> <4D541AC6.6040802@xxxxxxxxx> <4D5443E6.8010704@xxxxxxxxx> <alpine.DEB.2.00.1102111228340.2826@kaball-desktop> <4D555368.3010504@xxxxxxxxx> <4D558A02.6010106@xxxxxxxxx> <19801.27199.25918.814669@xxxxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.24 (X11/20101027)
Ian Jackson wrote:
> Kamala Narasimhan writes ("Re: [xen-devel][PATCH 2/5] Xl interface change 
> plus changes to code it impacts"):
>> Per suggestion, along with the latest patch is a more detailed
>> description to add to the check-in message -
> 
> It looks good to me, thanks, apart from some nits.  If you could
> address these I'll apply it :-).
> 
>> -            if (libxl__blktap_enabled(&gc))
>> +            if (libxl__blktap_enabled(&gc) && 
>> +                 disk->format != DISK_BACKEND_QDISK)
> 
> Some mistake here surely ?
>
Of course!

>> diff -r 6c22ae0f6540 tools/libxl/libxl.c
>> --- a/tools/libxl/libxl.c    Fri Feb 11 16:51:44 2011 +0000
>> +++ b/tools/libxl/libxl.c    Fri Feb 11 13:48:12 2011 -0500
> ...
>> -    switch (disk->phystype) {
> ...
>> +    switch (disk->backend) {
> 
> You have introduced these braces { }, but that seems to me to be just
> a stylistic change and they are not really needed ?
> 
No, I have switched disk->phystype to disk->backend.

>> +            libxl__device_physdisk_major_minor(disk->pdev_path, &major, 
>> &minor);
> 
> This function can fail.  It has two call sites neither of which check
> the return value.  Perhaps that should be addressed in a separate
> patch, as your change here isn't making it worse.  So no need to do
> anything about this right now if you don't want to.
> 
Yes, it isn't part of what we intended to change.  There are other things too
with respect to disk configuration option code that requires revisiting.

>> -        case PHYSTYPE_QCOW2:
>> -        case PHYSTYPE_VHD:
>> +        case DISK_BACKEND_TAP:
>> +        case DISK_BACKEND_QDISK: {
> 
> Once again, this is a stylistic change.  These { } are not used
> elsewhere in libxl so you should not introduce them.  (It would be a
> different matter if there were some reason why they are required in a
> particular case, eg to introduce a relevant block scope.)
> 
I agree, will change.

>>          case DSTATE_PHYSPATH:
>> -            if ( *p == ',' ) {
>> +            if (*p == ',') {
>>                  int ioemu_len;
> 
> It is good that you fixed up the formatting in code you changed, but
> please do not make formatting changes to unchanged lines.
>
Argg...  I was worried you might ask why I didn't fix the style around the code
I changed.  I have reverted the changes.

> We will do a style cleanup after 4.1 is released.
> 
>> -                if ( tok + ioemu_len < end &&
>> +                if (tok + ioemu_len < end &&
> 
> Once again.  Can you make sure your patch doesn't have /any/ unrelated
> formatting changes to lines you don't touch, please ?
>
Yes.

I will send a patch momentarily.

Kamala

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>