summaryrefslogtreecommitdiffstats
path: root/usr.bin/doscmd
diff options
context:
space:
mode:
authordwmalone <dwmalone@FreeBSD.org>2002-03-30 13:51:40 +0000
committerdwmalone <dwmalone@FreeBSD.org>2002-03-30 13:51:40 +0000
commit0d14312af7c4884efd15293a6f0994a48894a19a (patch)
tree299ee4db2ad7941f38ec18d94dd9e10c028f23ec /usr.bin/doscmd
parent63e149f8f69bbc0f9afbc2596a3a2cc06c2f4f57 (diff)
downloadFreeBSD-src-0d14312af7c4884efd15293a6f0994a48894a19a.zip
FreeBSD-src-0d14312af7c4884efd15293a6f0994a48894a19a.tar.gz
Mark some parameters as unused.
Make more code depend on '#ifndef NO_X' so we don't get unused warnings when compiling without X.
Diffstat (limited to 'usr.bin/doscmd')
-rw-r--r--usr.bin/doscmd/int.c8
-rw-r--r--usr.bin/doscmd/int14.c2
-rw-r--r--usr.bin/doscmd/tty.c28
3 files changed, 24 insertions, 14 deletions
diff --git a/usr.bin/doscmd/int.c b/usr.bin/doscmd/int.c
index 3974213..be70d1f 100644
--- a/usr.bin/doscmd/int.c
+++ b/usr.bin/doscmd/int.c
@@ -171,26 +171,26 @@ unpend(int irql)
}
static unsigned char
-irqc_in(int port)
+irqc_in(int port __unused)
{
return 0x60; /* What should be here? */
}
static void
-irqc_out(int port, unsigned char val)
+irqc_out(int port __unused, unsigned char val)
{
if (val == 0x20)
send_eoi();
}
static unsigned char
-imr_in(int port)
+imr_in(int port __unused)
{
return IM;
}
static void
-imr_out(int port, unsigned char val)
+imr_out(int port __unused, unsigned char val)
{
IM = val;
resume_interrupt();
diff --git a/usr.bin/doscmd/int14.c b/usr.bin/doscmd/int14.c
index f4b3d5f..0edaeee 100644
--- a/usr.bin/doscmd/int14.c
+++ b/usr.bin/doscmd/int14.c
@@ -238,7 +238,7 @@ get_int_id(struct com_data_struct *cdsp)
}
static void
-com_async(int fd, int cond, void *arg, regcontext_t *REGS)
+com_async(int fd __unused, int cond, void *arg, regcontext_t *REGS __unused)
{
struct com_data_struct *cdsp = (struct com_data_struct*) arg;
diff --git a/usr.bin/doscmd/tty.c b/usr.bin/doscmd/tty.c
index 685f1ba..03dfc62 100644
--- a/usr.bin/doscmd/tty.c
+++ b/usr.bin/doscmd/tty.c
@@ -129,13 +129,17 @@ static struct termios tty_cook, tty_raw;
static void _kbd_event(int, int, void *, regcontext_t *);
static void Failure(void *);
static void SetVREGCur(void);
+#ifndef NO_X
static void debug_event(int, int, void *, regcontext_t *);
+#endif
static unsigned char inb_port60(int);
static int inrange(int, int, int);
+#ifndef NO_X
static void kbd_event(int, int, void *, regcontext_t *);
static u_short read_raw_kbd(int, u_short *);
static void setgc(u_short);
static void video_async_event(int, int, void *, regcontext_t *);
+#endif
#ifndef NO_X
static void dac2rgb(XColor *, int);
@@ -325,7 +329,7 @@ console_init()
}
void
-video_setborder(int color)
+video_setborder(int color __unused)
{
#ifndef NO_X
XSetWindowBackground(dpy, win, pixels[color & 0xf]);
@@ -337,10 +341,10 @@ video_blink(int mode)
blink = mode;
}
+#ifndef NO_X
static void
setgc(u_short attr)
{
-#ifndef NO_X
XGCValues v;
if (blink && !show && (attr & 0x8000))
v.foreground = pixels[(attr >> 12) & 0x07];
@@ -349,8 +353,8 @@ setgc(u_short attr)
v.background = pixels[(attr >> 12) & (blink ? 0x07 : 0x0f)];
XChangeGC(dpy, gc, GCForeground|GCBackground, &v);
-#endif
}
+#endif
void
video_update(regcontext_t *REGS __unused)
@@ -531,7 +535,6 @@ vram2ximage()
return;
}
-#endif
static u_short Ascii2Scan[] = {
0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff,
@@ -551,6 +554,7 @@ static u_short Ascii2Scan[] = {
0x0019, 0x0010, 0x0013, 0x001f, 0x0014, 0x0016, 0x002f, 0x0011,
0x002d, 0x0015, 0x002c, 0x011a, 0x012b, 0x011b, 0x0129, 0xffff,
};
+#endif
struct {
u_short base;
@@ -649,8 +653,9 @@ struct {
{ 0x8600, 0x5888, 0x8a00, 0x8c00 }, /* key 88 - F12 */
};
+#ifndef NO_X
void
-debug_event(int fd, int cond, void *arg, regcontext_t *REGS)
+debug_event(int fd __unused, int cond, void *arg __unused, regcontext_t *REGS)
{
static char ibuf[1024];
static int icnt = 0;
@@ -768,6 +773,7 @@ debug_event(int fd, int cond, void *arg, regcontext_t *REGS)
ibuf[icnt] = 0;
}
}
+#endif
unsigned char
inb_port60(int port __unused)
@@ -778,8 +784,9 @@ inb_port60(int port __unused)
return(r);
}
+#ifndef NO_X
void
-kbd_event(int fd, int cond, void *arg, regcontext_t *REGS)
+kbd_event(int fd, int cond, void *arg __unused, regcontext_t *REGS __unused)
{
if (!(cond & AS_RD))
return;
@@ -790,6 +797,7 @@ kbd_event(int fd, int cond, void *arg, regcontext_t *REGS)
if ((break_code = read_raw_kbd(fd, &scan_code)) != 0xffff)
hardint(0x01);
}
+#endif
void
int09(REGISTERS __unused)
@@ -807,6 +815,7 @@ int09(REGISTERS __unused)
send_eoi();
}
+#ifndef NO_X
u_short
read_raw_kbd(int fd, u_short *code)
{
@@ -978,11 +987,12 @@ printf("FORCED REDRAW\n");
return(0xffff);
}
}
+#endif
+#ifndef NO_X
void
-video_async_event(int fd, int cond, void *arg, regcontext_t *REGS)
+video_async_event(int fd, int cond, void *arg __unused, regcontext_t *REGS __unused)
{
-#ifndef NO_X
int int9 = 0;
if (!(cond & AS_RD))
@@ -1032,8 +1042,8 @@ video_async_event(int fd, int cond, void *arg, regcontext_t *REGS)
break;
}
}
-#endif
}
+#endif
#ifndef NO_X
static int
OpenPOWER on IntegriCloud