]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/m68k/mvme16x/config.c
proc: move /proc/hardware to m68k-specific code
[linux-2.6-omap-h63xx.git] / arch / m68k / mvme16x / config.c
index 24cbc3030454aed4a76e847cfed91f415d8fc33b..1521826fc3c7caef9a62935a2bde21f0f6135378 100644 (file)
@@ -17,6 +17,7 @@
 #include <linux/types.h>
 #include <linux/kernel.h>
 #include <linux/mm.h>
+#include <linux/seq_file.h>
 #include <linux/tty.h>
 #include <linux/console.h>
 #include <linux/linkage.h>
@@ -42,7 +43,6 @@ extern t_bdid mvme_bdid;
 static MK48T08ptr_t volatile rtc = (MK48T08ptr_t)MVME_RTC_BASE;
 
 static void mvme16x_get_model(char *model);
-static int  mvme16x_get_hardware_list(char *buffer);
 extern void mvme16x_sched_init(irq_handler_t handler);
 extern unsigned long mvme16x_gettimeoffset (void);
 extern int mvme16x_hwclk (int, struct rtc_time *);
@@ -93,26 +93,21 @@ static void mvme16x_get_model(char *model)
 }
 
 
-static int mvme16x_get_hardware_list(char *buffer)
+static void mvme16x_get_hardware_list(struct seq_file *m)
 {
     p_bdid p = &mvme_bdid;
-    int len = 0;
 
     if (p->brdno == 0x0162 || p->brdno == 0x0172)
     {
        unsigned char rev = *(unsigned char *)MVME162_VERSION_REG;
 
-       len += sprintf (buffer+len, "VMEchip2        %spresent\n",
+       seq_printf (m, "VMEchip2        %spresent\n",
                        rev & MVME16x_CONFIG_NO_VMECHIP2 ? "NOT " : "");
-       len += sprintf (buffer+len, "SCSI interface  %spresent\n",
+       seq_printf (m, "SCSI interface  %spresent\n",
                        rev & MVME16x_CONFIG_NO_SCSICHIP ? "NOT " : "");
-       len += sprintf (buffer+len, "Ethernet i/f    %spresent\n",
+       seq_printf (m, "Ethernet i/f    %spresent\n",
                        rev & MVME16x_CONFIG_NO_ETHERNET ? "NOT " : "");
     }
-    else
-       *buffer = '\0';
-
-    return (len);
 }
 
 /*