public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Marcel Holtmann <marcel@holtmann.org>
To: "P.Manohar" <pmanohar@lantana.cs.iitm.ernet.in>
Cc: linux-kernel@vger.kernel.org
Subject: Re: ioctl to keyboard device file
Date: Mon, 16 May 2005 11:54:01 +0200	[thread overview]
Message-ID: <1116237241.10063.3.camel@pegasus> (raw)
In-Reply-To: <Pine.LNX.4.60.0505161418470.31612@lantana.cs.iitm.ernet.in>

Hi,

>      My task is to send the characters to any application as if the input 
> is coming from keyboard. For that I created one character device file. To 
> it I am sending input characters through ioctl. In the character device 
> ioctl definition I am copying these user characters to kernel space and 
> sending these characters to handle_scancode function. What is the wrong 
> with this solution. This solution is working now. But waht I am asking is
> istead of sending our ioctl to newly created device file, can we able to 
> send ioctl to the keyboard buffer, so that avoiding the use of new 
> character device file , whose purpose is just to handle ioctl.

using uinput is the way to achieve this goal. What you did is an ugly
hack and I don't see any chance to get it merged back mainline.

> One more is, uinput case,
> 
> Whether uinput also doing the same thing, waht I am doing?
> For sending user data to kernel sapce we should use ioctl ,is it right?

This has nothing to do with ioctl() versus write(). Forget about it and
start using uinput.

Regards

Marcel



  reply	other threads:[~2005-05-16  9:54 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-11 16:43 ioctl to keyboard device file P.Manohar
2005-05-11 17:14 ` Marcel Holtmann
2005-05-11 17:34   ` P.Manohar
2005-05-11 17:53     ` Marcel Holtmann
2005-05-11 18:17       ` Jan-Benedict Glaw
     [not found]       ` <Pine.LNX.4.60.0505121454240.26644@lantana.cs.iitm.ernet.in>
2005-05-12 10:01         ` Marcel Holtmann
2005-05-16  8:58           ` P.Manohar
2005-05-16  9:54             ` Marcel Holtmann [this message]
     [not found]               ` <Pine.LNX.4.60.0505162112240.25368@lantana.cs.iitm.ernet.in>
2005-05-16 16:19                 ` Marcel Holtmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1116237241.10063.3.camel@pegasus \
    --to=marcel@holtmann.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pmanohar@lantana.cs.iitm.ernet.in \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox