From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:42898) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Rv8fz-0005lM-SR for qemu-devel@nongnu.org; Wed, 08 Feb 2012 09:39:21 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Rv8fq-00074y-Cf for qemu-devel@nongnu.org; Wed, 08 Feb 2012 09:39:15 -0500 Received: from mail-bk0-f45.google.com ([209.85.214.45]:59325) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Rv8fq-00074c-7P for qemu-devel@nongnu.org; Wed, 08 Feb 2012 09:39:06 -0500 Received: by bkue19 with SMTP id e19so437305bku.4 for ; Wed, 08 Feb 2012 06:39:04 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <201202081420.54442.paul@codesourcery.com> References: <1328687721-16030-1-git-send-email-peter.crosthwaite@petalogix.com> <201202081420.54442.paul@codesourcery.com> Date: Thu, 9 Feb 2012 00:39:04 +1000 Message-ID: From: Peter Crosthwaite Content-Type: multipart/alternative; boundary=000e0cdfc78676f76e04b874db37 Subject: Re: [Qemu-devel] [RFC PATCH] arm boot: added QOM device definition List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paul Brook Cc: peter.maydell@linaro.org, aliguori@us.ibm.com, Alexander Graf , qemu-devel@nongnu.org --000e0cdfc78676f76e04b874db37 Content-Type: text/plain; charset=ISO-8859-1 2012/2/9 Paul Brook > > So if we consider this bootloader a device and its -dtb argument a > property > > of that device, then what you are implying is that every device property > of > > every device in a machine must be managed by the machine model? Isn't the > > dynamic machine model work that is in progress is trying to get away the > > approach where fixed machine models have to micromanage all their > attached > > devices? with the ultimate goal of -no-machine how will the bootloader > get > > this dtb argument? > > My expectation is that we have some way for the machine description to tag > objects/properties that pap to the generic commandline options. In the > same > way that we'd probably want to tag the default PCI bus, or UARTs for > matching > with the -serial commandline. Some of these can be guessed, others you > need > the machine description to tell you. > > Paul > Ok, so it seems that for command line driven arguments the policy is with standard arguments such as -dtb, the machine model must get it on the device behalf and instantiate the device, and that fits in with this patch. Its the other problem I am more worried about, i.e. when I -device instantiate my bootloader with an existing machine how do I get my ram_size and board_ID? The no machine opts for devices policy makes this impossible such that I would have to pass in board_id and ram_size to the boot-loader on the command line. Is there any acceptable way where the machine model can make something globally available to devices for the purpose of instantiating them with -device? --000e0cdfc78676f76e04b874db37 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable

2012/2/9 Paul Brook &l= t;paul@codesourcery.com>
> So if we consider this bootloader a device and its -= dtb argument a property
> of that device, then what you are implying is that every device proper= ty of
> every device in a machine must be managed by the machine model? Isn= 9;t the
> dynamic machine model work that is in progress is trying to get away t= he
> approach where fixed machine models have to micromanage all their atta= ched
> devices? with the ultimate goal of -no-machine how will the bootloader= get
> this dtb argument?

My expectation is that we have some way for the machine description t= o tag
objects/properties that pap to the generic commandline options. =A0In the s= ame
way that we'd probably want to tag the default PCI bus, or UARTs for ma= tching
with the -serial commandline. =A0Some of these can be guessed, others you n= eed
the machine description to tell you.

Paul

Ok, so it seems that for command = line driven arguments the policy is with standard arguments such as -dtb, t= he machine model must get it on the device behalf and instantiate the devic= e, and that fits in with this patch.

Its the other problem I am more worried about, i.e. whe= n I -device instantiate my bootloader with an existing machine how do I get= my ram_size and board_ID? The no machine opts for devices policy makes thi= s impossible such that I would have to pass in board_id and ram_size to the= =A0boot-loader=A0on the command line. Is there any acceptable way where the= machine model can make something globally available to devices for the pur= pose of instantiating them with -device?


--000e0cdfc78676f76e04b874db37--