Skip to content

Commit

Permalink
HID: alps: Fix some style in 't4_read_write_register()'
Browse files Browse the repository at this point in the history
Better indent the code to improve readability.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
  • Loading branch information
Christophe JAILLET authored and Jiri Kosina committed Apr 26, 2018
1 parent 6993401 commit a317e55
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/hid/hid-alps.c
Original file line number Diff line number Diff line change
Expand Up @@ -223,20 +223,20 @@ static int t4_read_write_register(struct hid_device *hdev, u32 address,

if (*(u32 *)&readbuf[6] != address) {
dev_err(&hdev->dev, "read register address error (%x,%x)\n",
*(u32 *)&readbuf[6], address);
*(u32 *)&readbuf[6], address);
goto exit_readbuf;
}

if (*(u16 *)&readbuf[10] != 1) {
dev_err(&hdev->dev, "read register size error (%x)\n",
*(u16 *)&readbuf[10]);
*(u16 *)&readbuf[10]);
goto exit_readbuf;
}

check_sum = t4_calc_check_sum(readbuf, 6, 7);
if (*(u16 *)&readbuf[13] != check_sum) {
dev_err(&hdev->dev, "read register checksum error (%x,%x)\n",
*(u16 *)&readbuf[13], check_sum);
*(u16 *)&readbuf[13], check_sum);
goto exit_readbuf;
}

Expand Down

0 comments on commit a317e55

Please sign in to comment.