lkml.org 
[lkml]   [2000]   [Feb]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: getting more that 4K out of a proc file?
Date
"A month of sundays ago Alan Cox wrote:"
> > In net/atm/proc.c, the file position is abused as an item counter.
> > Works pretty well. (Hardly anybody does calculated seeks, and the
> > more common "rewind" and "return to previously seen position" cases
> > are okay.)
>
> Yuck. Take a look at the routing code for IP stuff. We use fixed width records
> with space padding. Then you just shift right to get the item counter
> and it still works byte level

I have rewritten the generic proc read routine to at least be
comprehensible. (It's the stuff that interfaces the read calls
made at FS level to the functions registered with proc).

I was waiting for notices to come in of uses of some of its (to me obscure
and probably disused) modes before I changed the functionality to get rid
of them. I've been collecting the notices here and will cheerfully post a
suggested patch shortly ... (snowed under here).

Peter

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:56    [W:0.065 / U:0.172 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site