-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'sh-latest' of git://git.kernel.org/pub/scm/linux/kernel…
…/git/lethal/sh-3.x * 'sh-latest' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-3.x: (39 commits) SH: static should be at beginning of declaration sh: move CLKDEV_xxx_ID macro to sh_clk.h sh: clock-shx3: add CLKDEV_ICK_ID for cleanup sh: clock-sh7786: add CLKDEV_ICK_ID for cleanup sh: clock-sh7785: add CLKDEV_ICK_ID for cleanup sh: clock-sh7757: add CLKDEV_ICK_ID for cleanup sh: clock-sh7366: add CLKDEV_ICK_ID for cleanup sh: clock-sh7343: add CLKDEV_ICK_ID for cleanup sh: clock-sh7722: add CLKDEV_ICK_ID for cleanup sh: clock-sh7724: add CLKDEV_ICK_ID for cleanup sh: clock-sh7366: modify I2C clock settings sh: clock-sh7343: modify I2C clock settings sh: clock-sh7723: modify I2C clock settings sh: clock-sh7722: modify I2C clock settings sh: clock-sh7724: modify I2C clock settings serial: sh-sci: Fix up pretty name printing for port IRQs. serial: sh-sci: Kill off per-port enable/disable callbacks. serial: sh-sci: Add missing module description/author bits. serial: sh-sci: Regtype probing doesn't need to be fatal. sh: Tidy up pre-clkdev clk_get() error handling. ...
- Loading branch information
Showing
54 changed files
with
962 additions
and
1,188 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#ifndef __CPU_SH3_SERIAL_H | ||
#define __CPU_SH3_SERIAL_H | ||
|
||
#include <linux/serial_sci.h> | ||
|
||
extern struct plat_sci_port_ops sh770x_sci_port_ops; | ||
extern struct plat_sci_port_ops sh7710_sci_port_ops; | ||
extern struct plat_sci_port_ops sh7720_sci_port_ops; | ||
|
||
#endif /* __CPU_SH3_SERIAL_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#ifndef __CPU_SH4A_SERIAL_H | ||
#define __CPU_SH4A_SERIAL_H | ||
|
||
/* arch/sh/kernel/cpu/sh4a/serial-sh7722.c */ | ||
extern struct plat_sci_port_ops sh7722_sci_port_ops; | ||
|
||
#endif /* __CPU_SH4A_SERIAL_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#include <linux/serial_sci.h> | ||
#include <linux/serial_core.h> | ||
#include <linux/io.h> | ||
#include <cpu/serial.h> | ||
|
||
#define SCPCR 0xA4000116 | ||
#define SCPDR 0xA4000136 | ||
|
||
static void sh770x_sci_init_pins(struct uart_port *port, unsigned int cflag) | ||
{ | ||
unsigned short data; | ||
|
||
/* We need to set SCPCR to enable RTS/CTS */ | ||
data = __raw_readw(SCPCR); | ||
/* Clear out SCP7MD1,0, SCP6MD1,0, SCP4MD1,0*/ | ||
__raw_writew(data & 0x0fcf, SCPCR); | ||
|
||
if (!(cflag & CRTSCTS)) { | ||
/* We need to set SCPCR to enable RTS/CTS */ | ||
data = __raw_readw(SCPCR); | ||
/* Clear out SCP7MD1,0, SCP4MD1,0, | ||
Set SCP6MD1,0 = {01} (output) */ | ||
__raw_writew((data & 0x0fcf) | 0x1000, SCPCR); | ||
|
||
data = __raw_readb(SCPDR); | ||
/* Set /RTS2 (bit6) = 0 */ | ||
__raw_writeb(data & 0xbf, SCPDR); | ||
} | ||
} | ||
|
||
struct plat_sci_port_ops sh770x_sci_port_ops = { | ||
.init_pins = sh770x_sci_init_pins, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#include <linux/serial_sci.h> | ||
#include <linux/serial_core.h> | ||
#include <linux/io.h> | ||
#include <cpu/serial.h> | ||
|
||
#define PACR 0xa4050100 | ||
#define PBCR 0xa4050102 | ||
|
||
static void sh7710_sci_init_pins(struct uart_port *port, unsigned int cflag) | ||
{ | ||
if (port->mapbase == 0xA4400000) { | ||
__raw_writew(__raw_readw(PACR) & 0xffc0, PACR); | ||
__raw_writew(__raw_readw(PBCR) & 0x0fff, PBCR); | ||
} else if (port->mapbase == 0xA4410000) | ||
__raw_writew(__raw_readw(PBCR) & 0xf003, PBCR); | ||
} | ||
|
||
struct plat_sci_port_ops sh7710_sci_port_ops = { | ||
.init_pins = sh7710_sci_init_pins, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#include <linux/serial_sci.h> | ||
#include <linux/serial_core.h> | ||
#include <linux/io.h> | ||
#include <cpu/serial.h> | ||
#include <asm/gpio.h> | ||
|
||
static void sh7720_sci_init_pins(struct uart_port *port, unsigned int cflag) | ||
{ | ||
unsigned short data; | ||
|
||
if (cflag & CRTSCTS) { | ||
/* enable RTS/CTS */ | ||
if (port->mapbase == 0xa4430000) { /* SCIF0 */ | ||
/* Clear PTCR bit 9-2; enable all scif pins but sck */ | ||
data = __raw_readw(PORT_PTCR); | ||
__raw_writew((data & 0xfc03), PORT_PTCR); | ||
} else if (port->mapbase == 0xa4438000) { /* SCIF1 */ | ||
/* Clear PVCR bit 9-2 */ | ||
data = __raw_readw(PORT_PVCR); | ||
__raw_writew((data & 0xfc03), PORT_PVCR); | ||
} | ||
} else { | ||
if (port->mapbase == 0xa4430000) { /* SCIF0 */ | ||
/* Clear PTCR bit 5-2; enable only tx and rx */ | ||
data = __raw_readw(PORT_PTCR); | ||
__raw_writew((data & 0xffc3), PORT_PTCR); | ||
} else if (port->mapbase == 0xa4438000) { /* SCIF1 */ | ||
/* Clear PVCR bit 5-2 */ | ||
data = __raw_readw(PORT_PVCR); | ||
__raw_writew((data & 0xffc3), PORT_PVCR); | ||
} | ||
} | ||
} | ||
|
||
struct plat_sci_port_ops sh7720_sci_port_ops = { | ||
.init_pins = sh7720_sci_init_pins, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.