Hi,
I am learning to write Memory Mapped drivers in Linux. I thought a good place to start was writing a driver to directly access the NOR flash, as I know what it's contents should be already (contents of UBOOT).
My kernel object registers a char device (register_chrdev) and then uses request_mem_region to allocate a test memory area that's listed in /proc/iomem, at the address range I specify (0x0200 0000 to 0x0200 0FFF, the first page of NOR flash memory). I then use mmap (on a mknod 'node' char file) in the test app, and in the kernel object I use remap_pfn_range (in the mmap function pointer) to map my userspace memory onto the physical memory.
Trouble is I don't think it works. The memory I get back isn't as per UBOOT and it appears to change between runs.
Are there any examples of memory mapped drivers already in the DaVinci installation?
Will.