bdevname(), cdevname(), kdevname() - static buffers

From: Russ Weight (rweight@us.ibm.com)
Date: Fri Nov 02 2001 - 13:42:11 EST


Hi,

I was looking at the usage of bdevname(), cdevname(), and kdevname(),
and noticed that they each return a pointer to a static buffer.
This buffer contains a formatted device name, which is typically
printed immediately following the call. However, I don't see any
explicit lock protection for these buffers.

For SMP systems, is there something implicit in their use that
prevents a race on these buffers? Has anyone seen garbled device
names being printed (which might be attributed to a race)?

- Russ

     ----------------------------------------------------------------------

Russ Weight (rweight@us.ibm.com)
IBM Technology Center
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Nov 07 2001 - 21:00:19 EST