mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
[POWERPC] Move CPM command handling into the cpm drivers
This patch moves the CPM command handling into commproc.c for CPM1 and cpm2_common.c. This is yet another preparation to get rid of drivers accessing the CPM via the global cpmp. Signed-off-by: Jochen Friedrich <[email protected]> Acked-by: Scott Wood <[email protected]> Acked-by: Arnd Bergmann <[email protected]> Signed-off-by: Vitaly Bordug <[email protected]>
This commit is contained in:
parent
721c0c8af1
commit
362f9b6fa8
7 changed files with 58 additions and 31 deletions
|
|
@ -52,11 +52,7 @@
|
|||
#ifdef CONFIG_PPC_CPM_NEW_BINDING
|
||||
void cpm_line_cr_cmd(struct uart_cpm_port *port, int cmd)
|
||||
{
|
||||
u16 __iomem *cpcr = &cpmp->cp_cpcr;
|
||||
|
||||
out_be16(cpcr, port->command | (cmd << 8) | CPM_CR_FLG);
|
||||
while (in_be16(cpcr) & CPM_CR_FLG)
|
||||
;
|
||||
cpm_command(port->command, cmd);
|
||||
}
|
||||
#else
|
||||
void cpm_line_cr_cmd(struct uart_cpm_port *port, int cmd)
|
||||
|
|
|
|||
|
|
@ -52,13 +52,7 @@
|
|||
#ifdef CONFIG_PPC_CPM_NEW_BINDING
|
||||
void cpm_line_cr_cmd(struct uart_cpm_port *port, int cmd)
|
||||
{
|
||||
cpm_cpm2_t __iomem *cp = cpm2_map(im_cpm);
|
||||
|
||||
out_be32(&cp->cp_cpcr, port->command | cmd | CPM_CR_FLG);
|
||||
while (in_be32(&cp->cp_cpcr) & CPM_CR_FLG)
|
||||
;
|
||||
|
||||
cpm2_unmap(cp);
|
||||
cpm_command(port->command, cmd);
|
||||
}
|
||||
#else
|
||||
void cpm_line_cr_cmd(struct uart_cpm_port *port, int cmd)
|
||||
|
|
|
|||
Loading…
Reference in a new issue