ia64/xen-unstable

changeset 1049:e38f01055fc3

bitkeeper revision 1.688 (4011789fups9-ci9C6L2ART_UCuhpA)

xl_vbd.c:
Fix VBD setup in XL.
author kaf24@scramble.cl.cam.ac.uk
date Fri Jan 23 19:40:15 2004 +0000 (2004-01-23)
parents 92b00b4495fa
children 7f65f6292176
files xenolinux-2.4.24-sparse/arch/xeno/drivers/block/xl_vbd.c
line diff
     1.1 --- a/xenolinux-2.4.24-sparse/arch/xeno/drivers/block/xl_vbd.c	Thu Jan 22 21:07:39 2004 +0000
     1.2 +++ b/xenolinux-2.4.24-sparse/arch/xeno/drivers/block/xl_vbd.c	Fri Jan 23 19:40:15 2004 +0000
     1.3 @@ -456,10 +456,11 @@ void xlvbd_update_vbds(void)
     1.4          }
     1.5          else
     1.6          {
     1.7 -            if ( xlvbd_init_device(&new_info[j]) == 0 )
     1.8 +            if ( (memcmp(&old_info[i], &new_info[j], sizeof(xen_disk_t)) == 0) ||
     1.9 +                 (xlvbd_remove_device(old_info[i].device) == 0) )
    1.10 +                memcpy(&merged_info[k++], &old_info[i], sizeof(xen_disk_t));
    1.11 +            else if ( xlvbd_init_device(&new_info[j]) == 0 )
    1.12                  memcpy(&merged_info[k++], &new_info[j], sizeof(xen_disk_t));
    1.13 -            else
    1.14 -                memcpy(&merged_info[k++], &old_info[i], sizeof(xen_disk_t));
    1.15              i++; j++;
    1.16          }
    1.17      }