diff options
author | Alexey Dobriyan <adobriyan@sw.ru> | 2008-04-29 04:01:47 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-29 11:06:19 -0400 |
commit | 51251549140f99cc5fbfed8ac542f22cbf067870 (patch) | |
tree | bbfdbf55f1aec2f9a5e137dbb286912f8d448e41 /arch/m68k/mac | |
parent | 647634df400ed26e2707ef65a8bf0df3f3bb8663 (diff) |
proc: remove /proc/mac_iop
Entry creation was commented for a long time and right now it stands on
the way of ->get_info removal, so unless nobody objects...
Signed-off-by: Alexey Dobriyan <adobriyan@sw.ru>
Cc: Simon Arlott <simon@fire.lp0.eu>
Cc: Roman Zippel <zippel@linux-m68k.org>
Cc: Joern Engel <joern@wohnheim.fh-wedel.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/m68k/mac')
-rw-r--r-- | arch/m68k/mac/iop.c | 85 |
1 files changed, 0 insertions, 85 deletions
diff --git a/arch/m68k/mac/iop.c b/arch/m68k/mac/iop.c index 092d4b3d8f76..326fb9978094 100644 --- a/arch/m68k/mac/iop.c +++ b/arch/m68k/mac/iop.c | |||
@@ -109,7 +109,6 @@ | |||
109 | #include <linux/mm.h> | 109 | #include <linux/mm.h> |
110 | #include <linux/delay.h> | 110 | #include <linux/delay.h> |
111 | #include <linux/init.h> | 111 | #include <linux/init.h> |
112 | #include <linux/proc_fs.h> | ||
113 | #include <linux/interrupt.h> | 112 | #include <linux/interrupt.h> |
114 | 113 | ||
115 | #include <asm/bootinfo.h> | 114 | #include <asm/bootinfo.h> |
@@ -124,10 +123,6 @@ | |||
124 | 123 | ||
125 | int iop_scc_present,iop_ism_present; | 124 | int iop_scc_present,iop_ism_present; |
126 | 125 | ||
127 | #ifdef CONFIG_PROC_FS | ||
128 | static int iop_get_proc_info(char *, char **, off_t, int); | ||
129 | #endif /* CONFIG_PROC_FS */ | ||
130 | |||
131 | /* structure for tracking channel listeners */ | 126 | /* structure for tracking channel listeners */ |
132 | 127 | ||
133 | struct listener { | 128 | struct listener { |
@@ -299,12 +294,6 @@ void __init iop_init(void) | |||
299 | iop_listeners[IOP_NUM_ISM][i].devname = NULL; | 294 | iop_listeners[IOP_NUM_ISM][i].devname = NULL; |
300 | iop_listeners[IOP_NUM_ISM][i].handler = NULL; | 295 | iop_listeners[IOP_NUM_ISM][i].handler = NULL; |
301 | } | 296 | } |
302 | |||
303 | #if 0 /* Crashing in 2.4 now, not yet sure why. --jmt */ | ||
304 | #ifdef CONFIG_PROC_FS | ||
305 | create_proc_info_entry("mac_iop", 0, NULL, iop_get_proc_info); | ||
306 | #endif | ||
307 | #endif | ||
308 | } | 297 | } |
309 | 298 | ||
310 | /* | 299 | /* |
@@ -637,77 +626,3 @@ irqreturn_t iop_ism_irq(int irq, void *dev_id) | |||
637 | } | 626 | } |
638 | return IRQ_HANDLED; | 627 | return IRQ_HANDLED; |
639 | } | 628 | } |
640 | |||
641 | #ifdef CONFIG_PROC_FS | ||
642 | |||
643 | char *iop_chan_state(int state) | ||
644 | { | ||
645 | switch(state) { | ||
646 | case IOP_MSG_IDLE : return "idle "; | ||
647 | case IOP_MSG_NEW : return "new "; | ||
648 | case IOP_MSG_RCVD : return "received "; | ||
649 | case IOP_MSG_COMPLETE : return "completed "; | ||
650 | default : return "unknown "; | ||
651 | } | ||
652 | } | ||
653 | |||
654 | int iop_dump_one_iop(char *buf, int iop_num, char *iop_name) | ||
655 | { | ||
656 | int i,len = 0; | ||
657 | volatile struct mac_iop *iop = iop_base[iop_num]; | ||
658 | |||
659 | len += sprintf(buf+len, "%s IOP channel states:\n\n", iop_name); | ||
660 | len += sprintf(buf+len, "## send_state recv_state device\n"); | ||
661 | len += sprintf(buf+len, "------------------------------------------------\n"); | ||
662 | for (i = 0 ; i < NUM_IOP_CHAN ; i++) { | ||
663 | len += sprintf(buf+len, "%2d %10s %10s %s\n", i, | ||
664 | iop_chan_state(iop_readb(iop, IOP_ADDR_SEND_STATE+i)), | ||
665 | iop_chan_state(iop_readb(iop, IOP_ADDR_RECV_STATE+i)), | ||
666 | iop_listeners[iop_num][i].handler? | ||
667 | iop_listeners[iop_num][i].devname : ""); | ||
668 | |||
669 | } | ||
670 | len += sprintf(buf+len, "\n"); | ||
671 | return len; | ||
672 | } | ||
673 | |||
674 | static int iop_get_proc_info(char *buf, char **start, off_t pos, int count) | ||
675 | { | ||
676 | int len, cnt; | ||
677 | |||
678 | cnt = 0; | ||
679 | len = sprintf(buf, "IOPs detected:\n\n"); | ||
680 | |||
681 | if (iop_scc_present) { | ||
682 | len += sprintf(buf+len, "SCC IOP (%p): status %02X\n", | ||
683 | iop_base[IOP_NUM_SCC], | ||
684 | (uint) iop_base[IOP_NUM_SCC]->status_ctrl); | ||
685 | } | ||
686 | if (iop_ism_present) { | ||
687 | len += sprintf(buf+len, "ISM IOP (%p): status %02X\n\n", | ||
688 | iop_base[IOP_NUM_ISM], | ||
689 | (uint) iop_base[IOP_NUM_ISM]->status_ctrl); | ||
690 | } | ||
691 | |||
692 | if (iop_scc_present) { | ||
693 | len += iop_dump_one_iop(buf+len, IOP_NUM_SCC, "SCC"); | ||
694 | |||
695 | } | ||
696 | |||
697 | if (iop_ism_present) { | ||
698 | len += iop_dump_one_iop(buf+len, IOP_NUM_ISM, "ISM"); | ||
699 | |||
700 | } | ||
701 | |||
702 | if (len >= pos) { | ||
703 | if (!*start) { | ||
704 | *start = buf + pos; | ||
705 | cnt = len - pos; | ||
706 | } else { | ||
707 | cnt += len; | ||
708 | } | ||
709 | } | ||
710 | return (count > cnt) ? cnt : count; | ||
711 | } | ||
712 | |||
713 | #endif /* CONFIG_PROC_FS */ | ||