linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Lothar Waßmann" <LW@KARO-electronics.de>
To: Alberto Panizzo <maramaopercheseimorto@gmail.com>
Cc: H Hartley Sweeten <hartleys@visionengravers.com>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	Sascha linux-arm <s.hauer@pengutronix.de>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
	linux-input <linux-input@vger.kernel.org>
Subject: Re: [PATCH v3] input: MXC: add mxc-keypad driver to support the Keypad Port present in the mxc application processors family.
Date: Wed, 27 Jan 2010 15:52:34 +0100	[thread overview]
Message-ID: <19296.21298.394254.553268@ipc1.ka-ro> (raw)
In-Reply-To: <1264603193.2463.75.camel@realization>

Hi,

Alberto Panizzo writes:
> On mer, 2010-01-27 at 13:18 +0100, Lothar Waßmann wrote:
> > Hi,
> > 
> > Alberto Panizzo writes:
> > > > > +	irq = platform_get_irq(pdev, 0);
> > > > > +	if (irq < 0) {
> > > > > +		dev_err(&pdev->dev, "failed to get keypad irq\n");
> > > > > +		return -ENXIO;
> > > > > +	}
> > > > >
> > > > This should be -ENODEV.
> > > > 
> > > Lot of reference keyboard driver use -ENXIO..
> > > May should be better: return irq ?
> > > 
> > Yes, of course. If a function returns an error code that should be
> > promoted to the caller instead of inventing a new error code.
> > 
> > 
> > Lothar Waßmann
> 
> But, errno.h say:
> #define ENXIO           6                // Device not configured
> #define ENODEV          19               // Operation not supported by device
> 
What errno.h file is that?
I have:
./include/asm-generic/errno-base.h:#define      ENXIO            6      /* No such device or address */
./include/asm-generic/errno-base.h:#define      ENODEV          19      /* No such device */

AFAIK ENXIO is used when actual I/O has been attempted. But in this
case the driver is still being configured and did not do any I/O yet.


Lothar Waßmann
-- 
___________________________________________________________

Ka-Ro electronics GmbH | Pascalstraße 22 | D - 52076 Aachen
Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
Geschäftsführer: Matthias Kaussen
Handelsregistereintrag: Amtsgericht Aachen, HRB 4996

www.karo-electronics.de | info@karo-electronics.de
___________________________________________________________

  reply	other threads:[~2010-01-27 14:52 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-27  9:55 [PATCH v3] input: MXC: add mxc-keypad driver to support the Keypad Port present in the mxc application processors family Alberto Panizzo
2010-01-27 10:33 ` Lothar Waßmann
2010-01-27 10:45   ` Uwe Kleine-König
2010-01-27 12:17     ` Alberto Panizzo
2010-01-27 12:14   ` Alberto Panizzo
2010-01-27 12:18     ` Lothar Waßmann
2010-01-27 14:39       ` Alberto Panizzo
2010-01-27 14:52         ` Lothar Waßmann [this message]
2010-01-27 15:29           ` Alberto Panizzo
2010-01-27 17:03             ` Lothar Waßmann
2010-01-27 17:32               ` Dmitry Torokhov
2010-01-27 17:42               ` Alberto Panizzo

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=19296.21298.394254.553268@ipc1.ka-ro \
    --to=lw@karo-electronics.de \
    --cc=dmitry.torokhov@gmail.com \
    --cc=hartleys@visionengravers.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-input@vger.kernel.org \
    --cc=maramaopercheseimorto@gmail.com \
    --cc=s.hauer@pengutronix.de \
    /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;
as well as URLs for NNTP newsgroup(s).