From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55034) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WHcwJ-0007ww-Kh for qemu-devel@nongnu.org; Sun, 23 Feb 2014 12:34:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WHcwE-0007kd-Mu for qemu-devel@nongnu.org; Sun, 23 Feb 2014 12:34:07 -0500 Received: from s16892447.onlinehome-server.info ([82.165.15.123]:36822) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WHcwE-0007kF-GG for qemu-devel@nongnu.org; Sun, 23 Feb 2014 12:34:02 -0500 Message-ID: <530A3092.8080307@ilande.co.uk> Date: Sun, 23 Feb 2014 17:32:02 +0000 From: Mark Cave-Ayland MIME-Version: 1.0 References: <52C0B576.6060102@caramail.com> <53014600.9030309@caramail.com> In-Reply-To: <53014600.9030309@caramail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] Sun4m: Set HostID in NVRAM List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Olivier Danet Cc: Blue Swirl , qemu-devel , Artyom Tarasenko On 16/02/14 23:13, Olivier Danet wrote: > Ping. > Repost ! > > On 30/12/2013 15:02, Artyom Tarasenko wrote: >> On Mon, Dec 30, 2013 at 12:51 AM, Olivier Danet >> wrote: >>> On SparcStations, the HostID field in the NVRAM is equal to the >>> last three bytes of the MAC address (which is also stored in the NVRAM). >>> >>> This constant is used as an identification/serial number on Solaris. >>> >>> signed-off-by : Olivier Danet >> Corresponds with http://www.squirrel.com/squirrel/sun-nvram-hostid.faq >> and Solaris 9 detects the hostid after this patch fine, so >> >> Reviewed-by: Artyom Tarasenko >> >>> --- >>> include/hw/nvram/openbios_firmware_abi.h | 2 ++ >>> 1 file changed, 2 insertions(+) >>> >>> diff --git a/include/hw/nvram/openbios_firmware_abi.h >>> b/include/hw/nvram/openbios_firmware_abi.h >>> index 5e6e5d4..492c8d5 100644 >>> --- a/include/hw/nvram/openbios_firmware_abi.h >>> +++ b/include/hw/nvram/openbios_firmware_abi.h >>> @@ -62,6 +62,8 @@ Sun_init_header(struct Sun_nvram *header, const >>> uint8_t >>> *macaddr, int machine_id >>> header->type = 1; >>> header->machine_id = machine_id & 0xff; >>> memcpy(&header->macaddr, macaddr, 6); >>> + memcpy(&header->hostid , &macaddr[3],3); >>> + >>> /* Calculate checksum */ >>> tmp = 0; >>> tmpptr = (uint8_t *)header; >>> -- Tested-by: Mark Cave-Ayland I've applied this to my qemu-sparc branch. ATB, Mark.