aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/atm
diff options
context:
space:
mode:
authorRickard Strandqvist <rickard_strandqvist@spectrumdigital.se>2015-01-13 13:50:21 -0500
committerDavid S. Miller <davem@davemloft.net>2015-01-13 17:28:19 -0500
commit8bdda5ddd1f1590ae24002749adb72693b80baaf (patch)
tree65865befcf66432b09d4d45df44fcc5006d37628 /drivers/atm
parent927a97ccd25b67a80bfe8476fc08866fd4be2fc9 (diff)
atm: horizon: Remove some unused functions
Removes some functions that are not used anywhere: channel_to_vpivci() query_tx_channel_config() rx_disabled_handler() This was partially found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/atm')
-rw-r--r--drivers/atm/horizon.c24
1 files changed, 0 insertions, 24 deletions
diff --git a/drivers/atm/horizon.c b/drivers/atm/horizon.c
index 1dc0519333f2..527bbd595e37 100644
--- a/drivers/atm/horizon.c
+++ b/drivers/atm/horizon.c
@@ -458,12 +458,6 @@ static inline void update_tx_channel_config (hrz_dev * dev, short chan, u8 mode,
458 return; 458 return;
459} 459}
460 460
461static inline u16 query_tx_channel_config (hrz_dev * dev, short chan, u8 mode) {
462 wr_regw (dev, TX_CHANNEL_CONFIG_COMMAND_OFF,
463 chan * TX_CHANNEL_CONFIG_MULT | mode);
464 return rd_regw (dev, TX_CHANNEL_CONFIG_DATA_OFF);
465}
466
467/********** dump functions **********/ 461/********** dump functions **********/
468 462
469static inline void dump_skb (char * prefix, unsigned int vc, struct sk_buff * skb) { 463static inline void dump_skb (char * prefix, unsigned int vc, struct sk_buff * skb) {
@@ -513,16 +507,6 @@ static inline void dump_framer (hrz_dev * dev) {
513 507
514/* RX channels are 10 bit integers, these fns are quite paranoid */ 508/* RX channels are 10 bit integers, these fns are quite paranoid */
515 509
516static inline int channel_to_vpivci (const u16 channel, short * vpi, int * vci) {
517 unsigned short vci_bits = 10 - vpi_bits;
518 if ((channel & RX_CHANNEL_MASK) == channel) {
519 *vci = channel & ((~0)<<vci_bits);
520 *vpi = channel >> vci_bits;
521 return channel ? 0 : -EINVAL;
522 }
523 return -EINVAL;
524}
525
526static inline int vpivci_to_channel (u16 * channel, const short vpi, const int vci) { 510static inline int vpivci_to_channel (u16 * channel, const short vpi, const int vci) {
527 unsigned short vci_bits = 10 - vpi_bits; 511 unsigned short vci_bits = 10 - vpi_bits;
528 if (0 <= vpi && vpi < 1<<vpi_bits && 0 <= vci && vci < 1<<vci_bits) { 512 if (0 <= vpi && vpi < 1<<vpi_bits && 0 <= vci && vci < 1<<vci_bits) {
@@ -1260,14 +1244,6 @@ static u32 rx_queue_entry_next (hrz_dev * dev) {
1260 return rx_queue_entry; 1244 return rx_queue_entry;
1261} 1245}
1262 1246
1263/********** handle RX disabled by device **********/
1264
1265static inline void rx_disabled_handler (hrz_dev * dev) {
1266 wr_regw (dev, RX_CONFIG_OFF, rd_regw (dev, RX_CONFIG_OFF) | RX_ENABLE);
1267 // count me please
1268 PRINTK (KERN_WARNING, "RX was disabled!");
1269}
1270
1271/********** handle RX data received by device **********/ 1247/********** handle RX data received by device **********/
1272 1248
1273// called from IRQ handler 1249// called from IRQ handler