引用楼主 musi11630029 的回复:
如题:将android-linux-2.6.28的系统移植到s3c6410开发板上usb不能用
编译通过,初始化也通过,可是一插上U盘就报错:
提示错误:
usb 1-1: new full speed USB device using s3c2410-ohci and address 2
usb 1-1: device descriptor read/64, error -62
usb……
引用 18 楼 jjyyhema 的回复:
引用 17 楼 wlc311 的回复:
可否用VirtualAlloc?
LPVOID VirtualAlloc(
LPVOID lpAddress, // region to reserve or commit
SIZE_T dwSize, // size of region
DWORD flAllocationType, // type of allocation
DWORD flProtect // type of access protection
);
lpAddress 指定了一个虚拟基地址,不知是否会出错,还没试,明天试试
不用试的,肯定不可以。你看下MmMapIoSpace就源码就知道,这个函数就是用VirtualAlloc和VirtualCopy实现的,只不过MmMapIoSpace实现了地址自动对齐