From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=40019 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q6lAy-0006nm-Oo for qemu-devel@nongnu.org; Mon, 04 Apr 2011 10:56:38 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q6lAb-0007vh-Kd for qemu-devel@nongnu.org; Mon, 04 Apr 2011 10:54:22 -0400 Received: from e2.ny.us.ibm.com ([32.97.182.142]:35822) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q6lAb-0007vc-Gy for qemu-devel@nongnu.org; Mon, 04 Apr 2011 10:54:21 -0400 Received: from d01dlp01.pok.ibm.com (d01dlp01.pok.ibm.com [9.56.224.56]) by e2.ny.us.ibm.com (8.14.4/8.13.1) with ESMTP id p34EZLgg024383 for ; Mon, 4 Apr 2011 10:35:21 -0400 Received: from d01relay05.pok.ibm.com (d01relay05.pok.ibm.com [9.56.227.237]) by d01dlp01.pok.ibm.com (Postfix) with ESMTP id ADC6B38C8039 for ; Mon, 4 Apr 2011 10:54:12 -0400 (EDT) Received: from d01av04.pok.ibm.com (d01av04.pok.ibm.com [9.56.224.64]) by d01relay05.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id p34EsKWn211212 for ; Mon, 4 Apr 2011 10:54:20 -0400 Received: from d01av04.pok.ibm.com (loopback [127.0.0.1]) by d01av04.pok.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id p34EsKLE001659 for ; Mon, 4 Apr 2011 10:54:20 -0400 Message-ID: <4D99DB9B.9010306@linux.vnet.ibm.com> Date: Mon, 04 Apr 2011 10:54:19 -0400 From: Stefan Berger MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH V1 5/8] Support for BIOS interrupt handler References: <20110330175534.302129463@linux.vnet.ibm.com> <20110330175559.600480223@linux.vnet.ibm.com> <20110404043039.GC13528@morn.localdomain> In-Reply-To: <20110404043039.GC13528@morn.localdomain> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin O'Connor Cc: seabios@seabios.org, qemu-devel@nongnu.org On 04/04/2011 12:30 AM, Kevin O'Connor wrote: > On Wed, Mar 30, 2011 at 01:55:39PM -0400, Stefan Berger wrote: >> This patch implements the TCG BIOS interrupt handler 1ah. It is for >> example used by trusted grub. > [...] >> +/******************************************************************* >> + Calculation of SHA1 in SW >> + >> + See: http://www.itl.nist.gov/fipspubs/fip180-1.htm >> + RFC3174, Wikipedia's SHA1 alogrithm description >> + ******************************************************************/ > Looks like tcgbios.c is awfully big - can we move the sha1 code to > it's own file (eg, sha1.c)? Done. > [...] >> +static inline u32 rol(u32 val, u16 rol) > Should move to util.h. Done. >> +static inline u64 bswap_64(u64 val) > Same. Done. > [...] >> +++ seabios/src/stacks.c > [...] >> +#ifdef CONFIG_TCGBIOS >> +void tcpa_interrupt_handler16(struct bregs *regs) >> +{ >> + if (MODESEGMENT) { > I'm a bit confused here - MODESEGMENT will always be true. Also, this > code doesn't need to be in stacks.c - just invoke call32() directly > from handle_1abb(). > Will adapt it to that. Other code was checking the MODESEGMENT and so I thought I better do that, too. > Also, as before, just do "if (!CONFIG_TCGBIOS) return;" instead of the > #ifdef. > Did that. Stefan > -Kevin