Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5c8e191e authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/hpa/linux-2.6-x86setup:
  Remove magic macros for screen_info structure members
  [x86] remove uses of magic macros for boot_params access
parents cbfee345 3ea33510
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -78,9 +78,9 @@ static void __init
fixup_cats(struct machine_desc *desc, struct tag *tags,
	   char **cmdline, struct meminfo *mi)
{
	ORIG_VIDEO_LINES  = 25;
	ORIG_VIDEO_POINTS = 16;
	ORIG_Y = 24;
	screen_info.orig_video_lines  = 25;
	screen_info.orig_video_points = 16;
	screen_info.orig_y = 24;
}

MACHINE_START(CATS, "Chalice-CATS")
+1 −0
Original line number Diff line number Diff line
@@ -39,6 +39,7 @@ setup-y += printf.o string.o tty.o video.o version.o voyager.o
setup-y		+= video-vga.o
setup-y		+= video-vesa.o
setup-y		+= video-bios.o

targets		+= $(setup-y)
hostprogs-y	:= tools/build

+12 −7
Original line number Diff line number Diff line
@@ -24,7 +24,7 @@
#include <asm/page.h>
#include <asm/e820.h>
#include <asm/proto.h>
#include <asm/bootsetup.h>
#include <asm/setup.h>
#include <asm/sections.h>

struct e820map e820;
@@ -68,11 +68,16 @@ static inline int bad_addr(unsigned long *addrp, unsigned long size)

	/* initrd */ 
#ifdef CONFIG_BLK_DEV_INITRD
	if (LOADER_TYPE && INITRD_START && last >= INITRD_START && 
	    addr < INITRD_START+INITRD_SIZE) { 
		*addrp = PAGE_ALIGN(INITRD_START + INITRD_SIZE);
	if (boot_params.hdr.type_of_loader && boot_params.hdr.ramdisk_image) {
		unsigned long ramdisk_image = boot_params.hdr.ramdisk_image;
		unsigned long ramdisk_size  = boot_params.hdr.ramdisk_size;
		unsigned long ramdisk_end   = ramdisk_image+ramdisk_size;

		if (last >= ramdisk_image && addr < ramdisk_end) {
			*addrp = PAGE_ALIGN(ramdisk_end);
			return 1;
		}
	} 
#endif
	/* kernel code */
	if (last >= __pa_symbol(&_text) && addr < __pa_symbol(&_end)) {
@@ -594,8 +599,8 @@ void __init setup_memory_region(void)
	 * Otherwise fake a memory map; one section from 0k->640k,
	 * the next section from 1mb->appropriate_mem_k
	 */
	sanitize_e820_map(E820_MAP, &E820_MAP_NR);
	if (copy_e820_map(E820_MAP, E820_MAP_NR) < 0)
	sanitize_e820_map(boot_params.e820_map, &boot_params.e820_entries);
	if (copy_e820_map(boot_params.e820_map, boot_params.e820_entries) < 0)
		early_panic("Cannot find a valid memory map");
	printk(KERN_INFO "BIOS-provided physical RAM map:\n");
	e820_print_map("BIOS-e820");
+5 −10
Original line number Diff line number Diff line
@@ -6,15 +6,10 @@
#include <asm/io.h>
#include <asm/processor.h>
#include <asm/fcntl.h>
#include <asm/setup.h>
#include <xen/hvc-console.h>

/* Simple VGA output */

#ifdef __i386__
#include <asm/setup.h>
#else
#include <asm/bootsetup.h>
#endif
#define VGABASE		(__ISA_IO_base + 0xb8000)

static int max_ypos = 25, max_xpos = 80;
@@ -234,10 +229,10 @@ static int __init setup_early_printk(char *buf)
		early_serial_init(buf);
		early_console = &early_serial_console;
	} else if (!strncmp(buf, "vga", 3)
	           && SCREEN_INFO.orig_video_isVGA == 1) {
		max_xpos = SCREEN_INFO.orig_video_cols;
		max_ypos = SCREEN_INFO.orig_video_lines;
		current_ypos = SCREEN_INFO.orig_y;
	           && boot_params.screen_info.orig_video_isVGA == 1) {
		max_xpos = boot_params.screen_info.orig_video_cols;
		max_ypos = boot_params.screen_info.orig_video_lines;
		current_ypos = boot_params.screen_info.orig_y;
		early_console = &early_vga_console;
 	} else if (!strncmp(buf, "simnow", 6)) {
 		simnow_init(buf + 6);
+9 −6
Original line number Diff line number Diff line
@@ -331,11 +331,13 @@ void __init efi_init(void)
	memset(&efi, 0, sizeof(efi) );
	memset(&efi_phys, 0, sizeof(efi_phys));

	efi_phys.systab = EFI_SYSTAB;
	memmap.phys_map = EFI_MEMMAP;
	memmap.nr_map = EFI_MEMMAP_SIZE/EFI_MEMDESC_SIZE;
	memmap.desc_version = EFI_MEMDESC_VERSION;
	memmap.desc_size = EFI_MEMDESC_SIZE;
	efi_phys.systab =
		(efi_system_table_t *)boot_params.efi_info.efi_systab;
	memmap.phys_map = (void *)boot_params.efi_info.efi_memmap;
	memmap.nr_map = boot_params.efi_info.efi_memmap_size/
		boot_params.efi_info.efi_memdesc_size;
	memmap.desc_version = boot_params.efi_info.efi_memdesc_version;
	memmap.desc_size = boot_params.efi_info.efi_memdesc_size;

	efi.systab = (efi_system_table_t *)
		boot_ioremap((unsigned long) efi_phys.systab,
@@ -446,7 +448,8 @@ void __init efi_init(void)
		printk(KERN_ERR PFX "Could not map the runtime service table!\n");

	/* Map the EFI memory map for use until paging_init() */
	memmap.map = boot_ioremap((unsigned long) EFI_MEMMAP, EFI_MEMMAP_SIZE);
	memmap.map = boot_ioremap(boot_params.efi_info.efi_memmap,
				  boot_params.efi_info.efi_memmap_size);
	if (memmap.map == NULL)
		printk(KERN_ERR PFX "Could not map the EFI memory map!\n");

Loading