Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-19 Thread Kevin O'Connor
On Tue, Nov 16, 2010 at 09:22:45AM +0200, Gleb Natapov wrote: On Mon, Nov 15, 2010 at 09:52:19PM -0500, Kevin O'Connor wrote: I also have an ulterior motive here. If the boot order is exposed as a newline separated list via an entry in QEMU_CFG_FILE_DIR, then this becomes free for coreboot

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-19 Thread Gleb Natapov
On Mon, Nov 15, 2010 at 08:29:24PM +, Blue Swirl wrote: 2010/11/15 Gleb Natapov g...@redhat.com: On Sun, Nov 14, 2010 at 10:50:13PM +, Blue Swirl wrote: On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by: Gleb Natapov g...@redhat.com ---  

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Gleb Natapov
On Wed, Nov 17, 2010 at 09:54:27PM +, Blue Swirl wrote: 2010/11/16 Gleb Natapov g...@redhat.com: On Tue, Nov 16, 2010 at 06:30:19PM +, Blue Swirl wrote: Perhaps the FW path should use device class names if no name is specified. What do you mean by device class name. We can do

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Michael S. Tsirkin
On Thu, Nov 18, 2010 at 12:18:27PM +0200, Gleb Natapov wrote: On Wed, Nov 17, 2010 at 09:54:27PM +, Blue Swirl wrote: 2010/11/16 Gleb Natapov g...@redhat.com: On Tue, Nov 16, 2010 at 06:30:19PM +, Blue Swirl wrote: Perhaps the FW path should use device class names if no name is

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Gleb Natapov
On Thu, Nov 18, 2010 at 01:38:31PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 12:18:27PM +0200, Gleb Natapov wrote: On Wed, Nov 17, 2010 at 09:54:27PM +, Blue Swirl wrote: 2010/11/16 Gleb Natapov g...@redhat.com: On Tue, Nov 16, 2010 at 06:30:19PM +, Blue Swirl

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Michael S. Tsirkin
On Thu, Nov 18, 2010 at 01:45:04PM +0200, Gleb Natapov wrote: On Thu, Nov 18, 2010 at 01:38:31PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 12:18:27PM +0200, Gleb Natapov wrote: On Wed, Nov 17, 2010 at 09:54:27PM +, Blue Swirl wrote: 2010/11/16 Gleb Natapov

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Gleb Natapov
On Thu, Nov 18, 2010 at 01:52:30PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 01:45:04PM +0200, Gleb Natapov wrote: On Thu, Nov 18, 2010 at 01:38:31PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 12:18:27PM +0200, Gleb Natapov wrote: On Wed, Nov 17, 2010 at

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Michael S. Tsirkin
On Thu, Nov 18, 2010 at 02:16:05PM +0200, Gleb Natapov wrote: On Thu, Nov 18, 2010 at 01:52:30PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 01:45:04PM +0200, Gleb Natapov wrote: On Thu, Nov 18, 2010 at 01:38:31PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Gleb Natapov
On Thu, Nov 18, 2010 at 02:23:20PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 02:16:05PM +0200, Gleb Natapov wrote: On Thu, Nov 18, 2010 at 01:52:30PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 01:45:04PM +0200, Gleb Natapov wrote: On Thu, Nov 18, 2010 at

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Michael S. Tsirkin
On Thu, Nov 18, 2010 at 02:37:08PM +0200, Gleb Natapov wrote: So that's unavoidable if we think paths are correct. But if we know they are wrong, we are better off correcting them first IMO. They are correct for x86. My patch set does not even tries to cover all HW. If sparc want to use

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-18 Thread Gleb Natapov
On Thu, Nov 18, 2010 at 03:12:02PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 02:37:08PM +0200, Gleb Natapov wrote: So that's unavoidable if we think paths are correct. But if we know they are wrong, we are better off correcting them first IMO. They are correct for

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-17 Thread Blue Swirl
2010/11/16 Gleb Natapov g...@redhat.com: On Tue, Nov 16, 2010 at 06:30:19PM +, Blue Swirl wrote: Perhaps the FW path should use device class names if no name is specified. What do you mean by device class name. We can do something like this: if (dev-child_bus.lh_first)        return

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-16 Thread Blue Swirl
On Tue, Nov 16, 2010 at 7:22 AM, Gleb Natapov g...@redhat.com wrote: On Mon, Nov 15, 2010 at 09:52:19PM -0500, Kevin O'Connor wrote: On Mon, Nov 15, 2010 at 03:36:25PM +0200, Gleb Natapov wrote: On Mon, Nov 15, 2010 at 08:26:35AM -0500, Kevin O'Connor wrote: On Mon, Nov 15, 2010 at

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-16 Thread Blue Swirl
2010/11/16 Gleb Natapov g...@redhat.com: On Mon, Nov 15, 2010 at 08:29:24PM +, Blue Swirl wrote: 2010/11/15 Gleb Natapov g...@redhat.com: On Sun, Nov 14, 2010 at 10:50:13PM +, Blue Swirl wrote: On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by:

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-16 Thread Gleb Natapov
On Tue, Nov 16, 2010 at 06:30:19PM +, Blue Swirl wrote: Perhaps the FW path should use device class names if no name is specified. What do you mean by device class name. We can do something like this: if (dev-child_bus.lh_first)        return dev-child_bus.lh_first-info-name; i.e

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-15 Thread Gleb Natapov
On Mon, Nov 15, 2010 at 09:53:50AM +0200, Michael S. Tsirkin wrote: On Mon, Nov 15, 2010 at 09:40:08AM +0200, Gleb Natapov wrote: On Sun, Nov 14, 2010 at 10:40:33PM -0500, Kevin O'Connor wrote: On Sun, Nov 14, 2010 at 05:39:41PM +0200, Gleb Natapov wrote: +/* + * This function

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-15 Thread Gleb Natapov
On Sun, Nov 14, 2010 at 10:50:13PM +, Blue Swirl wrote: On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by: Gleb Natapov g...@redhat.com ---  hw/fw_cfg.c |   14 ++  hw/fw_cfg.h |    4 +++-  sysemu.h    |    1 +  vl.c        |   51

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-15 Thread Kevin O'Connor
On Mon, Nov 15, 2010 at 09:40:08AM +0200, Gleb Natapov wrote: On Sun, Nov 14, 2010 at 10:40:33PM -0500, Kevin O'Connor wrote: Why not just return a newline separated list that is null terminated? Doing it like this will needlessly complicate firmware side. How do you know how much memory

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-15 Thread Gleb Natapov
On Mon, Nov 15, 2010 at 08:26:35AM -0500, Kevin O'Connor wrote: On Mon, Nov 15, 2010 at 09:40:08AM +0200, Gleb Natapov wrote: On Sun, Nov 14, 2010 at 10:40:33PM -0500, Kevin O'Connor wrote: Why not just return a newline separated list that is null terminated? Doing it like this will

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-15 Thread Gleb Natapov
On Mon, Nov 15, 2010 at 03:36:25PM +0200, Gleb Natapov wrote: Hmm BTW I do not see proper endianness handling in FILE_DIR. That's just me. Everything it OK there with endianness. -- Gleb. -- To unsubscribe from this list: send the line

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-15 Thread Blue Swirl
2010/11/15 Gleb Natapov g...@redhat.com: On Sun, Nov 14, 2010 at 10:50:13PM +, Blue Swirl wrote: On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by: Gleb Natapov g...@redhat.com ---  hw/fw_cfg.c |   14 ++  hw/fw_cfg.h |    4 +++-  

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-15 Thread Kevin O'Connor
On Mon, Nov 15, 2010 at 03:36:25PM +0200, Gleb Natapov wrote: On Mon, Nov 15, 2010 at 08:26:35AM -0500, Kevin O'Connor wrote: On Mon, Nov 15, 2010 at 09:40:08AM +0200, Gleb Natapov wrote: On Sun, Nov 14, 2010 at 10:40:33PM -0500, Kevin O'Connor wrote: Why not just return a newline

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-15 Thread Gleb Natapov
On Mon, Nov 15, 2010 at 09:52:19PM -0500, Kevin O'Connor wrote: On Mon, Nov 15, 2010 at 03:36:25PM +0200, Gleb Natapov wrote: On Mon, Nov 15, 2010 at 08:26:35AM -0500, Kevin O'Connor wrote: On Mon, Nov 15, 2010 at 09:40:08AM +0200, Gleb Natapov wrote: On Sun, Nov 14, 2010 at 10:40:33PM

[PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Gleb Natapov
Signed-off-by: Gleb Natapov g...@redhat.com --- hw/fw_cfg.c | 14 ++ hw/fw_cfg.h |4 +++- sysemu.h|1 + vl.c| 51 +++ 4 files changed, 69 insertions(+), 1 deletions(-) diff --git a/hw/fw_cfg.c b/hw/fw_cfg.c

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Michael S. Tsirkin
On Sun, Nov 14, 2010 at 05:39:41PM +0200, Gleb Natapov wrote: Signed-off-by: Gleb Natapov g...@redhat.com --- hw/fw_cfg.c | 14 ++ hw/fw_cfg.h |4 +++- sysemu.h|1 + vl.c| 51 +++ 4 files changed, 69

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Gleb Natapov
On Sun, Nov 14, 2010 at 08:41:37PM +0200, Michael S. Tsirkin wrote: On Sun, Nov 14, 2010 at 05:39:41PM +0200, Gleb Natapov wrote: Signed-off-by: Gleb Natapov g...@redhat.com --- hw/fw_cfg.c | 14 ++ hw/fw_cfg.h |4 +++- sysemu.h|1 + vl.c| 51

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Blue Swirl
On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by: Gleb Natapov g...@redhat.com ---  hw/fw_cfg.c |   14 ++  hw/fw_cfg.h |    4 +++-  sysemu.h    |    1 +  vl.c        |   51 +++  4 files changed,

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Michael S. Tsirkin
On Sun, Nov 14, 2010 at 08:49:59PM +, Blue Swirl wrote: On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by: Gleb Natapov g...@redhat.com ---  hw/fw_cfg.c |   14 ++  hw/fw_cfg.h |    4 +++-  sysemu.h    |    1 +  vl.c        |   51

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Michael S. Tsirkin
On Sun, Nov 14, 2010 at 08:52:37PM +0200, Gleb Natapov wrote: On Sun, Nov 14, 2010 at 08:41:37PM +0200, Michael S. Tsirkin wrote: On Sun, Nov 14, 2010 at 05:39:41PM +0200, Gleb Natapov wrote: Signed-off-by: Gleb Natapov g...@redhat.com --- hw/fw_cfg.c | 14 ++

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Michael S. Tsirkin
On Sun, Nov 14, 2010 at 08:52:37PM +0200, Gleb Natapov wrote: + +len = strlen(bootpath); +list = qemu_realloc(list, total + len + 1); +list[total++] = len; +memcpy(list[total], bootpath, len); +total += len; +c++; +

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Blue Swirl
On Sun, Nov 14, 2010 at 8:54 PM, Michael S. Tsirkin m...@redhat.com wrote: On Sun, Nov 14, 2010 at 08:49:59PM +, Blue Swirl wrote: On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by: Gleb Natapov g...@redhat.com ---  hw/fw_cfg.c |   14 ++

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Michael S. Tsirkin
On Sun, Nov 14, 2010 at 09:13:03PM +, Blue Swirl wrote: On Sun, Nov 14, 2010 at 8:54 PM, Michael S. Tsirkin m...@redhat.com wrote: On Sun, Nov 14, 2010 at 08:49:59PM +, Blue Swirl wrote: On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by: Gleb

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Blue Swirl
On Sun, Nov 14, 2010 at 3:39 PM, Gleb Natapov g...@redhat.com wrote: Signed-off-by: Gleb Natapov g...@redhat.com ---  hw/fw_cfg.c |   14 ++  hw/fw_cfg.h |    4 +++-  sysemu.h    |    1 +  vl.c        |   51 +++  4 files changed,

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Kevin O'Connor
On Sun, Nov 14, 2010 at 05:39:41PM +0200, Gleb Natapov wrote: +/* + * This function returns device list as an array in a below format: + * +-+-+---+-+---+-- + * | n | l1 | devpath1| l2 | devpath2 | ... + *

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-14 Thread Michael S. Tsirkin
On Mon, Nov 15, 2010 at 09:40:08AM +0200, Gleb Natapov wrote: On Sun, Nov 14, 2010 at 10:40:33PM -0500, Kevin O'Connor wrote: On Sun, Nov 14, 2010 at 05:39:41PM +0200, Gleb Natapov wrote: +/* + * This function returns device list as an array in a below format: + *