Skip to content
Commit 257d6ef4 authored by Jose Manuel Alarcon Roldan's avatar Jose Manuel Alarcon Roldan Committed by Linus Torvalds
Browse files

Documentation: i2c: rename variable "register" to "reg"



The example code provided with the i2c device interface documentation
won't compile since it uses the reserved word "register" to name a
variable.

The compiler fails with this error message:

 error: expected identifier or '(' before '=' token
   __u8 register = 0x20; /* Device register to access */
                 ^

Rename the variable "register" to simply "reg" in the example code.

Another couple of typos has been fixed as well.
[Change "! =" to "!=".]

Signed-off-by: default avatarJose Alarcon Roldan <jose.alarcon.roldan@gmail.com>
Signed-off-by: default avatarRandy Dunlap <rdunlap@infradead.org>
Acked-by: default avatarWolfram Sang <wsa@the-dreams.de>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 77be4daf
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment