Skip to content

Commit

Permalink
FB: sa11x0: fix shannon GPSR/GPCR accesses
Browse files Browse the repository at this point in the history
The GPIO set and clear registers should only be written, rather than
read, modified, and written.  A read-modify-write will have undesired
side effects.

Acked-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Russell King committed Feb 21, 2012
1 parent 058502e commit 9bb13ee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/video/sa1100fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -798,7 +798,7 @@ static void sa1100fb_enable_controller(struct sa1100fb_info *fbi)

if (machine_is_shannon()) {
GPDR |= SHANNON_GPIO_DISP_EN;
GPSR |= SHANNON_GPIO_DISP_EN;
GPSR = SHANNON_GPIO_DISP_EN;
}

dev_dbg(fbi->dev, "DBAR1 = 0x%08lx\n", DBAR1);
Expand All @@ -816,7 +816,7 @@ static void sa1100fb_disable_controller(struct sa1100fb_info *fbi)
dev_dbg(fbi->dev, "Disabling LCD controller\n");

if (machine_is_shannon()) {
GPCR |= SHANNON_GPIO_DISP_EN;
GPCR = SHANNON_GPIO_DISP_EN;
}

set_current_state(TASK_UNINTERRUPTIBLE);
Expand Down

0 comments on commit 9bb13ee

Please sign in to comment.