Commit 3c0fcb5
serial: sh-sci: Fix panic when serial console and DMA are enabled
commit 3c9101766b502a0163d1d437fada5801cf616be2 upstream.
This patch fixes an issue that kernel panic happens when DMA is enabled
and we press enter key while the kernel booting on the serial console.
* An interrupt may occur after sci_request_irq().
* DMA transfer area is initialized by setup_timer() in sci_request_dma()
and used in interrupt.
If an interrupt occurred between sci_request_irq() and setup_timer() in
sci_request_dma(), DMA transfer area has not been initialized yet.
So, this patch changes the order of sci_request_irq() and
sci_request_dma().
Fixes: 73a19e4 ("serial: sh-sci: Add DMA support.")
Signed-off-by: Takatoshi Akiyama <takatoshi.akiyama.kj@ps.hitachi-solutions.com>
[Shimoda changes the commit log]
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Cc: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent cc04a14 commit 3c0fcb5
1 file changed
Lines changed: 6 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1800 | 1800 | | |
1801 | 1801 | | |
1802 | 1802 | | |
| 1803 | + | |
| 1804 | + | |
1803 | 1805 | | |
1804 | | - | |
| 1806 | + | |
| 1807 | + | |
1805 | 1808 | | |
1806 | | - | |
1807 | | - | |
| 1809 | + | |
1808 | 1810 | | |
1809 | 1811 | | |
1810 | 1812 | | |
| |||
1834 | 1836 | | |
1835 | 1837 | | |
1836 | 1838 | | |
1837 | | - | |
1838 | 1839 | | |
| 1840 | + | |
1839 | 1841 | | |
1840 | 1842 | | |
1841 | 1843 | | |
| |||
0 commit comments