From: Amos Kong <akong@redhat.com>
To: seabios@seabios.org
Cc: pbonzini@redhat.com, kevin@koconnor.net, qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH] boot: fix path pattern of scsi device
Date: Tue, 28 May 2013 15:40:06 +0800 [thread overview]
Message-ID: <1369726806-9715-1-git-send-email-akong@redhat.com> (raw)
bootindex parameter of scsi device doesn't work, it causes
by wrong pattern in seabios.
qemu passes the following firmware dev_path to seabios:
/pci@i0cf8/scsi@4/virtio-scsi-device/channel@0/disk@0,0
Signed-off-by: Amos Kong <akong@redhat.com>
---
src/boot.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/boot.c b/src/boot.c
index c308602..cd9d784 100644
--- a/src/boot.c
+++ b/src/boot.c
@@ -138,10 +138,11 @@ int bootprio_find_scsi_device(struct pci_device *pci, int target, int lun)
if (!pci)
// support only pci machine for now
return -1;
- // Find scsi drive - for example: /pci@i0cf8/scsi@5/channel@0/disk@1,0
+ /* Find scsi drive - for example:
+ /pci@i0cf8/scsi@5/virtio-scsi-device/channel@0/disk@1,0 */
char desc[256], *p;
p = build_pci_path(desc, sizeof(desc), "*", pci);
- snprintf(p, desc+sizeof(desc)-p, "/*@0/*@%d,%d", target, lun);
+ snprintf(p, desc+sizeof(desc)-p, "/*/*@0/*@%d,%d", target, lun);
return find_prio(desc);
}
--
1.8.1.4
next reply other threads:[~2013-05-28 7:40 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-28 7:40 Amos Kong [this message]
2013-05-28 8:06 ` [Qemu-devel] [PATCH] boot: fix path pattern of scsi device Paolo Bonzini
2013-05-28 9:35 ` Amos Kong
2013-05-28 9:45 ` Paolo Bonzini
2013-05-28 10:26 ` Laszlo Ersek
2013-05-28 10:31 ` Amos Kong
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=1369726806-9715-1-git-send-email-akong@redhat.com \
--to=akong@redhat.com \
--cc=kevin@koconnor.net \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=seabios@seabios.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).