Commit b8ac9fc0e8cda9f9776019c5b0464b0c6d2d4c90
Committed by
Greg Kroah-Hartman
1 parent
a2ab3d3000
Exists in
master
and in
39 other branches
uio: make uio_info's name and version const
These are only ever assigned constant strings and never modified. This was noticed because Wolfram Sang needed to cast the result of of_get_property() in order to assign it to the name field of a struct uio_info. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Hans J. Koch <hjk@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Showing 2 changed files with 4 additions and 4 deletions Side-by-side Diff
Documentation/DocBook/uio-howto.tmpl
... | ... | @@ -393,12 +393,12 @@ |
393 | 393 | |
394 | 394 | <itemizedlist> |
395 | 395 | <listitem><para> |
396 | -<varname>char *name</varname>: Required. The name of your driver as | |
396 | +<varname>const char *name</varname>: Required. The name of your driver as | |
397 | 397 | it will appear in sysfs. I recommend using the name of your module for this. |
398 | 398 | </para></listitem> |
399 | 399 | |
400 | 400 | <listitem><para> |
401 | -<varname>char *version</varname>: Required. This string appears in | |
401 | +<varname>const char *version</varname>: Required. This string appears in | |
402 | 402 | <filename>/sys/class/uio/uioX/version</filename>. |
403 | 403 | </para></listitem> |
404 | 404 |
include/linux/uio_driver.h