mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Michal Ostrowski <mostrows@watson.ibm.com>
To: linux-kernel@vger.kernel.org
Subject: BUG? [PATCH] driver core: Add the ability to bind drivers to devices from userspace
Date: Wed, 17 Aug 2005 19:43:48 -0400	[thread overview]
Message-ID: <20050817194348.3fb5b3d0@brick.watson.ibm.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 626 bytes --]


If a driver's probe function returns -ENXIO or -ENODEV,
driver_probe_device() will translate that to return 0 (comments argue it
is not an error).

Consequently driver_bind() will return 0 resulting in the write
system-call that initiated all of this in returning 0 as well.

If one uses "echo" to write to a "bind" attribute, echo will
continuously call write() trying to write to the attribute and always
get 0 as a result and thus find itself in a loop trying to do the write.

Perhaps the translation of -ENZIO to -ENODEV to success in
driver_probe_device() is not approriate here?

-- 
Michal Ostrowski

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

                 reply	other threads:[~2005-08-17 23:43 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20050817194348.3fb5b3d0@brick.watson.ibm.com \
    --to=mostrows@watson.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®