diff options
author | Jiri Slaby <jirislaby@gmail.com> | 2007-05-08 03:35:49 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-08 14:15:22 -0400 |
commit | ad39c3004971173baeca80173e77022ee03eb9a1 (patch) | |
tree | 9027afcf473ea62ab2ad01ad62938b36bcd6793c /drivers/char/cyclades.c | |
parent | b70509066cba24067757f1422c899c43e433429d (diff) |
Char: cyclades, remove volatiles
cyclades, remove volatiles
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char/cyclades.c')
-rw-r--r-- | drivers/char/cyclades.c | 52 |
1 files changed, 25 insertions, 27 deletions
diff --git a/drivers/char/cyclades.c b/drivers/char/cyclades.c index a035fb07acda..09249149d96f 100644 --- a/drivers/char/cyclades.c +++ b/drivers/char/cyclades.c | |||
@@ -967,7 +967,7 @@ do_softint(struct work_struct *work) | |||
967 | */ | 967 | */ |
968 | static int cyy_issue_cmd(void __iomem * base_addr, u_char cmd, int index) | 968 | static int cyy_issue_cmd(void __iomem * base_addr, u_char cmd, int index) |
969 | { | 969 | { |
970 | volatile int i; | 970 | unsigned int i; |
971 | 971 | ||
972 | /* Check to see that the previous command has completed */ | 972 | /* Check to see that the previous command has completed */ |
973 | for (i = 0; i < 100; i++) { | 973 | for (i = 0; i < 100; i++) { |
@@ -1043,7 +1043,7 @@ static void cyy_intr_chip(struct cyclades_card *cinfo, int chip, | |||
1043 | { | 1043 | { |
1044 | struct cyclades_port *info; | 1044 | struct cyclades_port *info; |
1045 | struct tty_struct *tty; | 1045 | struct tty_struct *tty; |
1046 | volatile int char_count; | 1046 | int char_count; |
1047 | int i, j, len, mdm_change, mdm_status, outch; | 1047 | int i, j, len, mdm_change, mdm_status, outch; |
1048 | int save_xir, channel, save_car; | 1048 | int save_xir, channel, save_car; |
1049 | char data; | 1049 | char data; |
@@ -1551,20 +1551,19 @@ cyz_issue_cmd(struct cyclades_card *cinfo, | |||
1551 | } /* cyz_issue_cmd */ | 1551 | } /* cyz_issue_cmd */ |
1552 | 1552 | ||
1553 | static void | 1553 | static void |
1554 | cyz_handle_rx(struct cyclades_port *info, | 1554 | cyz_handle_rx(struct cyclades_port *info, struct CH_CTRL __iomem *ch_ctrl, |
1555 | volatile struct CH_CTRL __iomem * ch_ctrl, | 1555 | struct BUF_CTRL __iomem *buf_ctrl) |
1556 | volatile struct BUF_CTRL __iomem * buf_ctrl) | ||
1557 | { | 1556 | { |
1558 | struct cyclades_card *cinfo = &cy_card[info->card]; | 1557 | struct cyclades_card *cinfo = &cy_card[info->card]; |
1559 | struct tty_struct *tty = info->tty; | 1558 | struct tty_struct *tty = info->tty; |
1560 | volatile int char_count; | 1559 | int char_count; |
1561 | int len; | 1560 | int len; |
1562 | #ifdef BLOCKMOVE | 1561 | #ifdef BLOCKMOVE |
1563 | int small_count; | 1562 | int small_count; |
1564 | #else | 1563 | #else |
1565 | char data; | 1564 | char data; |
1566 | #endif | 1565 | #endif |
1567 | volatile __u32 rx_put, rx_get, new_rx_get, rx_bufsize, rx_bufaddr; | 1566 | __u32 rx_put, rx_get, new_rx_get, rx_bufsize, rx_bufaddr; |
1568 | 1567 | ||
1569 | rx_get = new_rx_get = readl(&buf_ctrl->rx_get); | 1568 | rx_get = new_rx_get = readl(&buf_ctrl->rx_get); |
1570 | rx_put = readl(&buf_ctrl->rx_put); | 1569 | rx_put = readl(&buf_ctrl->rx_put); |
@@ -1648,18 +1647,17 @@ cyz_handle_rx(struct cyclades_port *info, | |||
1648 | } | 1647 | } |
1649 | 1648 | ||
1650 | static void | 1649 | static void |
1651 | cyz_handle_tx(struct cyclades_port *info, | 1650 | cyz_handle_tx(struct cyclades_port *info, struct CH_CTRL __iomem *ch_ctrl, |
1652 | volatile struct CH_CTRL __iomem * ch_ctrl, | 1651 | struct BUF_CTRL __iomem *buf_ctrl) |
1653 | volatile struct BUF_CTRL __iomem * buf_ctrl) | ||
1654 | { | 1652 | { |
1655 | struct cyclades_card *cinfo = &cy_card[info->card]; | 1653 | struct cyclades_card *cinfo = &cy_card[info->card]; |
1656 | struct tty_struct *tty = info->tty; | 1654 | struct tty_struct *tty = info->tty; |
1657 | char data; | 1655 | char data; |
1658 | volatile int char_count; | 1656 | int char_count; |
1659 | #ifdef BLOCKMOVE | 1657 | #ifdef BLOCKMOVE |
1660 | int small_count; | 1658 | int small_count; |
1661 | #endif | 1659 | #endif |
1662 | volatile __u32 tx_put, tx_get, tx_bufsize, tx_bufaddr; | 1660 | __u32 tx_put, tx_get, tx_bufsize, tx_bufaddr; |
1663 | 1661 | ||
1664 | if (info->xmit_cnt <= 0) /* Nothing to transmit */ | 1662 | if (info->xmit_cnt <= 0) /* Nothing to transmit */ |
1665 | return; | 1663 | return; |
@@ -1739,11 +1737,11 @@ static void cyz_handle_cmd(struct cyclades_card *cinfo) | |||
1739 | { | 1737 | { |
1740 | struct tty_struct *tty; | 1738 | struct tty_struct *tty; |
1741 | struct cyclades_port *info; | 1739 | struct cyclades_port *info; |
1742 | static volatile struct FIRM_ID __iomem *firm_id; | 1740 | static struct FIRM_ID __iomem *firm_id; |
1743 | static volatile struct ZFW_CTRL __iomem *zfw_ctrl; | 1741 | static struct ZFW_CTRL __iomem *zfw_ctrl; |
1744 | static volatile struct BOARD_CTRL __iomem *board_ctrl; | 1742 | static struct BOARD_CTRL __iomem *board_ctrl; |
1745 | static volatile struct CH_CTRL __iomem *ch_ctrl; | 1743 | static struct CH_CTRL __iomem *ch_ctrl; |
1746 | static volatile struct BUF_CTRL __iomem *buf_ctrl; | 1744 | static struct BUF_CTRL __iomem *buf_ctrl; |
1747 | __u32 channel; | 1745 | __u32 channel; |
1748 | __u8 cmd; | 1746 | __u8 cmd; |
1749 | __u32 param; | 1747 | __u32 param; |
@@ -1900,11 +1898,11 @@ static void cyz_poll(unsigned long arg) | |||
1900 | struct cyclades_card *cinfo; | 1898 | struct cyclades_card *cinfo; |
1901 | struct cyclades_port *info; | 1899 | struct cyclades_port *info; |
1902 | struct tty_struct *tty; | 1900 | struct tty_struct *tty; |
1903 | static volatile struct FIRM_ID *firm_id; | 1901 | static struct FIRM_ID *firm_id; |
1904 | static volatile struct ZFW_CTRL *zfw_ctrl; | 1902 | static struct ZFW_CTRL *zfw_ctrl; |
1905 | static volatile struct BOARD_CTRL *board_ctrl; | 1903 | static struct BOARD_CTRL *board_ctrl; |
1906 | static volatile struct CH_CTRL *ch_ctrl; | 1904 | static struct CH_CTRL *ch_ctrl; |
1907 | static volatile struct BUF_CTRL *buf_ctrl; | 1905 | static struct BUF_CTRL *buf_ctrl; |
1908 | unsigned long expires = jiffies + HZ; | 1906 | unsigned long expires = jiffies + HZ; |
1909 | int card, port; | 1907 | int card, port; |
1910 | 1908 | ||
@@ -3003,12 +3001,12 @@ static int cy_chars_in_buffer(struct tty_struct *tty) | |||
3003 | return info->xmit_cnt; | 3001 | return info->xmit_cnt; |
3004 | #ifdef Z_EXT_CHARS_IN_BUFFER | 3002 | #ifdef Z_EXT_CHARS_IN_BUFFER |
3005 | } else { | 3003 | } else { |
3006 | static volatile struct FIRM_ID *firm_id; | 3004 | static struct FIRM_ID *firm_id; |
3007 | static volatile struct ZFW_CTRL *zfw_ctrl; | 3005 | static struct ZFW_CTRL *zfw_ctrl; |
3008 | static volatile struct CH_CTRL *ch_ctrl; | 3006 | static struct CH_CTRL *ch_ctrl; |
3009 | static volatile struct BUF_CTRL *buf_ctrl; | 3007 | static struct BUF_CTRL *buf_ctrl; |
3010 | int char_count; | 3008 | int char_count; |
3011 | volatile __u32 tx_put, tx_get, tx_bufsize; | 3009 | __u32 tx_put, tx_get, tx_bufsize; |
3012 | 3010 | ||
3013 | firm_id = cy_card[card].base_addr + ID_ADDRESS; | 3011 | firm_id = cy_card[card].base_addr + ID_ADDRESS; |
3014 | zfw_ctrl = cy_card[card].base_addr + | 3012 | zfw_ctrl = cy_card[card].base_addr + |