[PATCHv2,1/2] Add bootindex handling into usb storage device.

Submitted by Gleb Natapov on Jan. 30, 2011, 10:29 a.m.

Details

Message ID 1296383359-19082-1-git-send-email-gleb@redhat.com
State New
Headers show

Commit Message

Gleb Natapov Jan. 30, 2011, 10:29 a.m.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
---
 hw/usb-msd.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

Comments

Markus Armbruster Jan. 31, 2011, 8:20 a.m.
Both patches look fine to me.

Patch hide | download patch | download mbox

diff --git a/hw/usb-msd.c b/hw/usb-msd.c
index 11722c7..d9df4f2 100644
--- a/hw/usb-msd.c
+++ b/hw/usb-msd.c
@@ -532,6 +532,7 @@  static int usb_msd_initfn(USBDevice *dev)
         }
     }
 
+    add_boot_device_path(s->conf.bootindex, &dev->qdev, "/disk@0,0");
     return 0;
 }
 
@@ -596,6 +597,7 @@  static USBDevice *usb_msd_init(const char *filename)
 static struct USBDeviceInfo msd_info = {
     .product_desc   = "QEMU USB MSD",
     .qdev.name      = "usb-storage",
+    .qdev.fw_name      = "storage",
     .qdev.size      = sizeof(MSDState),
     .usb_desc       = &desc,
     .init           = usb_msd_initfn,