Re: Using uio_pdrv to create an platform device for an FPGA, mmap() fails

2012-08-31 Thread Hans J. Koch
On Thu, Aug 30, 2012 at 11:03:04PM +, Worth, Kevin wrote: > > > >> but the code seems like > >> possibly useful sample/example code. > > > >That is another good argument. > > Perhaps this could be genericized to be a generic "Memory Map Userspace > IO Device" that takes a base address and a l

RE: Using uio_pdrv to create an platform device for an FPGA, mmap() fails

2012-08-30 Thread Worth, Kevin
>[Added Greg Kroah-Hartman to Cc:] > >On Thu, Aug 30, 2012 at 08:10:11PM +, Worth, Kevin wrote: >> >> Thanks for the reply, Hans. Your question about opening /dev/uio0 O_RDWR >> >> prompted me to check out how I was creating /dev/uio0 ... my system >> >> isn't using udev, and I was accidentall

Re: Using uio_pdrv to create an platform device for an FPGA, mmap() fails

2012-08-30 Thread Hans J. Koch
[Added Greg Kroah-Hartman to Cc:] On Thu, Aug 30, 2012 at 08:10:11PM +, Worth, Kevin wrote: > >> Thanks for the reply, Hans. Your question about opening /dev/uio0 O_RDWR > >> prompted me to check out how I was creating /dev/uio0 ... my system > >> isn't using udev, and I was accidentally creat

RE: Using uio_pdrv to create an platform device for an FPGA, mmap() fails

2012-08-30 Thread Worth, Kevin
>> Thanks for the reply, Hans. Your question about opening /dev/uio0 O_RDWR >> prompted me to check out how I was creating /dev/uio0 ... my system >> isn't using udev, and I was accidentally creating it with major/minor >> number 254/0 instead of the correct 253/0 (found by looking at >> /proc/devi

Re: Using uio_pdrv to create an platform device for an FPGA, mmap() fails

2012-08-30 Thread Hans J. Koch
On Thu, Aug 30, 2012 at 06:36:53PM +, Worth, Kevin wrote: > Thanks for the reply, Hans. Your question about opening /dev/uio0 O_RDWR > prompted me to check out how I was creating /dev/uio0 ... my system > isn't using udev, and I was accidentally creating it with major/minor > number 254/0 inste

RE: Using uio_pdrv to create an platform device for an FPGA, mmap() fails

2012-08-30 Thread Worth, Kevin
Thanks for the reply, Hans. Your question about opening /dev/uio0 O_RDWR prompted me to check out how I was creating /dev/uio0 ... my system isn't using udev, and I was accidentally creating it with major/minor number 254/0 instead of the correct 253/0 (found by looking at /proc/devices). Fixed tha

Re: Using uio_pdrv to create an platform device for an FPGA, mmap() fails

2012-08-29 Thread Hans J. Koch
[Added driver author to Cc:] On Wed, Aug 29, 2012 at 11:19:00PM +, Worth, Kevin wrote: > I have below what appears to be a mostly-functional device using the UIO > Platform Driver. The /sys entries I'd expect appear, /proc/iomem contains " > d000-dfff : myfpga", and lsuio sees the p