From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Jan Beulich" Subject: Re: [PATCH V4 07/15] Move x86 specific video and disk probing code Date: Thu, 11 Sep 2014 15:26:22 +0100 Message-ID: <5411CD2E0200007800033F66@mail.emea.novell.com> References: <1410310325-4509-1-git-send-email-roy.franz@linaro.org> <1410310325-4509-8-git-send-email-roy.franz@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1410310325-4509-8-git-send-email-roy.franz@linaro.org> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Roy Franz Cc: keir@xen.org, ian.campbell@citrix.com, tim@xen.org, xen-devel@lists.xen.org, stefano.stabellini@citrix.com, fu.wei@linaro.org List-Id: xen-devel@lists.xenproject.org >>> On 10.09.14 at 02:51, wrote: > @@ -811,189 +785,7 @@ efi_start(EFI_HANDLE ImageHandle, EFI_SYSTEM_TABLE *SystemTable) > cfg.addr = 0; > > dir_handle->Close(dir_handle); > - > - if ( gop && !base_video ) > - { > - for ( i = size = 0; i < gop->Mode->MaxMode; ++i ) > - { > - unsigned int bpp = 0; > - > - status = gop->QueryMode(gop, i, &info_size, &mode_info); > - if ( EFI_ERROR(status) ) > - continue; > - switch ( mode_info->PixelFormat ) > - { > - case PixelBitMask: > - bpp = hweight32(mode_info->PixelInformation.RedMask | > - mode_info->PixelInformation.GreenMask | > - mode_info->PixelInformation.BlueMask); > - break; > - case PixelRedGreenBlueReserved8BitPerColor: > - case PixelBlueGreenRedReserved8BitPerColor: > - bpp = 24; > - break; > - default: > - continue; > - } > - if ( cols == mode_info->HorizontalResolution && > - rows == mode_info->VerticalResolution && > - (!depth || bpp == depth) ) > - { > - gop_mode = i; > - break; > - } > - if ( !cols && !rows && > - mode_info->HorizontalResolution * > - mode_info->VerticalResolution > size ) > - { > - size = mode_info->HorizontalResolution * > - mode_info->VerticalResolution; > - gop_mode = i; > - } > - } > - } This together with ... > @@ -1075,77 +867,7 @@ efi_start(EFI_HANDLE ImageHandle, EFI_SYSTEM_TABLE *SystemTable) > l3_bootmap[l3_table_offset(xen_phys_start + (8 << L2_PAGETABLE_SHIFT) - 1)] = > l3e_from_paddr((UINTN)l2_bootmap, __PAGE_HYPERVISOR); > > - if ( gop ) > - { > - int bpp = 0; > - > - /* Set graphics mode. */ > - if ( gop_mode < gop->Mode->MaxMode && gop_mode != gop->Mode->Mode ) > - gop->SetMode(gop, gop_mode); ... this isn't arch-specific again. Jan