mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@suse.cz>
To: Patrick Mochel <mochel@osdl.org>
Cc: Petr Vandrovec <VANDROVE@vc.cvut.cz>, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] read() from driverfs files can read more bytes
Date: Fri, 8 Feb 2002 20:18:24 +0100	[thread overview]
Message-ID: <20020208191824.GA561@elf.ucw.cz> (raw)
In-Reply-To: <1124DDDD7FF9@vcnet.vc.cvut.cz> <Pine.LNX.4.33.0202071021280.25114-100000@segfault.osdlab.org>
In-Reply-To: <Pine.LNX.4.33.0202071021280.25114-100000@segfault.osdlab.org>

Hi!

> Ok, I agree with your argument concerning read(). 
> 
> Concerning reading/writing from offsets, it's up to the drivers for them 
> to either support it or not. In the files I've done so far, I return 0 if 
> show() is called with an offset. Which will give different results if you 
> read byte-by-byte or an entire chunk. 
> 
> It makes the callbacks simpler, but it is not technically correct. 

[snip solution]

Why not just say those files are character devices? It is okay for
character device to behave like crazy ;-).
									Pavel
-- 
(about SSSCA) "I don't say this lightly.  However, I really think that the U.S.
no longer is classifiable as a democracy, but rather as a plutocracy." --hpa

  reply	other threads:[~2002-02-08 21:12 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-02-07 18:15 Petr Vandrovec
2002-02-07 18:27 ` Patrick Mochel
2002-02-08 19:18   ` Pavel Machek [this message]
  -- strict thread matches above, loose matches on Subject: below --
2002-02-07 20:11 Petr Vandrovec
2002-02-07 20:21 ` Patrick Mochel
2002-02-07 20:26   ` Alexander Viro
2002-02-07 20:59     ` Patrick Mochel
2002-02-07 21:37       ` Alexander Viro
2002-02-07 18:11 Thomas Hood
2002-02-07 17:25 Petr Vandrovec
2002-02-07 17:43 ` Patrick Mochel

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=20020208191824.GA561@elf.ucw.cz \
    --to=pavel@suse.cz \
    --cc=VANDROVE@vc.cvut.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mochel@osdl.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®