Patch "xtensa: xtfpga: fix hardware lockup caused by LCD driver" has been added to the 3.19-stable tree
Subsystems (2)
This is a note to let you know that I've just added the patch titled
xtensa: xtfpga: fix hardware lockup caused by LCD driver
to the 3.19-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
xtensa-xtfpga-fix-hardware-lockup-caused-by-lcd-driver.patch
and it can be found in the queue-3.19 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
4949009eb8d40a441dcddcd96e101e77d31cf1b2Mon Sep 17 00:00:00 2001
From: Max Filippov <[email protected]>
Date: Fri, 27 Feb 2015 06:28:00 +0300
Subject: xtensa: xtfpga: fix hardware lockup caused by LCD driver
From: Max Filippov <[email protected]>
commit 4949009eb8d40a441dcddcd96e101e77d31cf1b2 upstream.
LCD driver is always built for the XTFPGA platform, but its base address is not configurable, and is wrong for ML605/KC705. Its initialization locks up KC705 board hardware.
Make the whole driver optional, and its base address and bus width configurable. Implement 4-bit bus access method.
--- arch/xtensa/Kconfig | 30 ++++++++ arch/xtensa/platforms/xtfpga/Makefile | 3 arch/xtensa/platforms/xtfpga/include/platform/hardware.h | 3 arch/xtensa/platforms/xtfpga/include/platform/lcd.h | 15 ++++ arch/xtensa/platforms/xtfpga/lcd.c | 55 +++++++++------ 5 files changed, 81 insertions(+), 25 deletions(-)
arch/xtensa/Kconfig +30 -0
@@ -428,6 +428,36 @@ config DEFAULT_MEM_SIZE If unsure, leave the default value here. +config XTFPGA_LCD + bool "Enable XTFPGA LCD driver" + depends on XTENSA_PLATFORM_XTFPGA + default n + help + There's a 2x16 LCD on most of XTFPGA boards, kernel may output + progress messages there during bootup/shutdown. It may be useful + during board bringup. + + If unsure, say N. + +config XTFPGA_LCD_BASE_ADDR + hex "XTFPGA LCD base address" + depends on XTFPGA_LCD + default "0x0d0c0000" + help + Base address of the LCD controller inside KIO region. + Different boards from XTFPGA family have LCD controller at different + addresses. Please consult prototyping user guide for your board for + the correct address. Wrong address here may lead to hardware lockup. + +config XTFPGA_LCD_8BIT_ACCESS + bool "Use 8-bit access to XTFPGA LCD" + depends on XTFPGA_LCD + default n + help + LCD may be connected with 4- or 8-bit interface, 8-bit access may + only be used with 8-bit interface. Please consult prototyping user + guide for your board for the correct interface width. + endmenu menu "Executable file formats"
arch/xtensa/platforms/xtfpga/Makefile +2 -1
@@ -6,4 +6,5 @@ # # Note 2! The CFLAGS definitions are in the main makefile... -obj-y = setup.o lcd.o +obj-y += setup.o +obj-$(CONFIG_XTFPGA_LCD) += lcd.o
arch/xtensa/platforms/xtfpga/include/platform/hardware.h +0 -3
@@ -40,9 +40,6 @@/* UART */ #define DUART16552_PADDR (XCHAL_KIO_PADDR + 0x0D050020) -/* LCD instruction and data addresses. */ -#define LCD_INSTR_ADDR ((char *)IOADDR(0x0D040000)) -#define LCD_DATA_ADDR ((char *)IOADDR(0x0D040004))/* Misc. */ #define XTFPGA_FPGAREGS_VADDR IOADDR(0x0D020000)
arch/xtensa/platforms/xtfpga/include/platform/lcd.h +15 -0
@@ -11,10 +11,25 @@#ifndef __XTENSA_XTAVNET_LCD_H#define __XTENSA_XTAVNET_LCD_H +#ifdef CONFIG_XTFPGA_LCD /* Display string STR at position POS on the LCD. */ void lcd_disp_at_pos (char *str,unsigned char pos);/* Shift the contents of the LCD display left or right. */ void lcd_shiftleft (void );void lcd_shiftright (void ); +#else +static inline void lcd_disp_at_pos (char *str,unsigned char pos) +{ +} + +static inline void lcd_shiftleft (void ) +{ +} + +static inline void lcd_shiftright (void ) +{ +} +#endif +#endif
arch/xtensa/platforms/xtfpga/lcd.c +34 -21
107 lines not on this page · raw message
Patches currently in stable-queue which might be from [email protected] are
queue-3.19/xtensa-iss-fix-locking-in-tap-network-adapter.patch queue-3.19/xtensa-xtfpga-fix-hardware-lockup-caused-by-lcd-driver.patch queue-3.19/xtensa-provide-__nr_sync_file_range2-instead-of-__nr_sync_file_range.patch