lkml.org 
[lkml]   [2011]   [May]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/4] drivers: create a pinmux subsystem
On Wed, May 11, 2011 at 12:18:00AM +0200, Linus Walleij wrote:

> This is the idiomatic way of providing sysfs strings (compare e.g.
> *_show() in drivers/regulator/core.c), the char *buf comes
> from the sysfs core in struct device_attribute in <linus/device.h>
> with this prototype:

> ssize_t (*show)(struct device *dev, struct device_attribute *attr,
> char *buf);

> and I have no way of knowing how large that buffer is. Migrating all

It's implicitly PAGE_SIZE. In pretty much all users the buffer is
constrained to well below that by the inputs (sometimes with some help
from users not using insanely long names for things) and the sysfs
semantics which mean you probably got something badly wrong if you get
anywhere near PAGE_SIZE.


\
 
 \ /
  Last update: 2011-05-11 00:43    [W:0.085 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site