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

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

?? sys.c

?? Linux2.4.20針對三星公司的s3c2410開發板的內核改造。
?? C
?? 第 1 頁 / 共 2 頁
字號:
/* *  linux/kernel/sys.c * *  Copyright (C) 1991, 1992  Linus Torvalds */#include <linux/module.h>#include <linux/mm.h>#include <linux/utsname.h>#include <linux/mman.h>#include <linux/smp_lock.h>#include <linux/notifier.h>#include <linux/reboot.h>#include <linux/prctl.h>#include <linux/init.h>#include <linux/highuid.h>#ifdef CONFIG_KFI#include <linux/kfi.h>#endif#include <asm/uaccess.h>#include <asm/io.h>/* * this is where the system-wide overflow UID and GID are defined, for * architectures that now have 32-bit UID/GID but didn't in the past */int overflowuid = DEFAULT_OVERFLOWUID;int overflowgid = DEFAULT_OVERFLOWGID;/* * the same as above, but for filesystems which can only store a 16-bit * UID and GID. as such, this is needed on all architectures */int fs_overflowuid = DEFAULT_FS_OVERFLOWUID;int fs_overflowgid = DEFAULT_FS_OVERFLOWUID;/* * this indicates whether you can reboot with ctrl-alt-del: the default is yes */int C_A_D = 1;int cad_pid = 1;/* *	Notifier list for kernel code which wants to be called *	at shutdown. This is used to stop any idling DMA operations *	and the like.  */static struct notifier_block *reboot_notifier_list;rwlock_t notifier_lock = RW_LOCK_UNLOCKED;/** *	notifier_chain_register	- Add notifier to a notifier chain *	@list: Pointer to root list pointer *	@n: New entry in notifier chain * *	Adds a notifier to a notifier chain. * *	Currently always returns zero. */ int notifier_chain_register(struct notifier_block **list, struct notifier_block *n){	write_lock(&notifier_lock);	while(*list)	{		if(n->priority > (*list)->priority)			break;		list= &((*list)->next);	}	n->next = *list;	*list=n;	write_unlock(&notifier_lock);	return 0;}/** *	notifier_chain_unregister - Remove notifier from a notifier chain *	@nl: Pointer to root list pointer *	@n: New entry in notifier chain * *	Removes a notifier from a notifier chain. * *	Returns zero on success, or %-ENOENT on failure. */ int notifier_chain_unregister(struct notifier_block **nl, struct notifier_block *n){	write_lock(&notifier_lock);	while((*nl)!=NULL)	{		if((*nl)==n)		{			*nl=n->next;			write_unlock(&notifier_lock);			return 0;		}		nl=&((*nl)->next);	}	write_unlock(&notifier_lock);	return -ENOENT;}/** *	notifier_call_chain - Call functions in a notifier chain *	@n: Pointer to root pointer of notifier chain *	@val: Value passed unmodified to notifier function *	@v: Pointer passed unmodified to notifier function * *	Calls each function in a notifier chain in turn. * *	If the return value of the notifier can be and'd *	with %NOTIFY_STOP_MASK, then notifier_call_chain *	will return immediately, with the return value of *	the notifier function which halted execution. *	Otherwise, the return value is the return value *	of the last notifier function called. */ int notifier_call_chain(struct notifier_block **n, unsigned long val, void *v){	int ret=NOTIFY_DONE;	struct notifier_block *nb = *n;	while(nb)	{		ret=nb->notifier_call(nb,val,v);		if(ret&NOTIFY_STOP_MASK)		{			return ret;		}		nb=nb->next;	}	return ret;}/** *	register_reboot_notifier - Register function to be called at reboot time *	@nb: Info about notifier function to be called * *	Registers a function with the list of functions *	to be called at reboot time. * *	Currently always returns zero, as notifier_chain_register *	always returns zero. */ int register_reboot_notifier(struct notifier_block * nb){	return notifier_chain_register(&reboot_notifier_list, nb);}/** *	unregister_reboot_notifier - Unregister previously registered reboot notifier *	@nb: Hook to be unregistered * *	Unregisters a previously registered reboot *	notifier function. * *	Returns zero on success, or %-ENOENT on failure. */ int unregister_reboot_notifier(struct notifier_block * nb){	return notifier_chain_unregister(&reboot_notifier_list, nb);}asmlinkage long sys_ni_syscall(void){	return -ENOSYS;}static int proc_sel(struct task_struct *p, int which, int who){	if(p->pid)	{		switch (which) {			case PRIO_PROCESS:				if (!who && p == current)					return 1;				return(p->pid == who);			case PRIO_PGRP:				if (!who)					who = current->pgrp;				return(p->pgrp == who);			case PRIO_USER:				if (!who)					who = current->uid;				return(p->uid == who);		}	}	return 0;}asmlinkage long sys_setpriority(int which, int who, int niceval){	struct task_struct *p;	int error;	if (which > 2 || which < 0)		return -EINVAL;	/* normalize: avoid signed division (rounding problems) */	error = -ESRCH;	if (niceval < -20)		niceval = -20;	if (niceval > 19)		niceval = 19;	read_lock(&tasklist_lock);	for_each_task(p) {		if (!proc_sel(p, which, who))			continue;		if (p->uid != current->euid &&			p->uid != current->uid && !capable(CAP_SYS_NICE)) {			error = -EPERM;			continue;		}		if (error == -ESRCH)			error = 0;		if (niceval < task_nice(p) && !capable(CAP_SYS_NICE))			error = -EACCES;		else			set_user_nice(p, niceval);	}	read_unlock(&tasklist_lock);	return error;}/* * Ugh. To avoid negative return values, "getpriority()" will * not return the normal nice-value, but a negated value that * has been offset by 20 (ie it returns 40..1 instead of -20..19) * to stay compatible. */asmlinkage long sys_getpriority(int which, int who){	struct task_struct *p;	long retval = -ESRCH;	if (which > 2 || which < 0)		return -EINVAL;	read_lock(&tasklist_lock);	for_each_task (p) {		long niceval;		if (!proc_sel(p, which, who))			continue;		niceval = 20 - task_nice(p);		if (niceval > retval)			retval = niceval;	}	read_unlock(&tasklist_lock);	return retval;}/* * Reboot system call: for obvious reasons only root may call it, * and even root needs to set up some magic numbers in the registers * so that some mistake won't make this reboot the whole machine. * You can also set the meaning of the ctrl-alt-del-key here. * * reboot doesn't sync: do that yourself before calling this. */asmlinkage long sys_reboot(int magic1, int magic2, unsigned int cmd, void * arg){	char buffer[256];	/* We only trust the superuser with rebooting the system. */	if (!capable(CAP_SYS_BOOT))		return -EPERM;	/* For safety, we require "magic" arguments. */	if (magic1 != LINUX_REBOOT_MAGIC1 ||	    (magic2 != LINUX_REBOOT_MAGIC2 && magic2 != LINUX_REBOOT_MAGIC2A &&			magic2 != LINUX_REBOOT_MAGIC2B))		return -EINVAL;	lock_kernel();	switch (cmd) {	case LINUX_REBOOT_CMD_RESTART:		notifier_call_chain(&reboot_notifier_list, SYS_RESTART, NULL);#ifdef CONFIG_KFI		kfi_dump_log(NULL);#endif		printk(KERN_EMERG "Restarting system.\n");		machine_restart(NULL);		break;	case LINUX_REBOOT_CMD_CAD_ON:		C_A_D = 1;		break;	case LINUX_REBOOT_CMD_CAD_OFF:		C_A_D = 0;		break;	case LINUX_REBOOT_CMD_HALT:		notifier_call_chain(&reboot_notifier_list, SYS_HALT, NULL);#ifdef CONFIG_KFI		kfi_dump_log(NULL);#endif		printk(KERN_EMERG "System halted.\n");		machine_halt();		do_exit(0);		break;	case LINUX_REBOOT_CMD_POWER_OFF:		notifier_call_chain(&reboot_notifier_list, SYS_POWER_OFF, NULL);#ifdef CONFIG_KFI		kfi_dump_log(NULL);#endif		printk(KERN_EMERG "Power down.\n");		machine_power_off();		do_exit(0);		break;	case LINUX_REBOOT_CMD_RESTART2:		if (strncpy_from_user(&buffer[0], (char *)arg, sizeof(buffer) - 1) < 0) {			unlock_kernel();			return -EFAULT;		}		buffer[sizeof(buffer) - 1] = '\0';		notifier_call_chain(&reboot_notifier_list, SYS_RESTART, buffer);		printk(KERN_EMERG "Restarting system with command '%s'.\n", buffer);#ifdef CONFIG_KFI		kfi_dump_log(NULL);#endif		machine_restart(buffer);		break;	default:		unlock_kernel();		return -EINVAL;	}	unlock_kernel();	return 0;}static void deferred_cad(void *dummy){	notifier_call_chain(&reboot_notifier_list, SYS_RESTART, NULL);	machine_restart(NULL);}/* * This function gets called by ctrl-alt-del - ie the keyboard interrupt. * As it's called within an interrupt, it may NOT sync: the only choice * is whether to reboot at once, or just ignore the ctrl-alt-del. */void ctrl_alt_del(void){	static struct tq_struct cad_tq = {		routine: deferred_cad,	};	if (C_A_D)		schedule_task(&cad_tq);	else		kill_proc(cad_pid, SIGINT, 1);}	/* * Unprivileged users may change the real gid to the effective gid * or vice versa.  (BSD-style) * * If you set the real gid at all, or set the effective gid to a value not * equal to the real gid, then the saved gid is set to the new effective gid. * * This makes it possible for a setgid program to completely drop its * privileges, which is often a useful assertion to make when you are doing * a security audit over a program. * * The general idea is that a program which uses just setregid() will be * 100% compatible with BSD.  A program which uses just setgid() will be * 100% compatible with POSIX with saved IDs.  * * SMP: There are not races, the GIDs are checked only by filesystem *      operations (as far as semantic preservation is concerned). */asmlinkage long sys_setregid(gid_t rgid, gid_t egid){	int old_rgid = current->gid;	int old_egid = current->egid;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
色综合中文字幕国产 | 欧美一区2区视频在线观看| 国产精品久久久久久久蜜臀 | 成人美女在线视频| 亚洲欧洲av另类| 在线免费精品视频| 亚洲国产视频一区二区| 欧美一级夜夜爽| 国产精品亚洲人在线观看| 国产精品三级在线观看| 色悠悠亚洲一区二区| 午夜精品免费在线观看| 欧美岛国在线观看| 成人综合在线网站| 一区二区三区中文字幕在线观看| 欧美日韩国产综合视频在线观看| 免费人成精品欧美精品| 久久久久国产成人精品亚洲午夜| 成人免费高清视频在线观看| 亚洲一区二区三区四区的| 日韩欧美另类在线| 99综合影院在线| 天天av天天翘天天综合网| 日韩免费看的电影| youjizz国产精品| 亚洲成人在线网站| 国产日韩综合av| 欧美中文字幕一区二区三区亚洲| 日本aⅴ免费视频一区二区三区| 久久久综合精品| 在线亚洲欧美专区二区| 久久精品国产99国产精品| 亚洲视频狠狠干| 欧美一区二区精美| 色婷婷综合久久| 精品无码三级在线观看视频| 亚洲欧美韩国综合色| 精品国产一区二区亚洲人成毛片| 99久久综合精品| 久久99精品久久久| 亚洲综合色视频| 中文字幕在线不卡视频| 日韩免费视频一区二区| 欧美亚洲国产怡红院影院| 大桥未久av一区二区三区中文| 秋霞午夜av一区二区三区| 亚洲欧美经典视频| 国产拍欧美日韩视频二区| 欧美一级理论性理论a| 91欧美一区二区| 国产综合久久久久久久久久久久| 亚洲超碰精品一区二区| 中文字幕中文乱码欧美一区二区 | 五月激情综合网| 国产精品传媒在线| 国产日韩欧美不卡在线| 欧美一区二区三区四区视频| 91免费视频网址| 成人免费看视频| 国产成人精品综合在线观看 | 国产精品一二三区在线| 蜜臀91精品一区二区三区| 亚洲电影视频在线| 亚洲欧美国产77777| 中文字幕中文字幕一区二区| 国产日韩av一区二区| 精品粉嫩超白一线天av| 欧美一区三区四区| 欧美日韩国产小视频在线观看| 99久久精品国产毛片| 粉嫩av亚洲一区二区图片| 国内精品不卡在线| 精品一区二区三区免费视频| 捆绑调教一区二区三区| 日本在线不卡一区| 蜜乳av一区二区| 免费xxxx性欧美18vr| 日韩 欧美一区二区三区| 日韩高清在线电影| 日本少妇一区二区| 久久精品国产色蜜蜜麻豆| 日韩va亚洲va欧美va久久| 日av在线不卡| 国产在线一区二区| 国产伦精品一区二区三区免费迷 | 久久这里只有精品6| 日韩一级二级三级精品视频| 日韩免费看网站| 久久欧美一区二区| 国产精品污www在线观看| 久久99热这里只有精品| 国产成人av电影在线播放| 亚洲精品乱码久久久久久| 亚洲码国产岛国毛片在线| 亚洲综合区在线| 免费在线观看日韩欧美| 在线看国产一区| 欧美性猛交xxxxxx富婆| 91精品免费观看| 欧美精品一区二区三区蜜桃视频 | 久久综合丝袜日本网| 久久久久久久久久久久电影| 国产精品理伦片| 亚洲图片一区二区| 麻豆91在线看| 成人av在线播放网址| 欧美亚洲国产一卡| 欧美电影免费观看高清完整版| 国产婷婷精品av在线| 亚洲视频小说图片| 蜜臀av一区二区| gogo大胆日本视频一区| 欧美精品一二三区| 精品国产亚洲一区二区三区在线观看| 国产婷婷一区二区| 亚洲精品国产无天堂网2021| 免费人成黄页网站在线一区二区| 国产99一区视频免费 | 欧美一级日韩一级| 国产精品三级久久久久三级| 亚洲一区二区三区国产| 极品少妇xxxx精品少妇偷拍| 色综合一区二区三区| 欧美一级在线免费| 亚洲免费看黄网站| 久草中文综合在线| 欧美三级资源在线| 国产精品水嫩水嫩| 欧美bbbbb| 色综合中文字幕国产 | 亚洲精品中文在线影院| 久久精品国产99| 欧美色区777第一页| 欧美国产综合色视频| 日本91福利区| 欧美日韩一区二区在线视频| 中文字幕一区免费在线观看 | 丝袜亚洲另类欧美综合| 91视频91自| 国产欧美一区二区精品性色超碰| 丁香婷婷综合五月| 精品国产乱码久久久久久浪潮| 一区二区三区不卡在线观看| 国产成人a级片| 精品成人在线观看| 日本欧美在线观看| 欧美熟乱第一页| 亚洲欧美日韩人成在线播放| 成人性生交大片免费看中文网站| 日韩精品专区在线影院重磅| 肉色丝袜一区二区| 欧美在线短视频| 亚洲免费av观看| 在线中文字幕不卡| 亚洲三级电影全部在线观看高清| 国产黑丝在线一区二区三区| 精品国产自在久精品国产| 日本在线不卡视频一二三区| 欧美日韩三级一区| 一区二区三区不卡视频在线观看| 不卡欧美aaaaa| 日本一区二区不卡视频| 国产精品一二一区| 日韩女优制服丝袜电影| 免费在线观看视频一区| 欧美一区二区在线视频| 亚洲一二三专区| 欧美丝袜丝交足nylons| 国产欧美视频一区二区三区| 国产精品一区免费在线观看| 日韩欧美国产精品| 亚洲不卡在线观看| 欧美一区中文字幕| 午夜激情久久久| 666欧美在线视频| 日日噜噜夜夜狠狠视频欧美人| 色av成人天堂桃色av| 亚洲成av人综合在线观看| 91麻豆精东视频| 亚洲成人激情av| 久久电影国产免费久久电影 | 色婷婷国产精品综合在线观看| 亚洲视频狠狠干| 99久久国产综合精品色伊| 中文在线免费一区三区高中清不卡| 大桥未久av一区二区三区中文| 久久久久久亚洲综合影院红桃 | 日韩毛片精品高清免费| 91丝袜国产在线播放| 亚洲美女免费在线| 欧美一区二区三区视频免费| 青青草91视频| 欧美韩国日本综合| 欧美日韩精品二区第二页| 亚洲妇女屁股眼交7| wwwwww.欧美系列| 99久久精品国产毛片| 亚洲超丰满肉感bbw| 久久精品亚洲精品国产欧美| 豆国产96在线|亚洲|