From: "Américo Wang" <xiyou.wangcong@gmail.com>
To: Jidong Xiao <jidong.xiao@gmail.com>
Cc: Kernel development list <linux-kernel@vger.kernel.org>
Subject: Re: How to export information larger than PROC_BLOCK_SIZE via /proc file system?
Date: Wed, 27 Apr 2011 11:00:32 +0800 [thread overview]
Message-ID: <BANLkTik+9oz9fbeTwS4qd32ukw6uPHtrWA@mail.gmail.com> (raw)
In-Reply-To: <BANLkTinQJ6wzOR++c-OSiCkf=MjOU=y=1A@mail.gmail.com>
On Wed, Apr 27, 2011 at 8:54 AM, Jidong Xiao <jidong.xiao@gmail.com> wrote:
> Hi,
>
> I am tracing some data inside the kernel, and I plan to export the
> tracing data through /proc file system. I created a file under /proc
> file system, and I use cat to display the tracing data. However, every
> time there is only 3072 bytes data displayed, which is the size
> defined by PROC_BLOCK_SIZE. And I wonder that how to export
> information more than that limit? Judging from the function
> fs/proc/generic.c/proc_file_read(), if the size returned by my
> read_proc function is large than a PAGE_SIZE, then I will get a
> KERN_ERR message which says "proc_file_read: Apparent buffer
> overflow!". Any help would be appreciated!
>
Why not switch to use debugfs?
next prev parent reply other threads:[~2011-04-27 3:00 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-27 0:54 Jidong Xiao
2011-04-27 3:00 ` Américo Wang [this message]
2011-04-27 3:18 ` Alexey Dobriyan
2011-04-27 4:16 ` Jidong Xiao
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=BANLkTik+9oz9fbeTwS4qd32ukw6uPHtrWA@mail.gmail.com \
--to=xiyou.wangcong@gmail.com \
--cc=jidong.xiao@gmail.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®