[PATCH 14/17] FRV: Stop the IEEE1394 nodemanager from accessing sem count directly

From: David Howells
Date: Fri Jan 06 2006 - 11:37:19 EST


The attached patch stops the IEEE1394 nodemanager from accessing the internals
of a semaphore directly. On the FRV arch, what it does does not work, and
there's a macro for doing what it wants.

Signed-Off-By: David Howells <dhowells@xxxxxxxxxx>
---
warthog>diffstat -p1 ieee1394-2615.diff
drivers/ieee1394/nodemgr.c | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)

diff -uNrp /warthog/kernels/linux-2.6.15/drivers/ieee1394/nodemgr.c linux-2.6.15-frv/drivers/ieee1394/nodemgr.c
--- /warthog/kernels/linux-2.6.15/drivers/ieee1394/nodemgr.c 2006-01-04 12:39:26.000000000 +0000
+++ linux-2.6.15-frv/drivers/ieee1394/nodemgr.c 2006-01-06 14:43:43.000000000 +0000
@@ -284,7 +284,7 @@ static DEVICE_ATTR(bus_options,S_IRUGO,f
static ssize_t fw_show_ne_tlabels_free(struct device *dev, struct device_attribute *attr, char *buf)
{
struct node_entry *ne = container_of(dev, struct node_entry, device);
- return sprintf(buf, "%d\n", atomic_read(&ne->tpool->count.count) + 1);
+ return sprintf(buf, "%d\n", sem_getcount(&ne->tpool->count) + 1);
}
static DEVICE_ATTR(tlabels_free,S_IRUGO,fw_show_ne_tlabels_free,NULL);

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/