Home | History | Annotate | Download | only in common
      1 /* SPDX-License-Identifier: GPL-2.0+ */
      2 /*
      3  * Copyright (c) 2014 Google, Inc
      4  */
      5 
      6 .globl early_board_init
      7 early_board_init:
      8 	/* Enable post codes to EC */
      9 #ifdef CONFIG_EARLY_POST_CROS_EC
     10 	mov    $0x1b, %ecx
     11 	rdmsr
     12 	and    $0x100, %eax
     13 	test   %eax, %eax
     14 	je     1f
     15 
     16 	mov    $0x8000f8f0, %eax
     17 	mov    $0xcf8, %dx
     18 	out    %eax, (%dx)
     19 	mov    $0xfed1c001, %eax
     20 	mov    $0xcfc, %dx
     21 	out    %eax, (%dx)
     22 	mov    $0xfed1f410, %esp
     23 	mov    (%esp), %eax
     24 	and    $0xfffffffb, %eax
     25 	mov    %eax, (%esp)
     26 1:
     27 #endif
     28 	jmp	early_board_init_ret
     29