put_user
1. put_user
Name
put_user -- Write a simple value into user space.
Synopsis
put_user
( x, ptr);
Arguments
- x
-
Value to copy to user space.
- ptr
-
Destination address, in user space.
Context
User context only. This function may sleep.
Description
This macro copies a single simple value from kernel space to user space. It supports simple types like char and int, but not larger data types like structures or arrays.
ptr must have pointer-to-simple-variable type, and x must be assignable to the result of dereferencing ptr .
Returns zero on success, or -EFAULT on error.
put_user的更多相关文章
- copy_to_user,copy_from_user,get_user,put_user函数比较
copy_to_user,copy_from_user,get_user,put_user函数比较 copy_to_user -- Copy a block of data into user sp ...
- linux内核中的get_user和put_user
linux内核中的get_user和put_user 在 内核空间和用户空间交换数据时,get_user和put_user是两个两用的函数.相对于copy_to_user和 copy_from_use ...
- Missing access checks in put_user/get_user kernel API (CVE-2013-6282)
/* 本文章由 莫灰灰 编写,转载请注明出处. 作者:莫灰灰 邮箱: minzhenfei@163.com */ 1.漏洞成因 Linux kernel对ARM上的get_user/put_us ...
- Linux 驱动学习笔记05--字符驱动实例,实现一个共享内存设备的驱动
断断续续学驱动,好不容易有空,做了段字符驱动的例子.主要还是跟书上学习在此记录下来,以后说不定能回过头来温故知新. 首先上驱动源码 gmem.c: /************************* ...
- 分析Linux内核创建一个新进程的过程
一.原理分析 1.进程的描述 进程控制块PCB——task_struct,为了管理进程,内核必须对每个进程进行清晰的描述,进程描述符提供了内核所需了解的进程信息. struct task_struct ...
- karottc A Simple linux-virus Analysis、Linux Kernel <= 2.6.37 - Local Privilege Escalation、CVE-2010-4258、CVE-2010-3849、CVE-2010-3850
catalog . 程序功能概述 . 感染文件 . 前置知识 . 获取ROOT权限: Linux Kernel <= - Local Privilege Escalation 1. 程序功能概述 ...
- Process Kill Technology && Process Protection Against In Linux
目录 . 引言 . Kill Process By Kill Command && SIGNAL . Kill Process By Resource Limits . Kill Pr ...
- Linux字符设备
一.linux系统将设备分为3类:字符设备.块设备.网络设备. 字符设备:是指只能一个字节一个字节读写的设备,不能随机读取设备内存中的某一数据,读取数据需要按照先后数据.字符设备是面向流的设备,常见的 ...
- Binder的设计和框架
转自:http://wangkuiwu.github.io/2014/09/01/Binder-Introduce/ 1. Binder架构解析 1.1 Binder模型 上图中涉及到Binder模型 ...
随机推荐
- MFC ListBox 设置水平长度
在*.rc资源 设置可以水平滚动, 垂直滚动 但是 水平滚动无效,水平方向 一直无法显示 完整 设置代码如下 m_listBox.SetHorizontalExtent(2000); m_listBo ...
- 微软 codeplex 团队
http://www.codeplex.com/site/users/view/Microsoft
- Redux API之creatStore
createStore(reducer, [initialState]) 创建一个 Redux store 来以存放应用中所有的 state.应用中应有且仅有一个 store. 参数 reducer ...
- 关于System类中out属性 实例化的问题
System类中out属性的声明是这样的: public final static PrintStream out = nullPrintStream(); private static PrintS ...
- eclipse(java) 使用SQL …
java连接sqlserver2005数据库 首先得下载驱动程序到微软网站下载Microsoft JDBC Driver 4.0 for SQL Server 下载地址 :http://msdn. ...
- openstack官方指导书
openstack官方网站:https://docs.openstack.org/ 由于openstack的官方文档有点多,所以这里对其进行梳理一下 Release Notes 发布版本 新功能,升级 ...
- login.aspx.cs
using System; //指令+系统(命名空间)using Sys ...
- Django 框架
MVC 框架和MTV框架 (了解即可) MVC,全名是Model View Controller,是软件工程中的一种软件架构模式,把软件系统分为三个基本部分:模型(Model).视图(View)和控 ...
- "Mysql has gone away"的几种可能
现象: 在本地利用Flask自带的WSGI服务进行调试没有问题后,通过Gunicorn进行部署. 但是在一晚上没有访问之后,第二天再次访问会出现500(Internal error). 原因: 通过追 ...
- Windows下安装CUDA8.0
在Win10下安装CUDA8.0,并使用VS2013测试: 机器配置: Windows 10 VS 2013 CUDA8.0 CUDA 8.0:下载地址 CUDA其他版本:下载地址 1. 安装CUDA ...