亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? asmstub.c

?? GRUB 0.93的源代碼。有人說可以當一個很小的操作系統了
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* asmstub.c - a version of shared_src/asm.S that works under Unix *//* *  GRUB  --  GRand Unified Bootloader *  Copyright (C) 1999,2000,2001,2002  Free Software Foundation, Inc. * *  This program is free software; you can redistribute it and/or modify *  it under the terms of the GNU General Public License as published by *  the Free Software Foundation; either version 2 of the License, or *  (at your option) any later version. * *  This program is distributed in the hope that it will be useful, *  but WITHOUT ANY WARRANTY; without even the implied warranty of *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the *  GNU General Public License for more details. * *  You should have received a copy of the GNU General Public License *  along with this program; if not, write to the Free Software *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. *//* Try to use glibc's transparant LFS support. */#define _LARGEFILE_SOURCE	1/* lseek becomes synonymous with lseek64.  */#define _FILE_OFFSET_BITS	64/* Simulator entry point. */int grub_stage2 (void);#include <stdlib.h>#include <string.h>#include <ctype.h>#include <assert.h>#include <stdio.h>#include <sys/types.h>#include <sys/stat.h>#include <fcntl.h>#include <time.h>#include <errno.h>#include <string.h>#include <unistd.h>#include <setjmp.h>#include <sys/time.h>#include <termios.h>#include <signal.h>#ifdef __linux__# include <sys/ioctl.h>		/* ioctl */# if !defined(__GLIBC__) || \	((__GLIBC__ < 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ < 1)))/* Maybe libc doesn't have large file support.  */#  include <linux/unistd.h>	/* _llseek */# endif /* (GLIBC < 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR < 1)) */# ifndef BLKFLSBUF#  define BLKFLSBUF	_IO (0x12,97)	/* flush buffer cache */# endif /* ! BLKFLSBUF */#endif /* __linux__ *//* We want to prevent any circularararity in our stubs, as well as   libc name clashes. */#define WITHOUT_LIBC_STUBS 1#include <shared.h>#include <device.h>#include <serial.h>#include <term.h>/* Simulated memory sizes. */#define EXTENDED_MEMSIZE (3 * 1024 * 1024)	/* 3MB */#define CONVENTIONAL_MEMSIZE (640 * 1024)	/* 640kB */unsigned long install_partition = 0x20000;unsigned long boot_drive = 0;int saved_entryno = 0;char version_string[] = VERSION;char config_file[128] = "/boot/grub/menu.lst"; /* FIXME: arbitrary */unsigned long linux_text_len = 0;char *linux_data_tmp_addr = 0;char *linux_data_real_addr = 0;unsigned short io_map[IO_MAP_SIZE];struct apm_info apm_bios_info;/* Emulation requirements. */char *grub_scratch_mem = 0;struct geometry *disks = 0;/* The map between BIOS drives and UNIX device file names.  */char **device_map = 0;/* The jump buffer for exiting correctly.  */static jmp_buf env_for_exit;/* The current color for console.  */static int console_current_color = A_NORMAL;/* The file descriptor for a serial device.  */static int serial_fd = -1;/* The file name of a serial device.  */static char *serial_device = 0;#ifdef SIMULATE_SLOWNESS_OF_SERIAL/* The speed of a serial device.  */static unsigned int serial_speed;#endif /* SIMULATE_SLOWNESS_OF_SERIAL *//* The main entry point into this mess. */intgrub_stage2 (void){  /* These need to be static, because they survive our stack transitions. */  static int status = 0;  static char *realstack;  char *scratch, *simstack;  int i;  /* We need a nested function so that we get a clean stack frame,     regardless of how the code is optimized. */  static volatile void doit ()  {    /* Make sure our stack lives in the simulated memory area. */    asm volatile ("movl %%esp, %0\n\tmovl %1, %%esp\n"		  : "=&r" (realstack) : "r" (simstack));    /* Do a setjmp here for the stop command.  */    if (! setjmp (env_for_exit))      {	/* Actually enter the generic stage2 code.  */	status = 0;	init_bios_info ();      }    else      {	/* If ERRNUM is non-zero, then set STATUS to non-zero.  */	if (errnum)	  status = 1;      }    /* Replace our stack before we use any local variables. */    asm volatile ("movl %0, %%esp\n" : : "r" (realstack));  }  assert (grub_scratch_mem == 0);  scratch = malloc (0x100000 + EXTENDED_MEMSIZE + 15);  assert (scratch);  grub_scratch_mem = (char *) ((((int) scratch) >> 4) << 4);  /* FIXME: simulate the memory holes using mprot, if available. */  assert (disks == 0);  disks = malloc (NUM_DISKS * sizeof (*disks));  assert (disks);  /* Initialize DISKS.  */  for (i = 0; i < NUM_DISKS; i++)    disks[i].flags = -1;  if (! init_device_map (&device_map, device_map_file, floppy_disks))    return 1;    /* Check some invariants. */  assert ((SCRATCHSEG << 4) == SCRATCHADDR);  assert ((BUFFERSEG << 4) == BUFFERADDR);  assert (BUFFERADDR + BUFFERLEN == SCRATCHADDR);  assert (FSYS_BUF % 16 == 0);  assert (FSYS_BUF + FSYS_BUFLEN == BUFFERADDR);#ifdef HAVE_LIBCURSES  /* Get into char-at-a-time mode. */  if (use_curses)    {      initscr ();      cbreak ();      noecho ();      nonl ();      scrollok (stdscr, TRUE);      keypad (stdscr, TRUE);      wtimeout (stdscr, 100);      signal (SIGWINCH, SIG_IGN);    }#endif  /* Make sure that actual writing is done.  */  sync ();  /* Set our stack, and go for it. */  simstack = (char *) PROTSTACKINIT;  doit ();  /* I don't know if this is necessary really.  */  sync ();#ifdef HAVE_LIBCURSES  if (use_curses)    endwin ();#endif  /* Close off the file descriptors we used. */  for (i = 0; i < NUM_DISKS; i ++)    if (disks[i].flags != -1)      {#ifdef __linux__	/* In Linux, invalidate the buffer cache. In other OSes, reboot	   is one of the solutions...  */	ioctl (disks[i].flags, BLKFLSBUF, 0);#else# warning "In your operating system, the buffer cache will not be flushed."#endif	close (disks[i].flags);      }  if (serial_fd >= 0)    close (serial_fd);    /* Release memory. */  restore_device_map (device_map);  device_map = 0;  free (disks);  disks = 0;  free (scratch);  grub_scratch_mem = 0;  if (serial_device)    free (serial_device);  serial_device = 0;    /* Ahh... at last we're ready to return to caller. */  return status;}/* Assign DRIVE to a device name DEVICE.  */voidassign_device_name (int drive, const char *device){  /* If DRIVE is already assigned, free it.  */  if (device_map[drive])    free (device_map[drive]);  /* If the old one is already opened, close it.  */  if (disks[drive].flags != -1)    {      close (disks[drive].flags);      disks[drive].flags = -1;    }  /* Assign DRIVE to DEVICE.  */  if (! device)    device_map[drive] = 0;  else    device_map[drive] = strdup (device);}voidstop (void){#ifdef HAVE_LIBCURSES  if (use_curses)    endwin ();#endif  /* Jump to doit.  */  longjmp (env_for_exit, 1);}voidgrub_reboot (void){  stop ();}voidgrub_halt (int no_apm){  stop ();}/* calls for direct boot-loader chaining */voidchain_stage1 (unsigned long segment, unsigned long offset,	      unsigned long part_table_addr){  stop ();}voidchain_stage2 (unsigned long segment, unsigned long offset, int second_sector){  stop ();}/* do some funky stuff, then boot linux */voidlinux_boot (void){  stop ();}/* For bzImage kernels. */voidbig_linux_boot (void){  stop ();}/* booting a multiboot executable */voidmulti_boot (int start, int mb_info){  stop ();}/* sets it to linear or wired A20 operation */voidgateA20 (int linear){  /* Nothing to do in the simulator. */}/* Set up the int15 handler.  */voidset_int15_handler (void){  /* Nothing to do in the simulator.  */}/* Restore the original int15 handler.  */voidunset_int15_handler (void){  /* Nothing to do in the simulator.  */}/* The key map.  */unsigned short bios_key_map[KEY_MAP_SIZE + 1];unsigned short ascii_key_map[KEY_MAP_SIZE + 1];/* Copy MAP to the drive map and set up the int13 handler.  */voidset_int13_handler (unsigned short *map){  /* Nothing to do in the simulator.  */}intget_code_end (void){  /* Just return a little area for simulation. */  return BOOTSEC_LOCATION + (60 * 1024);}/* memory probe routines */intget_memsize (int type){  if (! type)    return CONVENTIONAL_MEMSIZE >> 10;  else    return EXTENDED_MEMSIZE >> 10;}/* get_eisamemsize() :  return packed EISA memory map, lower 16 bits is *		memory between 1M and 16M in 1K parts, upper 16 bits is *		memory above 16M in 64K parts.  If error, return -1. */intget_eisamemsize (void){  return (EXTENDED_MEMSIZE >> 10);}#define MMAR_DESC_TYPE_AVAILABLE 1 /* available to OS */#define MMAR_DESC_TYPE_RESERVED 2 /* not available */#define MMAR_DESC_TYPE_ACPI_RECLAIM 3 /* usable by OS after reading ACPI */#define MMAR_DESC_TYPE_ACPI_NVS 4 /* required to save between NVS sessions */#define MMAR_DESC_LENGTH	20/* Fetch the next entry in the memory map and return the continuation   value.  DESC is a pointer to the descriptor buffer, and CONT is the   previous continuation value (0 to get the first entry in the   map).  */intget_mmap_entry (struct mmar_desc *desc, int cont){  /* Record the memory map statically.  */  static struct mmar_desc desc_table[] =  {    /* The conventional memory.  */    {      MMAR_DESC_LENGTH,      0,      CONVENTIONAL_MEMSIZE,      MMAR_DESC_TYPE_AVAILABLE    },    /* BIOS RAM and ROM (such as video memory).  */    {      MMAR_DESC_LENGTH,      CONVENTIONAL_MEMSIZE,      0x100000 - CONVENTIONAL_MEMSIZE,      MMAR_DESC_TYPE_RESERVED    },    /* The extended memory.  */    {      MMAR_DESC_LENGTH,      0x100000,      EXTENDED_MEMSIZE,      MMAR_DESC_TYPE_AVAILABLE    }  };    int num = sizeof (desc_table) / sizeof (*desc_table);  if (cont < 0 || cont >= num)    {      /* Should not happen.  */      desc->desc_len = 0;    }  else    {      /* Copy the entry.  */      *desc = desc_table[cont++];      /* If the next entry exists, return the index.  */      if (cont < num)	return cont;    }    return 0;}/* Track the int13 handler.  */voidtrack_int13 (int drive){  /* Nothing to do in the simulator.  */}/* Get the ROM configuration table.  */unsigned longget_rom_config_table (void){  return 0;}/* Get APM BIOS information.  */voidget_apm_info (void){  /* Nothing to do in the simulator.  */}/* Get VBE controller information.  */intget_vbe_controller_info (struct vbe_controller *controller){  /* Always fails.  */  return 0;}/* Get VBE mode information.  */intget_vbe_mode_info (int mode_number, struct vbe_mode *mode){  /* Always fails.  */  return 0;}/* Set VBE mode.  */intset_vbe_mode (int mode_number){  /* Always fails.  */  return 0;}/* low-level timing info */intgetrtsecs (void){  /* FIXME: exact value is not important, so just return time_t for now. */  return time (0);}intcurrticks (void){  struct timeval tv;  long csecs;  int ticks_per_csec, ticks_per_usec;  /* Note: 18.2 ticks/sec.  */  /* Get current time.  */  gettimeofday (&tv, 0);  /* Compute centiseconds.  */  csecs = tv.tv_sec / 10;  /* Ticks per centisecond.  */  ticks_per_csec = csecs * 182;  /* Ticks per microsecond.  */  ticks_per_usec = (((tv.tv_sec - csecs * 10) * 1000000 + tv.tv_usec)		    * 182 / 10000000);  /* Sum them.  */  return ticks_per_csec + ticks_per_usec;}/* displays an ASCII character.  IBM displays will translate some   characters to special graphical ones */voidconsole_putchar (int c){  /* Curses doesn't have VGA fonts.  */  switch (c)    {    case DISP_UL:      c = ACS_ULCORNER;      break;    case DISP_UR:      c = ACS_URCORNER;      break;    case DISP_LL:      c = ACS_LLCORNER;      break;    case DISP_LR:      c = ACS_LRCORNER;      break;    case DISP_HORIZ:      c = ACS_HLINE;      break;    case DISP_VERT:      c = ACS_VLINE;      break;    case DISP_LEFT:      c = ACS_LARROW;      break;    case DISP_RIGHT:      c = ACS_RARROW;      break;    case DISP_UP:      c = ACS_UARROW;      break;    case DISP_DOWN:      c = ACS_DARROW;      break;    default:      break;    }#ifdef HAVE_LIBCURSES  if (use_curses)    {      /* In ncurses, a newline is treated badly, so we emulate it in our	 own way.  */      if (c == '\n')	{	  int x, y;	  getyx (stdscr, y, x);	  if (y + 1 == LINES)	    scroll (stdscr);	  else	    move (y + 1, x);	}      else if (isprint (c))	{	  int x, y;	  getyx (stdscr, y, x);	  if (x + 1 == COLS)	    {	      console_putchar ('\r');	      console_putchar ('\n');	    }	  addch (c | console_current_color);	}      else	{	  addch (c);	}      #ifdef REFRESH_IMMEDIATELY      refresh ();#endif    }  else#endif    {      /* CR is not used in Unix.  */      if (c != '\r')	putchar (c);    }}/* The store for ungetch simulation. This is necessary, because   ncurses-1.9.9g is still used in the world and its ungetch is   completely broken.  */#ifdef HAVE_LIBCURSESstatic int save_char = ERR;#endifstatic intconsole_translate_key (int c){  switch (c)    {    case KEY_LEFT:      return 2;    case KEY_RIGHT:      return 6;    case KEY_UP:      return 16;    case KEY_DOWN:      return 14;    case KEY_DC:      return 4;    case KEY_BACKSPACE:      return 8;    case KEY_HOME:      return 1;    case KEY_END:      return 5;    case KEY_PPAGE:      return 7;    case KEY_NPAGE:      return 3;    default:      break;    }

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品美女久久久久久久网站| 欧美性猛交xxxx乱大交退制版| 欧美亚洲国产一区二区三区va| 亚洲欧美自拍偷拍| 99国产精品99久久久久久| 国产蜜臀97一区二区三区| 91啪九色porn原创视频在线观看| 国产精品狼人久久影院观看方式| 成人av电影在线播放| 亚洲人成亚洲人成在线观看图片| 国产亚洲欧美日韩俺去了| 粉嫩在线一区二区三区视频| 亚洲欧洲日产国码二区| 欧洲中文字幕精品| 美女在线观看视频一区二区| 欧美激情在线一区二区三区| 99亚偷拍自图区亚洲| 一区二区三区中文在线观看| 欧美精品xxxxbbbb| 国产精品性做久久久久久| 国产精品传媒入口麻豆| 欧美日韩一区二区三区免费看| 美女视频一区二区| 国产精品素人视频| 欧美日韩高清一区二区三区| 久草中文综合在线| 亚洲天堂av一区| 欧美一级欧美三级在线观看| 国产精品1区二区.| 亚洲一区精品在线| 久久久精品蜜桃| 色婷婷激情综合| 黄页视频在线91| 亚洲综合色自拍一区| 久久品道一品道久久精品| 色噜噜久久综合| 男女男精品网站| 中文字幕在线免费不卡| 91精品国产综合久久精品app | 亚洲一区二区3| 91精品国产福利在线观看| 国产老女人精品毛片久久| 亚洲国产美国国产综合一区二区| 久久综合久色欧美综合狠狠| 欧美日韩专区在线| 丁香亚洲综合激情啪啪综合| 日本成人中文字幕| 亚洲综合激情网| 亚洲国产精品成人综合| 日韩亚洲欧美成人一区| 91福利视频久久久久| 国产伦精一区二区三区| 亚洲一区在线播放| 亚洲人成小说网站色在线| 久久久影视传媒| 91精品国产一区二区| 色综合激情五月| 成人自拍视频在线观看| 麻豆精品视频在线观看视频| 亚洲影院在线观看| 中文字幕亚洲一区二区av在线| 欧美大黄免费观看| 欧美三级日韩在线| 成人小视频免费在线观看| 老司机免费视频一区二区三区| 一区二区三区成人| 亚洲欧美日韩精品久久久久| 欧美激情艳妇裸体舞| 2021中文字幕一区亚洲| 91精品国产一区二区三区蜜臀| 欧美吻胸吃奶大尺度电影| 9i在线看片成人免费| 91丨porny丨蝌蚪视频| 岛国精品在线播放| 成人黄页毛片网站| 不卡在线视频中文字幕| 成人精品在线视频观看| 成人永久aaa| 岛国一区二区三区| bt欧美亚洲午夜电影天堂| 国产麻豆精品视频| 国产精品亚洲一区二区三区妖精| 老色鬼精品视频在线观看播放| 日韩不卡手机在线v区| 免费成人av资源网| 狂野欧美性猛交blacked| 免费人成网站在线观看欧美高清| 午夜电影久久久| 美女视频黄久久| 国产精华液一区二区三区| 成人性生交大片免费看视频在线 | 日韩情涩欧美日韩视频| 欧亚一区二区三区| 91黄视频在线观看| 欧美手机在线视频| 日韩视频免费直播| 久久午夜羞羞影院免费观看| 国产欧美综合在线观看第十页| 中文字幕 久热精品 视频在线| 亚洲色大成网站www久久九九| 亚洲另类春色国产| 日日摸夜夜添夜夜添国产精品| 蜜臀av国产精品久久久久| 精品一区二区日韩| 97久久超碰国产精品| 欧美性大战xxxxx久久久| 日韩午夜在线观看| 国产精品水嫩水嫩| 天堂一区二区在线免费观看| 国产在线精品不卡| 色哦色哦哦色天天综合| 欧美一区二区三区播放老司机| www国产亚洲精品久久麻豆| 国产精品久久久久久久久久久免费看 | 色爱区综合激月婷婷| 欧美一级在线免费| 国产人久久人人人人爽| 亚洲成人av福利| 国产不卡视频一区二区三区| 欧美无乱码久久久免费午夜一区| 欧美va天堂va视频va在线| 亚洲美女视频在线| 国产一区二区在线视频| 色丁香久综合在线久综合在线观看| 91精品婷婷国产综合久久性色| 久久久久久久久一| 亚洲第一福利一区| www.亚洲人| 日韩欧美国产小视频| 亚洲一区二区偷拍精品| 久久97超碰国产精品超碰| 91精品办公室少妇高潮对白| 欧美刺激脚交jootjob| 亚洲免费三区一区二区| 国产一区二区三区精品欧美日韩一区二区三区| 成人免费高清视频在线观看| 56国语精品自产拍在线观看| 一区二区中文视频| 国产伦理精品不卡| 欧美一级片免费看| 亚洲国产综合在线| caoporn国产精品| 国产午夜精品美女毛片视频| 欧美aaaaa成人免费观看视频| 91视频观看视频| 欧美本精品男人aⅴ天堂| 日韩精品一级二级| 91性感美女视频| 亚洲国产精品激情在线观看 | 欧美xxxxxxxx| 丝袜脚交一区二区| 色丁香久综合在线久综合在线观看| 国产嫩草影院久久久久| 国产精品一区二区不卡| 日韩一本二本av| 久久97超碰色| 欧美mv日韩mv国产网站app| 日本美女一区二区三区视频| 欧美视频一区二区三区四区| 亚洲丝袜另类动漫二区| 成人丝袜高跟foot| 日本一区二区不卡视频| 国产成人aaaa| 国产嫩草影院久久久久| 国产福利精品导航| 久久精品无码一区二区三区 | 国产福利精品一区二区| 精品国产免费久久| 蜜桃av一区二区| 日韩欧美电影在线| 日本v片在线高清不卡在线观看| 欧美性受xxxx| 亚洲1区2区3区视频| 欧美乱熟臀69xxxxxx| 日韩电影在线一区二区三区| 91麻豆精品国产91久久久久久久久 | 亚洲蜜桃精久久久久久久| 不卡av电影在线播放| 国产美女久久久久| 日韩精品一区二区三区在线播放| 日韩电影免费在线观看网站| 欧美色男人天堂| 日韩黄色一级片| 精品国产乱码久久久久久夜甘婷婷 | av综合在线播放| 亚洲精选视频在线| 欧美日韩久久不卡| 美美哒免费高清在线观看视频一区二区 | 国产九色sp调教91| 国产免费成人在线视频| av不卡在线观看| 亚洲国产aⅴ成人精品无吗| 欧美一区二区高清| 国产美女视频一区| 亚洲欧美日韩精品久久久久| 欧美人狂配大交3d怪物一区| 天天亚洲美女在线视频| 欧美精品一区二区三| 成人99免费视频| 亚洲激情综合网|