查找idt table 所對應的page table in Linux
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/types.h>
#include <asm/pgtable.h>
#include <asm/current.h>
#include <asm/desc_defs.h>
MODULE_LICENSE("GPL");
struct desc_ptr idt;
int init_module(void)
{
asm volatile ("sidt %0" : "=m" (idt));
unsigned int level;
pte_t *pte;
pte = lookup_address( idt.address, &level);
printk("level:%d\n", level);
printk("pte_val(*pte):%lx\n", pte_val(*pte));
printk("pte_val(*pte)& _PAGE_PRESENT:%d\n", pte_val(*pte)& _PAGE_PRESENT);
return 0;
}
void cleanup_module(void)
{
printk("clean_module : fixmap\n");
}
查找idt table 所對應的page table in Linux的更多相关文章
- Page (computer memory) Memory segmentation Page table 虚拟地址到物理地址的转换
A page, memory page, or virtual page is a fixed-length contiguous block of virtual memory, described ...
- Virtual Memory PAGE TABLE STRUCTURE
COMPUTER ORGANIZATION AND ARCHITECTURE DESIGNING FOR PERFORMANCE NINTH EDITION The basic mechanism f ...
- Marlin 溫度感應器 數值轉換對應表
Marlin 溫度感應器 數值轉換對應表 (2014/03/27)Update: 自己實測了這個自動產生的對應表,結果測得的溫度與實際值仍有相當大的誤差.看來還是要回頭用測量的方式來校正溫度... ...
- linux page table entry struct
Page Table Entry The access control information is held in the PTE and is CPU specific; figure bit f ...
- [Xamarin.Android]使用Java Bindings Libary專案 Binding Java元件(.jar) 與Metadata.xml、型別對應 (转帖)
使用Xamarin開發Android APP時, 如果已經有原本就用Java寫好的套件(.jar), 就可以利用Xamarin提供的Java Bindings Libary將他變成C#可使用的元件. ...
- Linux就这个范儿 第15章 七种武器 linux 同步IO: sync、fsync与fdatasync Linux中的内存大页面huge page/large page David Cutler Linux读写内存数据的三种方式
Linux就这个范儿 第15章 七种武器 linux 同步IO: sync.fsync与fdatasync Linux中的内存大页面huge page/large page David Cut ...
- html table表格导出excel的方法 html5 table导出Excel HTML用JS导出Excel的五种方法 html中table导出Excel 前端开发 将table内容导出到excel HTML table导出到Excel中的解决办法 js实现table导出Excel,保留table样式
先上代码 <script type="text/javascript" language="javascript"> var idTmr; ...
- foreach statement cannot operate on variables of type 'System.Web.UI.WebControls.Table' because 'System.Web.UI.WebControls.Table' does not contain a public definition for 'GetEnumerator'
错误:foreach statement cannot operate on variables of type 'System.Web.UI.WebControls.Table' because ' ...
- magento -- 解决magento错误:ERROR: Base table or view already exists: 1050 Table ... already exists
相信有更新magento或者,备份转移magento站点的时候可能会碰到类似这样的错误提示: Base table or view already exists: 1050 Table ... alr ...
随机推荐
- motd - 当日消息
描述 (DESCRIPTION) 在 登录 系统 后, 执行 登录 shell 前, login(1) 显示 /etc/motd 中的 内容. "motd" 意思是 "m ...
- zabbix3.4.8中提示host [4gronghe_110] not found
查看zabbix_agentd.log时出现下列错误 [root@4gronghe_110 ~]# tail /var/log/zabbix/zabbix_agentd.log 1266:2014 ...
- 用C#实现获取文件夹大小的源代码
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Tex ...
- Codeforces Round #425 (Div. 2) - D
题目链接:http://codeforces.com/contest/832/problem/D 题意:给定一棵n个点的树,然后给你q个询问,每个询问为三元组(a,b,c),问你从这三个点中选取一个作 ...
- Codeforces Round #421 (Div. 2) - A
题目链接:http://codeforces.com/contest/820/problem/A 题意:一个人在看一本书,书一共C页,这个人每天看v0页,但是他又开始加速看这本书,每天都比前一天多看a ...
- 14DBCP连接池
实际开发中“获得连接”或“释放资源”是非常消耗系统资源的两个过程,为了解决此类性能问题,通常情况我们采用连接池技术,来共享连接Connection.这样我们就不需要每次都创建连接.释放连接了,这些操作 ...
- SpringBoot 利用freemaker生成静态页面
1. <!-- freemarker模板 --> <dependency> <groupId>org.springframework.boot</groupI ...
- alert(1) to win 8
function escape(s) { return '<script>console.log("' + s.toUpperCase() + '")</scri ...
- 在父组件中,直接获取子组件数据-vue
1.通过 $ref 获取 主父组件中: <x-test ref="ch"></x-test> import XTest from '@/components ...
- flume(2)
接续上一篇:https://www.cnblogs.com/metianzing/p/9511852.html 这里也是主要记录配置文件. 以上一篇案例五为基础,考虑到日志服务器和采集日志的服务器往往 ...