lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 27 Sep 2018 09:07:04 -0700
From:   Randy Dunlap <rdunlap@...radead.org>
To:     xyproto@...hlinux.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Reduce boot header size with 1 byte

On 9/27/18 6:41 AM, xyproto@...hlinux.org wrote:
> From: Alexander F. Rødseth <xyproto@...hlinux.org>
> 
> Only ah needs to be set to 0 before calling interrupt 0x16 for waiting
> for a keypress.
> 
> This patch changes the line that uses xor so that it only zeroes "ah" instead of "ax".
> This saves a byte.
> 
> Signed-off-by: Alexander F. Rødseth <xyproto@...hlinux.org>

Hi,

You should Cc: the X86 maintainers on this patch.
Otherwise it will just be lost in the ether.

thanks.

> ---
>  arch/x86/boot/header.S | 11 ++++++-----
>  1 file changed, 6 insertions(+), 5 deletions(-)
> 
> diff --git a/arch/x86/boot/header.S b/arch/x86/boot/header.S
> index 850b8762e889..905cb96f43d4 100644
> --- a/arch/x86/boot/header.S
> +++ b/arch/x86/boot/header.S
> @@ -71,14 +71,15 @@ msg_loop:
>  	jmp	msg_loop
>  
>  bs_die:
> -	# Allow the user to press a key, then reboot
> -	xorw	%ax, %ax
> +	# Allow the user to press a key
> +	xorb	%ah, %ah
>  	int	$0x16
> +
> +	# Boostrap by reading sector 1, head 0, track 0 from drive
>  	int	$0x19
>  
> -	# int 0x19 should never return.  In case it does anyway,
> -	# invoke the BIOS reset code...
> -	ljmp	$0xf000,$0xfff0
> +	# If boostrap somehow did not work, invoke the BIOS reset code
> +	ljmp	$0xf000, $0xfff0
>  
>  #ifdef CONFIG_EFI_STUB
>  	.org	0x3c
> 


-- 
~Randy

Powered by blists - more mailing lists