摘要:1、中间库: 中间库都放在middlewares目录,include头文件相同,所以不需要特殊处理,只要特殊处理lib安装目录, 示例pro文件如下: TEMPLATE = lib TARGET = ime VERSION = 1.0.0 DEPENDPATH += . INCLUDEPATH += . CONFIG += staticlib inc.files = \ xinputmethod...
阅读全文
摘要:发现一些linux文件系统没有正常工作,都是空的 在sata.sh中加了手动重新挂载: mount [OPTIONS] [-o OPTS] DEVICE NODE mount -t usbfs none /proc/bus/usb/ mount -t sysfs sysfs /sys mount –t devpts none /dev/pts 注意:usbdevfs 已经过时,用usbfs代替
阅读全文
摘要:usb SET_FEATURE TEST_MODE http://www.beyondlogic.org/usbnutshell/usb6.shtml http://www.beyondlogic.org/usbnutshell/usb7.htm
阅读全文
摘要:20 January 2007 -- BusyBox 1.4.0 (stable) e2fsprogs are mostly removed from busybox 由于e2fsprogs太大,所以移除了。所以要自己编译 主要包含的命令: findfs fsck.ext3 mkfs.ext3 http://cross-lfs.org/view/1.1.0/x86/final-system/e2f...
阅读全文
摘要:devfs、sysfs、udev介绍 http://blog.csdn.net/aaronychen/archive/2008/09/19/2953345.aspx 一、devfs linux下有专门的文件系统用来对设备进行管理,devfs和sysfs就是其中两种。在2.6内核以前一直使用的是devfs,devfs挂载于/dev目录下,提供了一种类似于文件的方法来管理位于/dev目录下的所有设备,...
阅读全文
摘要:http://my.chinaunix.net/space.php?uid=20382483&do=blog&id=321047 多数的 Linux 内核态程序都需要和用户空间的进程交换数据,但 Linux 内核态无法对传统的 Linux 进程间同步和通信的方法提供足够的支持。本文总结并比较了几种内核态与用户态进程通信的实现方法,并推荐使用 netlink 套接字实现中断环境与用户态进程通信。 1...
阅读全文
摘要:#!/bin/sh echo "init..." echo "ifconfig eth0..." ifconfig eth0 192.168.73.59 mount -o nolock 192.168.73.60:/rootfs /mnt exec /sbin/switch_root /mnt /linuxrc
阅读全文
摘要:Freeing init memory: 4172K Failed to execute /init Failed to execute /sbin/init. Attempting defaults... Kernel panic - not syncing: No init foun...
阅读全文
摘要:内存加到1G后,发现后面的512M不能使用,导致kernel起不来,停在starting kernel那里。 所以在uboot环境下检测后面512M内存: uboot下sflash 地址为0xf8000000,前100000为uboot,后面的为kernel Marvell>> iminfo 0xf8100000 ## Checking Image at f8100000 ... Image ...
阅读全文
摘要:BANK - also "memory bank" A bank of memory (flash or RAM) consists of all those memory chips on your system that are controlled by the same chip select signal. For example, a system might consist of o...
阅读全文
摘要:在 U-Boot中,Denx(U-Boot的开发商)针对常见的DDR内存故障进行了严格的检测处理,下图描述了该检测处理过程的三个步骤:检测数据线、地址线和DDR物理存储部件,主要涉及这三个步骤的处理过程和方法,对于DDR子系统,是很容易出故障并且是很难debug检测出来的,而Denx所针对 DDR内存故障设计的检测方法是非常严谨,值得学习研究的。 下面主要是相关的检测处理思路及问题: 1、为什么先...
阅读全文
摘要:使用asm/div64.h中宏do_div #include <asm/div64.h> unsigned long long x,y,result; unsigned long mod; mod = do_div(x,y); result = x; 64 bit division 结果保存在x中;余数保存在返回结果中。
阅读全文
摘要:接入usb移动硬盘后不能识别,内核一直打印提示信息如下 : hub 1-1:1.0: over-current change on port1 hub 1-1:1.0: over-current change on port1 过流保护?
阅读全文
摘要:http://blogold.chinaunix.net/u/31100/showart_244622.html (转载) ================================ Author: taoyuetao Email: tao_yuetao@yahoo.com.cn Blog: taoyuetao.cublog.cn 2006-11-03 ===================...
阅读全文
摘要:http://blogold.chinaunix.net/u3/111381/showart_2163688.html 5.2.2:接口驱动中的hub_thread()函数 我们之前在分析usb_hub_init()的代码的时候,忽略掉了一部份. 代码片段如下所示: int usb_hub_init(void) { …… khubd_task = kthread_run(hub_thread,...
阅读全文
摘要:set lcd0_enable 1 //set lcd0_params 1280x720-32@60 set lcd0_params 1280x720-16@60 改成16位色就可以,具体原因不明 测试时候读用cat命令,写用cp 在硬盘上用 cat xxx.mpg > /dev/null 读硬盘数据,闪烁严重 cp /usb/test /mnt/test1 闪烁较少,但是也有 usb上读写...
阅读全文
摘要:http://www.unixresources.net/linux/clf/embedded/archive/00/00/62/23/622399.html http://blogold.chinaunix.net/u/31100/showart_244622.html 限制512m内存之后就可以跑起来,奇怪啊! setenv bootcmd 'setenv bootargs init=/sb...
阅读全文
摘要:第八章、路由觀念與路由器設定 http://linux.vbird.org/linux_server/0230router.php
阅读全文
摘要:作者:shiroki @cuteqt.com 保留版权信息 网站:酷享Qt 原文链接:http://www.cuteqt.com/blog/?p=65 ui文件的使用是在Qt4中不太容易上手的一点,因为很多同学都是从Qt3升级到Qt4的,在升级过程中发现这部分的变化非常之大,让人有点无所适从。 Qt3的designer简直可以媲美一个ide,可以编辑代码,可以管理工程, 可是到了Qt4却仿佛是退化...
阅读全文
摘要:QT没有提供一个完整的IP地址控件, 1. 可以使用QLineEdit简单的实现 QRegExp regExp("((2[0-4]\\d|25[0-5]|[01]?\\d\\d?)\\.){3}(2[0-4]\\d|25[0-5]|[01]?\\d\\d?)"); QRegExpValidator *pValidator =new QRegExpValidator(regExp, this);...
阅读全文
摘要:#if 0 QPalette palette = app.palette(); palette.setColor(QPalette::WindowText, Qt::white); palette.setColor(QPalette::Window, Qt::black); palette.setColor(QPalette::Base, Qt::black); palette.setC...
阅读全文
摘要:http://fred-zone.blogspot.com/2008/02/linux-kernel-space-udp-server.html 今天在『Linux Kernel Newbies』閒逛,看近期 Kernel 的動態和變化,心中不時贊歎 Linux 發展的複雜和快速,每次去都令人驚奇。該網站上除了有 kernel 的最新資訊,也有一些相關的文件和教學手冊,而其中一篇文獻『Simple...
阅读全文
摘要:IFF_UP 和 IFF_RUNNING 的差別在哪?就實際功用而言,兩者都代表了網路裝置是否正常啟用,但是更仔細觀察可以發現拔除網路線時會造成 IFF_RUNNING 的改變,至於 IFF_UP 不會因插拔網路線而有任何變化 #include <stdio.h> #include <stdlib.h> #include <sys/types.h> #include <sys/stat.h> ...
阅读全文
摘要:http://www.unixresources.net/linux/clf/proxy/archive/00/00/38/41/384165.html
阅读全文
摘要:mount -o iocharset=utf8 /dev/sde1 /mnt可以,但是内核会警告 man 8 mount 查看vfat相关 mount -o utf8 /dev/sda5 /mnt 成功支持中文最终命令:mount -o utf8,shortname=mixed,usefree %1 %2usefree解决statfs慢的问题shortname=mixed解决大小写问题
阅读全文
摘要:Accessing PCI Regions PCI devices contain three addressable regions: configuration space, I/O ports, and device memory Configuration Space pci_read_config_[byte|word|dword](struct pci_dev *pdev, int o...
阅读全文
摘要:功能:将IO地址空间映射到内核的虚拟空间上。 linux-2.6.x/arch/arm/io.h 208 /* 209 * ioremap and friends. 210 * 211 * ioremap takes a PCI memory address, as specified in 212 * Documentation/IO-mapping.txt. 213 * 214 */ 215...
阅读全文
摘要:安装 apt-get install qemu-launcher 安装完成后,在 Application/Accessories 系统菜单下,添加了qemu-laucher 的启动项。 查看安装了哪些文件 dpkg -L qemu-launcher 参考http://blog.ccidnet.com/home.php?mod=space&uid=60710&do=blog&id=612280
阅读全文
摘要:双网卡不能将ip设置为同一网段,如果设置为同一网段则会出现,网线都插着时,只有A口有作用。只有网线在A口时,两个ip都可以访问。只有网线在B口时,网络无法访问,只有把A口停了才行(ifdown eth0)。 所以,这类情况只要设置不同网段的IP就解决问题了;
阅读全文
摘要:在Unix系统下,维护源码版本可以使用很多方法,其中最常用的当然是大名鼎鼎的CVS,但实际上,简单的版本维护工作并没有必要使用复杂的CVS等专门的版本维护工具,Unix标配中的diff和patch工具就完全可以完成代码的简单备份和升级工作。 diff 以"行"为单位比较两个文本文件(也可以是目录比较),并将不同之处以某种格式输出到标准输出上;patch可以读入这种输出,并按照一定指令使源文件 (...
阅读全文
摘要:root@james-desktop:/opt/qt-everywhere/marvell/SDK/linux-2.6.31.8# diff .config-2g config-3g 4c4 < # Sun Jun 19 10:06:59 2011 --- > # Sun Jun 19 10:06:32 2011 363,364c363,364 < # CONFIG_VMSPLIT_3G is n...
阅读全文
摘要:http://blog.csdn.net/sustzombie/archive/2010/06/12/5667563.aspx 虽然有错误,但是可以参考 http://www.ibm.com/developerworks/library/l-embdev/index.html
阅读全文
摘要:Yo u c a n n o t s p e c i f y __GFP_HIGHMEM to either __get_free_pages() or kmalloc(). Because these both return a logical address, and not a page structure, it is possible that these functions woul...
阅读全文
摘要:CONFIG_MV_INTERNAL_REGS_SELECTIVE_MAPPING=y 选择映射内部寄存器(分散开,每个64K),否则映射1M寄存器空间 sysmap.c文件 #if defined(CONFIG_MV_INTERNAL_REGS_SELECTIVE_MAPPING) /* need to make sure it is big enough to hold all mapping...
阅读全文
摘要:Virtual Memory I: the problem http://en.wikipedia.org/wiki/High_memory http://lwn.net/Articles/75174/ [Posted March 10, 2004 by corbet] This article serves mostly as background to help understand why ...
阅读全文
摘要:原先一直都对Linux高端内存的管理认识模模糊糊的,可能主要是初次接触Linux kernel 是0.11版吧,当初的内存设计是16M,Linus对拥有32M的内存都是觊觎万分,1G内存恐怕是天方夜谭了。16M内存哪里还顾得上高端内存,脑子就一直没有这种概念。先我们还是来看看为什么要有高端内存? 80386的线性寻址空间是4G,内核空间从3G开始,如果全部采用"线性映射"(物理地址和逻辑地址只差一...
阅读全文
摘要:Linux内核访问外设I/O资源的方式 Author: Dongas Date: 08-08-02 我们知道默认外设I/O资源是不在Linux内核空间中的(如sram或硬件接口寄存器等),若需要访问该外设I/O资源,必须先将其地址映射到内核空间中来,然后才能在内核空间中访问它。 Linux内核访问外设I/O内存资源的方式有两种:动态映射(ioremap)和静态映射(map_desc)。 ...
阅读全文
摘要:__init和__initdata Linux在arch/$(ARCH)/kernel/vmlinux.lds中定义了.init段。__init和__initdata属性的数据都在这个段中,当内核启动完毕后,这个段中的内存会被释放掉供其他使用。 __init和__initdata宏定义如下: /* include/linux/init.c */ #define __init __attrib...
阅读全文
摘要:http://www.cublog.cn/u2/60011/showart_1010489.html MACHINE_START宏 linux2.6.18内核,在Mach-s3c2410.c文件中,有如下的宏定义: MACHINE_START(SMDK2410, "SMDK2410") /* @TODO: request a new identifier and switch to SMDK241...
阅读全文
摘要:About TEXTADDR, ZTEXTADDR, PAGE_OFFSET etc Initial definitions ------------------- The following symbol definitions rely on you knowing the translation that __virt_to_phys() does for your machine. Th...
阅读全文
摘要:Vmalloc可以获得的地址在VMALLOC_START到VMALLOC_END的范围中。这两个符号在<asm/pgtable.h>中定义: * arch/arm/include/asm/pgtable.h /* * Just any arbitrary offset to the start of the vmalloc VM area: the * current 8MB value just...
阅读全文
摘要:http://partner.atheros.com/Drivers.aspx 下载AR81Family Linux Driver
阅读全文
摘要:http://www.marvell.com/products/processors/embedded/kirkwood/ Mbus-Light (Mbus-L) separate interfaces to DDR controller and to Mbus bridge.
阅读全文
摘要:http://jiangjqian.blog.51cto.com/1040847/404097 分析发现uboot env的存储格式是,开始4个字节是crc32,后面是一个接一个\0结束的字符串,每个串都是envname=enavalue的格式。 挪用uboot部分的相关代码,实现以下函数: int set_env_ptr(unsigned char * ptr); char *get_env...
阅读全文
摘要:ther Component Systems Microsoft COM (and DCOM/COM+/.Net/MSMQ/ActiveX) Mozilla XPCOM theKompany Korelib TrollTech Qt Component Model Apache 1.x module API Apache 2.x hooks and modules API Mozilla/Nets...
阅读全文
摘要:Pulse Width Modulation -- 脉宽调制 /脉冲宽度调制 脉冲宽度调制(PWM)是利用微处理器的数字输出来对模拟电路进行控制的一种非常有效的技术,广泛应用在从测量、通信到功率控制与变换的许多领域中。脉宽调制是开关型稳压电源中的术语。这是按稳压的控制方式分类的,除了PWM型,还有PFM型和PWM、PFM混合型。脉宽调制式开关型稳压电路是在控制电路输出频率不变的情况下,通过电压反馈...
阅读全文
摘要:你的文件分隔符恐怕不止一个空格(一定的who生成的): 用awk: awk '{print $2}' file 一定要用cut的话: cat file|tr -s ' '|cut -d' ' -f2
阅读全文
摘要:please input the mac : 00:1A:A9:AA:BB:CC new mac for decrease is :00:1A:A9:AA:BB:CB new mac for increase is :00:1A:A9:AA:BB:CD #define BOOL int #define FALSE 0 #define TRUE 1 #include <stdio.h> #incl...
阅读全文
摘要:init –q int init_main(int argc UNUSED_PARAM, char **argv) { //init -q使init进程立即重新读取并处理文件inittab if (argv[1] && strcmp(argv[1], "-q") == 0) { return kill(1, SIGHUP); }
阅读全文
摘要:http://busybox.net/FAQ.html#job_control Job control will be turned off since your shell can not obtain a controlling terminal. This typically happens when you run your shell on /dev/console. The kerne...
阅读全文
摘要:http://blog.richliu.com/2010/01/20/843/ 以前都習慣用 printk 和 /proc 做輸入輸出的動作, 不過 debugfs 看起來是 User space 和 kernel space 交流更好的選擇. 先確認 Enable Kernel debugfs Function Kernel hacking —> -*- Debug Filesystem 先來個...
阅读全文
摘要:General informations The Linux kernel configuration item CONFIG_MTD_CMDLINE_PARTS has multiple definitions: drivers/mtd/Kconfig The configuration item CONFIG_MTD_CMDLINE_PARTS: prompt: Command line pa...
阅读全文
摘要:一、时区 1. 查看当前时区 date –R 2. 修改设置时区 cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime ntpd -p 192.168.74.36 -qNn hwclock –w 3.启动时从hwclock同步到sys 启动脚本加: hwclock –s marvell不加也可以,自动同步。。
阅读全文
摘要:DS28E01-100有四个存储区:数据存储器(EEPROM)(共分4页,每页32个字节)、密钥存储器(secret)(8字节)、含有特定功能和用户字节的寄存器页(register page)和易失性暂存器(scratchpad)(8字节)。 向数据存储器写数据、载入初始密钥或者向寄存器页写数据时,暂存器作为缓存使用。 The DS28E01-100 has four memory areas...
阅读全文
摘要:http://china.maxim-ic.com/glossary/definitions.mvp/terms/all 术语表:裸焊盘 (Exposed Pad) 定义有些封装具有裸露焊盘,用来改善器件散热的焊盘。通常为非电气绝缘,可根据电连接要求将其接地或电源。 同义词 EP 裸露底盘 关键词垫盘, 封装, 散热 术语表:收发器 (Transceiver) 定义同时含有发送器和接收器的器件。 ...
阅读全文