Skip to content

Commit

Permalink
Input: adxl34x - Fix bug in definition of ADXL346_2D_ORIENT
Browse files Browse the repository at this point in the history
Coverity report pointet out by Dmitry

Reported-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
  • Loading branch information
Michael Hennerich authored and Dmitry Torokhov committed Dec 10, 2013
1 parent e696c68 commit 241ecf1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/input/misc/adxl34x.c
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@

/* ORIENT ADXL346 only */
#define ADXL346_2D_VALID (1 << 6)
#define ADXL346_2D_ORIENT(x) (((x) & 0x3) >> 4)
#define ADXL346_2D_ORIENT(x) (((x) & 0x30) >> 4)
#define ADXL346_3D_VALID (1 << 3)
#define ADXL346_3D_ORIENT(x) ((x) & 0x7)
#define ADXL346_2D_PORTRAIT_POS 0 /* +X */
Expand Down

0 comments on commit 241ecf1

Please sign in to comment.