Am Samstag 28 April 2007 01:19 schrieb Alan Cox:I reviewed the code once more and find it OK. There is only one legal value for the parameter "count" of uio_read(), and that's sizeof(int). The data that is actually read is the element "event" of struct uio_device, which is of type atomic_t. The latter has the size of an int. Unfortunately, the fact that the read count _must_ be sizeof(int) is not mentioned in the documentation. I'll send a patch for that ASAP. This patch should fix it: Index: linux-2.6.22-rc/drivers/uio/uio.c =================================================================== --- linux-2.6.22-rc.orig/drivers/uio/uio.c 2007-04-28 20:01:02.000000000 +0200 +++ linux-2.6.22-rc/drivers/uio/uio.c 2007-04-28 20:15:00.000000000 +0200 @@ -633,6 +633,8 @@ if (ret) goto err_uio_dev_add_attributes; + info->uio_dev = idev; + if (idev->info->irq >= 0) { ret = request_irq(idev->info->irq, uio_interrupt, idev->info->irq_flags, idev->info->name, idev); @@ -640,7 +642,6 @@ goto err_request_irq; } - info->uio_dev = idev; return 0; err_request_irq: Thanks for your review, Hans -
| Amit K. Arora | [RFC] Heads up on sys_fallocate() |
| Linus Torvalds | Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series.. |
| Paul Jackson | Re: cpuset-remove-sched-domain-hooks-from-cpusets |
| Greg KH | [GIT PATCH] driver core patches against 2.6.24 |
git: | |
| Linus Torvalds | Re: [GIT]: Networking |
| David Miller | Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| David Miller | Re: [klibc] [patch] import socket defines |
