Subject: Re: wskbd ioctl question
To:, Chris Jones <>
From: Matthias Drochner <>
List: current-users
Date: 09/03/1998 21:59:39
Excerpts from netbsd: 3-Sep-98 wskbd ioctl question Chris
Jones@rupert.honor (987)

> I open the device (/dev/ttyE0 or /dev/wskbd) as O_RDWR,
> and then I try to do a WSKBDIO_BELL ioctl.  It says, "Permission
> denied.

Hmm. Just tried the appended program, and got a beep.

> Maybe my kernel (-current from Aug
> 13) has different code than my sources (Sep 2)?

There are no changes to wscons which could explain this.

best regards

#include <stdio.h>
#include <fcntl.h>
#include <err.h>
#include <dev/wscons/wsconsio.h>

    int a, b;

    a = open("/dev/ttyE0", O_RDWR, 0);
    if (a < 0)
	err(1, "open");
    b = ioctl(a, WSKBDIO_BELL, 0);
    if (b < 0)
	err(1, "ioctl");